Skip to content
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

Fixed ADTaskProfile toXContent bug and added to .gitignore #447

Merged

Conversation

amitgalitz
Copy link
Member

Signed-off-by: Amit Galitzky amgalitz@amazon.com

Description

  1. Fixed bug in ADTaskProfile.toXContent() which added ENTITY_TASK_PROFILE_FIELD instead of LATEST_HC_TASK_RUN_TIME_FIELD when latestHCTaskRunTime was present in constructor. Also added a test case for this. This previously would cause a parsing exception if a non null latestHCTaskRunTime was given to constructor.
  2. Added ._.DS_Store to .gitignore as its a file that gets auto created by macOS Finder which isn't relevant.

Check List

  • Commits are signed per the DCO using --signoff

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
For more information on following Developer Certificate of Origin and signing off your commits, please check here.

Signed-off-by: Amit Galitzky <amgalitz@amazon.com>
@amitgalitz amitgalitz added the bug Something isn't working label Mar 16, 2022
@amitgalitz amitgalitz requested a review from a team March 16, 2022 18:38
Copy link
Collaborator

@ylwu-amzn ylwu-amzn left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. Thanks for fixing this bug!

@codecov-commenter
Copy link

Codecov Report

Merging #447 (8c8a90f) into main (124a269) will increase coverage by 0.46%.
The diff coverage is 100.00%.

Impacted file tree graph

@@             Coverage Diff              @@
##               main     #447      +/-   ##
============================================
+ Coverage     77.46%   77.92%   +0.46%     
- Complexity     4099     4134      +35     
============================================
  Files           296      296              
  Lines         17657    17657              
  Branches       1879     1879              
============================================
+ Hits          13678    13760      +82     
+ Misses         3071     3005      -66     
+ Partials        908      892      -16     
Flag Coverage Δ
plugin 77.92% <100.00%> (+0.46%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
...in/java/org/opensearch/ad/model/ADTaskProfile.java 86.49% <100.00%> (+16.03%) ⬆️
...rch/ad/transport/ForwardADTaskTransportAction.java 94.06% <0.00%> (-3.39%) ⬇️
...opensearch/ad/indices/AnomalyDetectionIndices.java 72.47% <0.00%> (+0.37%) ⬆️
...ain/java/org/opensearch/ad/task/ADTaskManager.java 76.67% <0.00%> (+0.45%) ⬆️
.../main/java/org/opensearch/ad/ml/CheckpointDao.java 70.19% <0.00%> (+0.64%) ⬆️
...rch/ad/transport/AnomalyResultTransportAction.java 80.82% <0.00%> (+0.68%) ⬆️
...ava/org/opensearch/ad/task/ADHCBatchTaskCache.java 90.12% <0.00%> (+1.23%) ⬆️
...java/org/opensearch/ad/task/ADBatchTaskRunner.java 81.76% <0.00%> (+3.49%) ⬆️
...ain/java/org/opensearch/ad/model/ModelProfile.java 72.72% <0.00%> (+3.63%) ⬆️
.../java/org/opensearch/ad/AnomalyDetectorRunner.java 43.52% <0.00%> (+5.88%) ⬆️
... and 2 more

@amitgalitz amitgalitz merged commit b0f6475 into opensearch-project:main Mar 16, 2022
opensearch-trigger-bot bot pushed a commit that referenced this pull request Mar 22, 2022
Signed-off-by: Amit Galitzky <amgalitz@amazon.com>
(cherry picked from commit b0f6475)
amitgalitz added a commit that referenced this pull request Mar 22, 2022
Signed-off-by: Amit Galitzky <amgalitz@amazon.com>
(cherry picked from commit b0f6475)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backport 1.x bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants