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
Performance improvments #470
Conversation
1. `properties` is a list comprehension 2. Massively reduce the amount of calls to `properties`
1 similar comment
- Path and modified time of JSON file are used as the cache key - Global state is hidden away inside a root-class for re-use - Maximum size is 150 considering the number of JSON definitions During my tests the memory usage of the test suites was halved.
…to mback2k-template-cache
90 days and counting, folks.
Codecov Report
@@ Coverage Diff @@
## master #470 +/- ##
==========================================
+ Coverage 35.97% 36.05% +0.07%
==========================================
Files 35 35
Lines 6679 6712 +33
==========================================
+ Hits 2403 2420 +17
- Misses 4276 4292 +16
Continue to review full report at Codecov.
|
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.
@Rafiot Thanks for merging my PR. It looks good so far, but I have some comments you may want to look at.
I am currently testing this PR in our application and will report back about the result soon.
Okay, my test cases are passing now... let me know how that goes for you. |
Thanks, with the previous changes we still had huge memory usage. So I am going to give the latest changes another try and will report back later today. |
Sorry for my delayed response regarding my results. Unfortunately I am still analyzing the memory usage, because we are still hitting some limits at the moment. I hope to find the root cause soon. |
Hmmm that's weird. If you give a try to rapidjson, the memory use was a little bit lower on my end. |
Ok, I think it is ready to be merged, the tests are passing, and it is already an improvement. Please let me know if you figure out what is going on on your side, and where we can improve the code from there. |
I am going to test the latest changes now. |
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.
Sorry, I forgot to submit this pending review. Have you seen my comment regarding remote_describe_types = describe_types
?
Need to be checked.