-
Notifications
You must be signed in to change notification settings - Fork 73
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
update the AD settings for opensearch. #47
Conversation
Signed-off-by: Alex <[email protected]>
@@ -137,7 +137,7 @@ public void testHistoricalDetectorWithValidDateRange() throws IOException, Inter | |||
DetectionDateRange dateRange = new DetectionDateRange(startTime, endTime); | |||
ADBatchAnomalyResultRequest request = adBatchAnomalyResultRequest(dateRange); | |||
client().execute(ADBatchAnomalyResultAction.INSTANCE, request).actionGet(5000); | |||
Thread.sleep(10000); | |||
Thread.sleep(20000); |
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.
This will make our tests slower and slower when adding more tests. We want to avoid even though the execute finishes quickly and we still sleep 20 seconds. You can use a CountDownLatch to wait while the client().execute is running. See an example in EntityProfileRunnerTests.stateTestTemplate
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.
Thank you very much for the suggestion!
I have checked with Yaliang, he is still working on the batching change and need more time to optimize the unit tests.
I'm planning to update these unit tests after Yaliang finished his PRs.
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.
I will fix UTs related with AD batch tasks after all changes ready. I'm ok if @spbjss willing to put some effort to fix it now or leave it to later to avoid duplicate effort.
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.
sounds good. Will approve the PR once you get the build issue figured out. Please let me know.
@@ -40,8 +40,8 @@ private AnomalyDetectorSettings() {} | |||
|
|||
public static final Setting<Integer> MAX_SINGLE_ENTITY_ANOMALY_DETECTORS = Setting | |||
.intSetting( | |||
"opendistro.anomaly_detection.max_anomaly_detectors", | |||
1000, | |||
"opensearch.anomaly_detection.max_anomaly_detectors", |
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.
I know @saratvemulapalli has been saying that we would want these to be plugins.
just to avoid renaming again :) Care to comment?
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.
I think it was miss on our side, we haven't updated the guidance. I would prefer to have plugins
instead of opensearch
.
Can we update the doc: https://github.com/opensearch-project/opensearch-plugins/blob/main/CONVENTIONS.md#settings
Also let folks working on JobScheduler to take care of it as well.
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.
Do you mean we should change "opensearch.anomaly_detection.xxx" to "plugins.anomaly_detection.xxx"?
Sure, I will make that change.
Thank you for the comments!
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.
Yes please. Thanks Alex!
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.
And why would we not make this anomaly_detection.max_anomaly_detectors
? That's what k-nn is doing, for example.
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.
Definitely that works too. But I would love to have consistency across different pieces in the plugins.
And, we have decided to go with that as we have already discussed in the public:
opensearch-project/opensearch-plugins#13
https://discuss.opendistrocommunity.dev/t/thoughts-on-having-opensearch-identifier-in-all-things-plugins/5855
I am not opposed to either way but since we have taken a decision in the public, I would prefer to stick with it unless we see strong contentions to why that doesnt work. What do you think?
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.
A-OK by me to include plugins
. opensearch-project/opensearch-plugins#31
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.
Haha oncall :/, thanks for the change!
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.
Thank you very much for the input!
I have submitted a commits to update "opensearch" to "plugins"
Signed-off-by: Alex <[email protected]>
Signed-off-by: Alex <[email protected]>
latest code which is requred to support the setting change. Signed-off-by: Alex <[email protected]>
From CI workflow log, the compile can pass, but integTest failed, error message
The integTest will always use |
Several options to unblock the integTest,
|
@ylwu-amzn @spbjss There were code changes to make the backward compatibility happen in OpenSearch. The CI should run a build out of 1.x branch of OpenSearch. @dblock action items for us:
|
@ylwu-amzn @spbjss would you please followup with infra team on (1)? cc: @bbarani |
Also can we open an issue in opensearch-build to track this? |
Talked with Peter @peterzhuamazon , we will have a new tarball tomorrow. Do we need to change the tarball link used in integTest ? Who will change it? @dblock @saratvemulapalli |
… 1.0.0-beta1 to 1.x 2. Update the code import from opendistro to opensearch 3. Update the CI workflow script to apply the dependencis version change. Signed-off-by: Alex <[email protected]>
Signed-off-by: Alex <[email protected]>
Signed-off-by: Alex <[email protected]>
Signed-off-by: Alex <[email protected]>
As a general rule of thumb when we need something we should be opening issues. I got pinged by several people about this, so opened opensearch-project/opensearch-build#39 and just point them to it. |
@spbjss who opened this PR wants it to get to green so I imagine he would ;) |
Haha I think the link should work, we have agreed upon a format between Infra and Opensearch, Distribution Downloader should be able to handle that. |
Signed-off-by: Alex <[email protected]>
I could change the tar url of the integration test to "https://artifacts.opensearch.org/releases/core/opensearch/1.0.0-rc1/opensearch-1.0.0-rc1-linux-x64.tar.gz", waiting for infrastructure team to build the rc1 artifact. |
Codecov Report
@@ Coverage Diff @@
## main #47 +/- ##
============================================
+ Coverage 79.28% 79.41% +0.12%
- Complexity 2691 2692 +1
============================================
Files 242 243 +1
Lines 11065 11123 +58
Branches 1012 1012
============================================
+ Hits 8773 8833 +60
+ Misses 1878 1876 -2
Partials 414 414
Flags with carried forward coverage won't be shown. Click here to find out more.
|
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.
Good stuff.
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.
Looks great!
@@ -33,37 +33,37 @@ jobs: | |||
with: | |||
repository: 'opensearch-project/OpenSearch' | |||
path: OpenSearch | |||
ref: 'main' | |||
ref: '1.x' |
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.
Yay!
|
||
# dependencies: common-utils | ||
- name: Checkout common-utils | ||
uses: actions/checkout@v2 | ||
with: | ||
ref: '1.0.0-beta1' | ||
ref: 'main' # TODO: update to the right branch name once it's ready. e.g. 1.x |
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.
We should add instructions for our branching strategy for plugins in the plugins repo. @dblock
I can take care of it.
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.
Please do.
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.
Signed-off-by: Alex [email protected]
Description
Rename plugin settings from opendistro to opensearch.
Issues Resolved
#40
Check List
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.