[Refactor] remaining ImmutableOpenMap usage to j.u.Map and remove class#7309
Conversation
Refactors all remaining usage of HPPC backed ImmutableOpenMap to j.u.Map. This is the last usage of the class so ImmutableOpenMap is completely removed in favor of java maps. Signed-off-by: Nicholas Walter Knize <nknize@apache.org>
Gradle Check (Jenkins) Run Completed with:
|
Codecov Report❌ Patch coverage is Additional details and impacted files@@ Coverage Diff @@
## main #7309 +/- ##
============================================
+ Coverage 70.45% 70.67% +0.21%
- Complexity 59381 59513 +132
============================================
Files 4862 4859 -3
Lines 285489 285339 -150
Branches 41144 41133 -11
============================================
+ Hits 201143 201653 +510
+ Misses 67777 67166 -611
+ Partials 16569 16520 -49 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
andrross
left a comment
There was a problem hiding this comment.
This refactoring has caused some issues for the plugins, but since we've already started it will be good to finish.
I'm wondering if it'll be less impactful on downstream dependencies to do the backport in a single commit that combines all the ImmutableOpenMap removal changes.
I'm not opposed that. Or I can take care of all of these backports pretty quickly myself. |
….com/opensearch-project/OpenSearch/pull/7309 Signed-off-by: Joshua Palis <jpalis@amazon.com>
…y and multi-entity detectors (#880) * Initial historical analysis commit. Registers ForwardADTaskTransportAction, ADBatchAnomalyResultTransportAction, replaces Internal Aggregation classes with corresponding Parsed Aggregation class. removes hashring from historical analysis workflow Signed-off-by: Joshua Palis <jpalis@amazon.com> * Reverts changes to AnomalyResultBulkIndexHandler and uses the SDKRestClient to bulk index anomaly results, replaces transport service calls with corresponding client execute calls. Adds check for request content for job details registration, this prevents historical task requests from triggering job details registration Signed-off-by: Joshua Palis <jpalis@amazon.com> * Adds another check for job details registration for start path only, adds transport action for stop historical detector Signed-off-by: Joshua Palis <jpalis@amazon.com> * Fixing import error, test classes Signed-off-by: Joshua Palis <jpalis@amazon.com> * spotlessApply Signed-off-by: Joshua Palis <jpalis@amazon.com> * Commenting out parse bucket tests since ParsedAggregation classes have no constructor to access via reflection Signed-off-by: Joshua Palis <jpalis@amazon.com> * Addressing PR comments Signed-off-by: Joshua Palis <jpalis@amazon.com> * replaceing .valuesIt() with .values().iterator() due tohttps://github.com/opensearch-project/OpenSearch/pull/7309 Signed-off-by: Joshua Palis <jpalis@amazon.com> * removing ImmutableOpenMap Signed-off-by: Joshua Palis <jpalis@amazon.com> * Reverting dataGeneration script changes Signed-off-by: Joshua Palis <jpalis@amazon.com> * fixing iterator Signed-off-by: Joshua Palis <jpalis@amazon.com> * Fixing data nodes iterator Signed-off-by: Joshua Palis <jpalis@amazon.com> * removing value from iterator Signed-off-by: Joshua Palis <jpalis@amazon.com> --------- Signed-off-by: Joshua Palis <jpalis@amazon.com>
…nsearch-project#7309) Refactors all remaining usage of HPPC backed ImmutableOpenMap to j.u.Map. This is the last usage of the class so ImmutableOpenMap is completely removed in favor of java maps. Signed-off-by: Nicholas Walter Knize <nknize@apache.org>
|
Due to this refactoring, we have seen improvement in heap memory usage. The |
|
The backport to To backport manually, run these commands in your terminal: # Fetch latest updates from GitHub
git fetch
# Create a new working tree
git worktree add ../.worktrees/backport-2.x 2.x
# Navigate to the new working tree
pushd ../.worktrees/backport-2.x
# Create a new branch
git switch --create backport/backport-7309-to-2.x
# Cherry-pick the merged commit of this pull request and resolve the conflicts
git cherry-pick -x --mainline 1 d984f5028e77e281ed08386d43de4e64e06f2bf8
# Push it to GitHub
git push --set-upstream origin backport/backport-7309-to-2.x
# Go back to the original working tree
popd
# Delete the working tree
git worktree remove ../.worktrees/backport-2.xThen, create a pull request where the |
…nsearch-project#7309) Refactors all remaining usage of HPPC backed ImmutableOpenMap to j.u.Map. This is the last usage of the class so ImmutableOpenMap is completely removed in favor of java maps. Signed-off-by: Nicholas Walter Knize <nknize@apache.org> (cherry picked from commit d984f50)
…nsearch-project#7309) Refactors all remaining usage of HPPC backed ImmutableOpenMap to j.u.Map. This is the last usage of the class so ImmutableOpenMap is completely removed in favor of java maps. Signed-off-by: Nicholas Walter Knize <nknize@apache.org> (cherry picked from commit d984f50)
…nsearch-project#7309) Refactors all remaining usage of HPPC backed ImmutableOpenMap to j.u.Map. This is the last usage of the class so ImmutableOpenMap is completely removed in favor of java maps. Signed-off-by: Nicholas Walter Knize <nknize@apache.org> Signed-off-by: Shivansh Arora <hishiv@amazon.com>
Refactors all remaining usage of HPPC backed
ImmutableOpenMaptoj.u.Map. This is the last usage of the class soImmutableOpenMapis also completely removed in favor ofjava.util.Mapusage.relates #5910