Skip to content

Commit

Permalink
fixed current version fetch issue and bumped to 1.3.4
Browse files Browse the repository at this point in the history
Signed-off-by: Amit Galitzky <amgalitz@amazon.com>
  • Loading branch information
amitgalitz committed Jul 12, 2022
1 parent 29da6f8 commit d69bc97
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 22 deletions.
22 changes: 11 additions & 11 deletions .github/workflows/CI.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,28 +29,28 @@ jobs:

- name: Assemble anomaly-detection
run: |
./gradlew assemble -Dopensearch.version=1.3.3-SNAPSHOT
echo "Creating ./src/test/resources/org/opensearch/ad/bwc/anomaly-detection/1.3.3.0-SNAPSHOT ..."
mkdir -p ./src/test/resources/org/opensearch/ad/bwc/anomaly-detection/1.3.3.0-SNAPSHOT
echo "Copying ./build/distributions/*.zip to ./src/test/resources/org/opensearch/ad/bwc/anomaly-detection/1.3.3.0-SNAPSHOT ..."
./gradlew assemble -Dopensearch.version=1.3.4-SNAPSHOT
echo "Creating ./src/test/resources/org/opensearch/ad/bwc/anomaly-detection/1.3.4.0-SNAPSHOT ..."
mkdir -p ./src/test/resources/org/opensearch/ad/bwc/anomaly-detection/1.3.4.0-SNAPSHOT
echo "Copying ./build/distributions/*.zip to ./src/test/resources/org/opensearch/ad/bwc/anomaly-detection/1.3.4.0-SNAPSHOT ..."
ls ./build/distributions/
cp ./build/distributions/*.zip ./src/test/resources/org/opensearch/ad/bwc/anomaly-detection/1.3.3.0-SNAPSHOT
echo "Copied ./build/distributions/*.zip to ./src/test/resources/org/opensearch/ad/bwc/anomaly-detection/1.3.3.0-SNAPSHOT ..."
ls ./src/test/resources/org/opensearch/ad/bwc/anomaly-detection/1.3.3.0-SNAPSHOT
cp ./build/distributions/*.zip ./src/test/resources/org/opensearch/ad/bwc/anomaly-detection/1.3.4.0-SNAPSHOT
echo "Copied ./build/distributions/*.zip to ./src/test/resources/org/opensearch/ad/bwc/anomaly-detection/1.3.4.0-SNAPSHOT ..."
ls ./src/test/resources/org/opensearch/ad/bwc/anomaly-detection/1.3.4.0-SNAPSHOT
- name: Build and Run Tests
run: |
./gradlew build -Dopensearch.version=1.3.3-SNAPSHOT
./gradlew build -Dopensearch.version=1.3.4-SNAPSHOT
- name: Publish to Maven Local
run: |
./gradlew publishToMavenLocal -Dopensearch.version=1.3.3-SNAPSHOT
./gradlew publishToMavenLocal -Dopensearch.version=1.3.4-SNAPSHOT
- name: Multi Nodes Integration Testing
run: |
./gradlew integTest -PnumNodes=3
- name: Pull and Run Docker
run: |
plugin=`ls build/distributions/*.zip`
version=1.3.3
plugin_version=1.3.3.0-SNAPSHOT
version=1.3.4
plugin_version=1.3.4.0-SNAPSHOT
echo Using OpenSearch $version with AD $plugin_version
cd ..
if docker pull opensearchstaging/opensearch:$version
Expand Down
15 changes: 4 additions & 11 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ buildscript {
ext {
opensearch_group = "org.opensearch"
isSnapshot = "true" == System.getProperty("build.snapshot", "true")
opensearch_version = System.getProperty("opensearch.version", "1.3.3-SNAPSHOT")
opensearch_version = System.getProperty("opensearch.version", "1.3.4-SNAPSHOT")
if (isSnapshot) {
plugin_version = opensearch_version.substring(0, opensearch_version.indexOf("-"))
} else {
Expand Down Expand Up @@ -336,7 +336,7 @@ String bwcAnomalyDetectionPath = bwcFilePath + "anomaly-detection/"
testClusters {
"${baseName}$i" {
testDistribution = "ARCHIVE"
versions = ["7.10.2","1.3.3-SNAPSHOT"]
versions = ["7.10.2","1.3.4-SNAPSHOT"]
numberOfNodes = 3
plugin(provider(new Callable<RegularFile>(){
@Override
Expand Down Expand Up @@ -405,15 +405,8 @@ List<Provider<RegularFile>> plugins = [
return new RegularFile() {
@Override
File getAsFile() {
if (new File("$project.rootDir/$bwcFilePath/anomaly-detection/$opensearch_build").exists()) {
project.delete(files("$project.rootDir/$bwcFilePath/anomaly-detection/$opensearch_build"))
}
project.mkdir bwcAnomalyDetectionPath + opensearch_build
ant.get(src: anomaly_detection_build_download,
dest: bwcAnomalyDetectionPath + opensearch_build,
httpusecaches: false)
return fileTree(bwcAnomalyDetectionPath + opensearch_build).getSingleFile()
}
return fileTree(bwcFilePath + "anomaly-detection/" + project.version).getSingleFile()
}
}
}
})
Expand Down

0 comments on commit d69bc97

Please sign in to comment.