-
Notifications
You must be signed in to change notification settings - Fork 75
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
Changes default version to 2.0.0-alpha1 and fixes CVE-2020-36518 #478
Merged
amitgalitz
merged 7 commits into
opensearch-project:main
from
amitgalitz:alpha1-abstractAD-fixes
Mar 31, 2022
Merged
Changes from all commits
Commits
Show all changes
7 commits
Select commit
Hold shift + click to select a range
e7cad31
fixed mappings return type based of core changes
amitgalitz cf6d320
fixed tests that used mapping type
amitgalitz f1aa0f3
updating jackson-databind to match core and fix CVE
amitgalitz f387fff
updating CI workflow
amitgalitz f4f3bc8
changed CI to use gradle's constant
amitgalitz 134503c
remove jdk14 support
amitgalitz 6129713
changed version tokenizing
amitgalitz File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -16,9 +16,18 @@ import org.opensearch.gradle.testclusters.StandaloneRestIntegTestTask | |
buildscript { | ||
ext { | ||
opensearch_group = "org.opensearch" | ||
opensearch_version = System.getProperty("opensearch.version", "2.0.0-SNAPSHOT") | ||
// 1.2.0 -> 1.2.0.0, and 1.2.0-SNAPSHOT -> 1.2.0.0-SNAPSHOT | ||
opensearch_build = opensearch_version.replaceAll(/(\.\d)([^\d]*)$/, '$1.0$2') | ||
isSnapshot = "true" == System.getProperty("build.snapshot", "true") | ||
opensearch_version = System.getProperty("opensearch.version", "2.0.0-alpha1-SNAPSHOT") | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Infra team fixed this part, you can refer to this PR https://github.com/opensearch-project/ml-commons/pull/262/files |
||
buildVersionQualifier = System.getProperty("build.version_qualifier") | ||
// 2.0.0-alpha1-SNAPSHOT -> 2.0.0.0-alpha1-SNAPSHOT | ||
version_tokens = opensearch_version.tokenize('-') | ||
opensearch_build = version_tokens[0] + '.0' | ||
if (buildVersionQualifier) { | ||
opensearch_build += "-${buildVersionQualifier}" | ||
} | ||
if (isSnapshot) { | ||
opensearch_build += "-SNAPSHOT" | ||
} | ||
common_utils_version = System.getProperty("common_utils.version", opensearch_build) | ||
job_scheduler_version = System.getProperty("job_scheduler.version", opensearch_build) | ||
} | ||
|
@@ -106,7 +115,7 @@ configurations.all { | |
if (it.state != Configuration.State.UNRESOLVED) return | ||
resolutionStrategy { | ||
force "joda-time:joda-time:${versions.joda}" | ||
force "com.fasterxml.jackson.core:jackson-core:2.12.6" | ||
force "com.fasterxml.jackson.core:jackson-core:2.13.2" | ||
force "commons-logging:commons-logging:${versions.commonslogging}" | ||
force "org.apache.httpcomponents:httpcore:${versions.httpcore}" | ||
force "commons-codec:commons-codec:${versions.commonscodec}" | ||
|
@@ -315,7 +324,7 @@ String bwcFilePath = "src/test/resources/org/opensearch/ad/bwc/" | |
testClusters { | ||
"${baseName}$i" { | ||
testDistribution = "ARCHIVE" | ||
versions = ["7.10.2","1.3.0-SNAPSHOT"] | ||
versions = ["7.10.2", "2.0.0-alpha1-SNAPSHOT"] | ||
numberOfNodes = 3 | ||
plugin(provider(new Callable<RegularFile>(){ | ||
@Override | ||
|
@@ -584,9 +593,9 @@ dependencies { | |
|
||
// force Jackson version to avoid version conflict issue | ||
implementation 'software.amazon.randomcutforest:randomcutforest-serialization:2.0.1' | ||
implementation "com.fasterxml.jackson.core:jackson-core:2.12.6" | ||
implementation "com.fasterxml.jackson.core:jackson-databind:2.12.6" | ||
implementation "com.fasterxml.jackson.core:jackson-annotations:2.12.6" | ||
implementation "com.fasterxml.jackson.core:jackson-core:2.13.2" | ||
implementation "com.fasterxml.jackson.core:jackson-databind:2.13.2.2" | ||
implementation "com.fasterxml.jackson.core:jackson-annotations:2.13.2" | ||
implementation files('lib/randomcutforest-parkservices-2.0.1.jar') | ||
implementation files('lib/randomcutforest-core-2.0.1.jar') | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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.
Infra team fixed this part, you can refer to this PR https://github.com/opensearch-project/ml-commons/pull/262/files
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.
Changed it to be the same as ml-commons
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.
Thanks, btw, make sure the built AD artifact name is
opensearch-anomaly-detection-2.0.0.0-alpha1-SNAPSHOT
. I see line 633Not sure what
project.version
isThere 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.
It actually gives a zip of
opensearch-anomaly-detection-2.0.0.0-SNAPSHOT
. Same case for ml-commons built zip (just tried on latest code) -> will investigate this, changing line 633 seems to have no effectThere 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.
oh,I guess infra team's fix break this part for
ml-commons
, will take a lookThere 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.
For
ml-commons
, this one can generate artifact with alpha1,./gradlew clean;./gradlew build -Dbuild.version_qualifier=alpha1
. But artifact generated by./gradlew build
has noalpha1
in name even we setopensearch_version = System.getProperty("opensearch.version", "2.0.0-alpha1-SNAPSHOT")
. @peterzhuamazon is this what we expected?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.
From @peterzhuamazon , we are going to move to rc1 soon. So just keep this code, we can change to rc1 later.