Skip to content

Commit

Permalink
Bumping anomaly-detection to 1.1.0.0 to use OpenSearch (main) 1.1.0 (#…
Browse files Browse the repository at this point in the history
  • Loading branch information
VachaShah authored and ohltyler committed Sep 1, 2021
1 parent 81c0ae8 commit 3cc6b09
Show file tree
Hide file tree
Showing 4 changed files with 18 additions and 18 deletions.
22 changes: 11 additions & 11 deletions .github/workflows/CI.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,37 +33,37 @@ jobs:
with:
repository: 'opensearch-project/OpenSearch'
path: OpenSearch
ref: '1.0'
ref: 'main'
- name: Build OpenSearch
working-directory: ./OpenSearch
run: ./gradlew publishToMavenLocal -Dbuild.snapshot=false
run: ./gradlew publishToMavenLocal

# dependencies: common-utils
- name: Checkout common-utils
uses: actions/checkout@v2
with:
ref: '1.0'
ref: 'main'
repository: 'opensearch-project/common-utils'
path: common-utils
- name: Build common-utils
working-directory: ./common-utils
run: ./gradlew publishToMavenLocal -Dopensearch.version=1.0.0
run: ./gradlew publishToMavenLocal -Dopensearch.version=1.1.0-SNAPSHOT

# dependencies: job-scheduler
- name: Checkout job-scheduler
uses: actions/checkout@v2
with:
ref: '1.0'
ref: 'main'
repository: 'opensearch-project/job-scheduler'
path: job-scheduler

- name: Build job-scheduler
working-directory: ./job-scheduler
run: ./gradlew publishToMavenLocal -Dopensearch.version=1.0.0 -Dbuild.snapshot=false
run: ./gradlew publishToMavenLocal -Dopensearch.version=1.1.0-SNAPSHOT -Dbuild.snapshot=false
- name: Assemble job-scheduler
working-directory: ./job-scheduler
run: |
./gradlew assemble -Dopensearch.version=1.0.0 -Dbuild.snapshot=false
./gradlew assemble -Dopensearch.version=1.1.0-SNAPSHOT -Dbuild.snapshot=false
echo "Creating ../src/test/resources/job-scheduler ..."
mkdir -p ../src/test/resources/job-scheduler
pwd
Expand All @@ -75,11 +75,11 @@ jobs:
- name: Build and Run Tests
run: |
./gradlew build -Dopensearch.version=1.0.0
./gradlew build -Dopensearch.version=1.1.0-SNAPSHOT
- name: Publish to Maven Local
run: |
./gradlew publishToMavenLocal -Dopensearch.version=1.0.0
./gradlew publishToMavenLocal -Dopensearch.version=1.1.0-SNAPSHOT
- name: Multi Nodes Integration Testing
run: |
Expand All @@ -91,8 +91,8 @@ jobs:
## version=`echo $plugin|awk -F- '{print $4}'| cut -d. -f 1-3`
## plugin_version=`echo $plugin|awk -F- '{print $4}'| cut -d. -f 1-4`
## TODO: remove these two hard code versions below after GA release
version=1.0.0
plugin_version=1.0.0.0
version=1.1.0-SNAPSHOT
plugin_version=1.1.0.0
echo $version
cd ..
if docker pull opensearchstaging/opensearch:$version
Expand Down
10 changes: 5 additions & 5 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -31,9 +31,9 @@ import org.opensearch.gradle.testclusters.StandaloneRestIntegTestTask
buildscript {
ext {
opensearch_group = "org.opensearch"
opensearch_version = System.getProperty("opensearch.version", "1.0.0")
common_utils_version = System.getProperty("common_utils.version", "1.0.0.0")
job_scheduler_version = System.getProperty("job_scheduler.version", "1.0.0.0")
opensearch_version = System.getProperty("opensearch.version", "1.1.0-SNAPSHOT")
common_utils_version = System.getProperty("common_utils.version", "1.1.0.0")
job_scheduler_version = System.getProperty("job_scheduler.version", "1.1.0.0")
}

repositories {
Expand Down Expand Up @@ -63,7 +63,7 @@ repositories {
}

ext {
opensearchVersion = System.getProperty("opensearch.version", "1.0.0")
opensearchVersion = System.getProperty("opensearch.version", "1.1.0")
isSnapshot = "true" == System.getProperty("build.snapshot", "true")
}

Expand Down Expand Up @@ -274,7 +274,7 @@ String bwcFilePath = "src/test/resources/org/opensearch/ad/bwc/"
testClusters {
"${baseName}" {
testDistribution = "ARCHIVE"
versions = ["7.10.2","1.0.0"]
versions = ["7.10.2","1.1.0-SNAPSHOT"]
numberOfNodes = 3
plugin(provider(new Callable<RegularFile>(){
@Override
Expand Down
3 changes: 1 addition & 2 deletions src/main/java/org/opensearch/ad/util/Bwc.java
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,6 @@ public class Bwc {
* @return whether the version support multiple category fields
*/
public static boolean supportMultiCategoryFields(Version version) {
// TODO: remove DISABLE_BWC before 1.1 release
return DISABLE_BWC || version.after(Version.V_1_0_0);
return version.after(Version.V_1_0_0);
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -118,6 +118,7 @@ public void testNormal() throws IOException, JsonPathNotFoundException {
nodeRequestOut.setVersion(Version.V_1_0_0);
nodeRequest.writeTo(nodeRequestOut);
StreamInput siNode = nodeRequestOut.bytes().streamInput();
siNode.setVersion(Version.V_1_0_0);

CronNodeRequest nodeResponseRead = new CronNodeRequest(siNode);

Expand Down

0 comments on commit 3cc6b09

Please sign in to comment.