Skip to content
This repository has been archived by the owner on Aug 2, 2022. It is now read-only.

Adding RestActions support for Get Detector API #242

Merged
merged 5 commits into from
Oct 12, 2020

Conversation

saratvemulapalli
Copy link
Contributor

*Issue #195 *

Description of changes:
Adding RestActions support for Get Detector API

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

@codecov
Copy link

codecov bot commented Oct 9, 2020

Codecov Report

Merging #242 into master will decrease coverage by 1.28%.
The diff coverage is 27.17%.

Impacted file tree graph

@@             Coverage Diff              @@
##             master     #242      +/-   ##
============================================
- Coverage     72.86%   71.57%   -1.29%     
- Complexity     1329     1350      +21     
============================================
  Files           149      153       +4     
  Lines          6194     6406     +212     
  Branches        480      490      +10     
============================================
+ Hits           4513     4585      +72     
- Misses         1456     1589     +133     
- Partials        225      232       +7     
Flag Coverage Δ Complexity Δ
#cli 79.27% <ø> (ø) 0.00 <ø> (ø)
#plugin 70.59% <27.17%> (-1.42%) 1350.00 <22.00> (+21.00) ⬇️

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

Impacted Files Coverage Δ Complexity Δ
...stroforelasticsearch/ad/model/AnomalyDetector.java 66.27% <0.00%> (-22.62%) 46.00 <0.00> (ø)
...oforelasticsearch/ad/model/AnomalyDetectorJob.java 61.16% <0.00%> (-20.66%) 22.00 <0.00> (ø)
...stroforelasticsearch/ad/model/DetectorProfile.java 34.39% <0.00%> (-4.18%) 14.00 <0.00> (ø)
...n/opendistroforelasticsearch/ad/model/Feature.java 76.36% <0.00%> (-19.10%) 13.00 <0.00> (ø)
...sticsearch/ad/model/IntervalTimeConfiguration.java 63.63% <0.00%> (-36.37%) 8.00 <0.00> (ø)
...earch/ad/transport/GetAnomalyDetectorResponse.java 0.00% <0.00%> (ø) 0.00 <0.00> (?)
...icsearch/ad/rest/RestGetAnomalyDetectorAction.java 42.10% <14.28%> (+23.28%) 4.00 <1.00> (-1.00) ⬆️
...d/transport/GetAnomalyDetectorTransportAction.java 51.21% <51.21%> (ø) 9.00 <9.00> (?)
...search/ad/transport/GetAnomalyDetectorRequest.java 96.77% <96.77%> (ø) 9.00 <9.00> (?)
...stroforelasticsearch/ad/AnomalyDetectorPlugin.java 93.54% <100.00%> (ø) 10.00 <0.00> (ø)
... and 8 more

@saratvemulapalli saratvemulapalli marked this pull request as ready for review October 9, 2020 09:46
public XContentBuilder toXContent(XContentBuilder builder) throws IOException {
return toXContent(builder, ToXContent.EMPTY_PARAMS);
}

public void writeTo(StreamOutput output) throws IOException {
Copy link
Contributor

Choose a reason for hiding this comment

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

Should we override Writeable.writeTo method like Feature class?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Sure thats a good point.
Will make changes for both AnomalyDetector and AnomalyDetectorJob

Copy link
Contributor

@ohltyler ohltyler 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 adding

Copy link
Contributor

@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 the change!

@saratvemulapalli saratvemulapalli merged commit de644de into master Oct 12, 2020
@saratvemulapalli saratvemulapalli deleted the fgac-get-api branch October 13, 2020 00:05
@ohltyler ohltyler added the enhancement New feature or request label Oct 19, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants