-
Notifications
You must be signed in to change notification settings - Fork 1.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Returning cache to life. #3307
Returning cache to life. #3307
Conversation
Codecov Report
@@ Coverage Diff @@
## master #3307 +/- ##
============================================
+ Coverage 92.95% 93.00% +0.04%
+ Complexity 3542 3539 -3
============================================
Files 382 382
Lines 9389 9388 -1
Branches 760 755 -5
============================================
+ Hits 8728 8731 +3
Misses 468 468
+ Partials 193 189 -4
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍 Just had one questions about a change.
@@ -127,7 +126,7 @@ public ApiListingScanner( | |||
|
|||
List<SecurityReference> securityReferences = new ArrayList<>(); | |||
|
|||
Map<String, Set<Model>> globalModelMap = new TreeMap<>(); | |||
Map<String, Set<Model>> globalModelMap = new HashMap<>(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This was tree map because it preserves the order of the models. Does this need to change to hash map?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Iterating over HashMap
is faster than iterating TreeMap
, and order is not important any more
Thank you @MaksimOrlov! |
This PR returns support for cache. Variable
parameterId
has been removed from.equals()
and.hashCode()
methods ofModelContext
. Speed on load testing shows increasing from 130 test controllers to 300 controllers per second.