-
Notifications
You must be signed in to change notification settings - Fork 1.9k
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
[Refactor] SegmentsStats#filesSizes from ImmutableOpenMap to java.util.Map #7094
Conversation
…l.Map Using an ImmutableOpenMap in filesSizes in o.o.index.engine.SegmentsStats is overkill since all we care about is public facing API not leaking the filesSizes collection. This commit refactors the SegmentsStats#filesSizes variable from an ImmutableOpenMap to an unmodifiable java.util.Map to remove all of the unnecessary temporary object copies on the internal map. Signed-off-by: Nicholas Walter Knize <nknize@apache.org>
Gradle Check (Jenkins) Run Completed with:
|
Doc count assertion failure, seems non-related to changes. Retrying check.
|
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.
Nice (Spring?) cleanup :)
Gradle Check (Jenkins) Run Completed with:
|
Codecov Report
📣 This organization is not using Codecov’s GitHub App Integration. We recommend you install it so Codecov can continue to function properly for your repositories. Learn more @@ Coverage Diff @@
## main #7094 +/- ##
============================================
- Coverage 71.10% 70.80% -0.30%
+ Complexity 59808 59485 -323
============================================
Files 4852 4852
Lines 285138 285123 -15
Branches 41107 41104 -3
============================================
- Hits 202755 201892 -863
- Misses 66040 66628 +588
- Partials 16343 16603 +260
... and 446 files with indirect coverage changes Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here. |
I opened #7101 for the unrelated GeoHashGridIT failure. Rerunning the cancelled precommit job and will merge on green. |
…l.Map (#7094) Using an ImmutableOpenMap in filesSizes in o.o.index.engine.SegmentsStats is overkill since all we care about is public facing API not leaking the filesSizes collection. This commit refactors the SegmentsStats#filesSizes variable from an ImmutableOpenMap to an unmodifiable java.util.Map to remove all of the unnecessary temporary object copies on the internal map. It also refactors the internal only used FILE_DESCRIPTIONS static variable to an unmodifiable java.util.Map in order to completely remove SegmentsStats dependency on hppc based ImmutableOpenMap. Signed-off-by: Nicholas Walter Knize <nknize@apache.org> (cherry picked from commit 352de4e) Signed-off-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
…l.Map (#7094) (#7162) Using an ImmutableOpenMap in filesSizes in o.o.index.engine.SegmentsStats is overkill since all we care about is public facing API not leaking the filesSizes collection. This commit refactors the SegmentsStats#filesSizes variable from an ImmutableOpenMap to an unmodifiable java.util.Map to remove all of the unnecessary temporary object copies on the internal map. It also refactors the internal only used FILE_DESCRIPTIONS static variable to an unmodifiable java.util.Map in order to completely remove SegmentsStats dependency on hppc based ImmutableOpenMap. (cherry picked from commit 352de4e) Signed-off-by: Nicholas Walter Knize <nknize@apache.org> Signed-off-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com> Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
…l.Map (opensearch-project#7094) Using an ImmutableOpenMap in filesSizes in o.o.index.engine.SegmentsStats is overkill since all we care about is public facing API not leaking the filesSizes collection. This commit refactors the SegmentsStats#filesSizes variable from an ImmutableOpenMap to an unmodifiable java.util.Map to remove all of the unnecessary temporary object copies on the internal map. It also refactors the internal only used FILE_DESCRIPTIONS static variable to an unmodifiable java.util.Map in order to completely remove SegmentsStats dependency on hppc based ImmutableOpenMap. Signed-off-by: Nicholas Walter Knize <nknize@apache.org>
Using an
ImmutableOpenMap
ino.o.index.engine.SegmentsStats#filesSizes
is overkill since all we care about is public facing API not leaking thefilesSizes
collection. To remove all of the unnecessary temporary object copies saddled with usingImmutableOpenMap
internally, this PR refactors the SegmentsStats#filesSizes variable from anImmutableOpenMap
to an unmodifiable java.util.Map. It also refactors the internal only usedFILE_DESCRIPTIONS
static variable to an unmodifiable java.util.Map in order to completely removeSegmentsStats
dependency on hppc basedImmutableOpenMap
.relates #5910