diff --git a/alerting/build.gradle b/alerting/build.gradle index cedb207a0..0d7d19729 100644 --- a/alerting/build.gradle +++ b/alerting/build.gradle @@ -99,14 +99,12 @@ integTest.getClusters().forEach{c -> c.plugin(project.getObjects().fileProperty( def _numNodes = findProperty('numNodes') as Integer ?: 1 -String notificationsVersion = "2.0.0" -String notificationsQualifier = "rc1" String notificationsFilePath = "src/test/resources/notifications" String notificationsCoreFilePath = "src/test/resources/notifications-core" -String notificationsOpenDistroPlugin = "opensearch-notifications-" + notificationsVersion + ".0-" + notificationsQualifier + ".zip" -String notificationsCoreOpenDistroPlugin = "opensearch-notifications-core-" + notificationsVersion + ".0-" + notificationsQualifier + ".zip" -String notificationsRemoteFile = "https://ci.opensearch.org/ci/dbc/distribution-build-opensearch/" + notificationsVersion + "-" + notificationsQualifier + "/latest/linux/x64/tar/builds/opensearch/plugins/" + notificationsOpenDistroPlugin -String notificationsCoreRemoteFile = "https://ci.opensearch.org/ci/dbc/distribution-build-opensearch/" + notificationsVersion + "-" + notificationsQualifier + "/latest/linux/x64/tar/builds/opensearch/plugins/" + notificationsCoreOpenDistroPlugin +String notificationsPlugin = "opensearch-notifications-" + plugin_no_snapshot + ".zip" +String notificationsCorePlugin = "opensearch-notifications-core-" + plugin_no_snapshot + ".zip" +String notificationsRemoteFile = "https://ci.opensearch.org/ci/dbc/distribution-build-opensearch/" + opensearch_no_snapshot + "/latest/linux/x64/tar/builds/opensearch/plugins/" + notificationsPlugin +String notificationsCoreRemoteFile = "https://ci.opensearch.org/ci/dbc/distribution-build-opensearch/" + opensearch_no_snapshot + "/latest/linux/x64/tar/builds/opensearch/plugins/" + notificationsCorePlugin testClusters.integTest { testDistribution = "ARCHIVE" // Cluster shrink exception thrown if we try to set numberOfNodes to 1, so only apply if > 1 @@ -132,11 +130,11 @@ testClusters.integTest { dir.mkdirs() } - File f = new File(dir, notificationsCoreOpenDistroPlugin) + File f = new File(dir, notificationsCorePlugin) if (!f.exists()) { new URL(notificationsCoreRemoteFile).withInputStream{ ins -> f.withOutputStream{ it << ins }} } - fileTree("src/test/resources/notifications-core").getSingleFile() + fileTree(notificationsCoreFilePath).getSingleFile() } } })) @@ -151,11 +149,11 @@ testClusters.integTest { dir.mkdirs() } - File f = new File(dir, notificationsOpenDistroPlugin) + File f = new File(dir, notificationsPlugin) if (!f.exists()) { new URL(notificationsRemoteFile).withInputStream{ ins -> f.withOutputStream{ it << ins }} } - fileTree("src/test/resources/notifications").getSingleFile() + fileTree(notificationsFilePath).getSingleFile() } } })) @@ -261,7 +259,7 @@ task prepareBwcTests { if (!f.exists()) { new URL(notificationsCoreRemoteFile).withInputStream{ ins -> f.withOutputStream{ it << ins }} } - fileTree("src/test/resources/notifications-core").getSingleFile() + fileTree(notificationsCoreFilePath).getSingleFile() } } }), @@ -279,7 +277,7 @@ task prepareBwcTests { if (!f.exists()) { new URL(notificationsRemoteFile).withInputStream{ ins -> f.withOutputStream{ it << ins }} } - fileTree("src/test/resources/notifications").getSingleFile() + fileTree(notificationsFilePath).getSingleFile() } } }) diff --git a/alerting/src/test/resources/bwc/alerting/1.13.1.0/opendistro-alerting-1.13.1.0.zip b/alerting/src/test/resources/bwc/alerting/1.13.1.0/opendistro-alerting-1.13.1.0.zip new file mode 100644 index 000000000..f17758c88 Binary files /dev/null and b/alerting/src/test/resources/bwc/alerting/1.13.1.0/opendistro-alerting-1.13.1.0.zip differ diff --git a/build.gradle b/build.gradle index 2651c0da5..e30fced64 100644 --- a/build.gradle +++ b/build.gradle @@ -13,12 +13,15 @@ buildscript { // 2.0.0-rc1-SNAPSHOT -> 2.0.0.0-rc1-SNAPSHOT version_tokens = opensearch_version.tokenize('-') opensearch_build = version_tokens[0] + '.0' + plugin_no_snapshot = opensearch_build if (buildVersionQualifier) { opensearch_build += "-${buildVersionQualifier}" + plugin_no_snapshot += "-${buildVersionQualifier}" } if (isSnapshot) { opensearch_build += "-SNAPSHOT" } + opensearch_no_snapshot = opensearch_version.replace("-SNAPSHOT","") common_utils_version = System.getProperty("common_utils.version", opensearch_build) kotlin_version = '1.6.10' }