Skip to content

Commit

Permalink
Merge branch '2.x' into backport/backport-748-to-2.x
Browse files Browse the repository at this point in the history
Signed-off-by: Derek Ho <dxho@amazon.com>
  • Loading branch information
derek-ho authored Aug 15, 2023
2 parents 5094f04 + 07c4494 commit d31d78a
Show file tree
Hide file tree
Showing 72 changed files with 454 additions and 396 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/draft-release-notes-workflow.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,6 @@ jobs:
with:
config-name: draft-release-notes-config.yml
tag: (None)
version: 2.6.0.0
version: 2.10.0.0
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
9 changes: 4 additions & 5 deletions .github/workflows/maven-publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,10 @@ name: Publish snapshots to maven
on:
workflow_dispatch:
push:
branches: [
main
1.*
2.*
]
branches:
- main
- '1.3'
- 2.x

jobs:
build-and-publish-snapshots:
Expand Down
29 changes: 10 additions & 19 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ buildscript {
opensearch_group = "org.opensearch"

isSnapshot = "true" == System.getProperty("build.snapshot", "true")
opensearch_version = System.getProperty("opensearch.version", "2.6.0-SNAPSHOT")
opensearch_version = System.getProperty("opensearch.version", "2.10.0-SNAPSHOT")
buildVersionQualifier = System.getProperty("build.version_qualifier", "")
// 2.0.0-rc1-SNAPSHOT -> 2.0.0.0-rc1-SNAPSHOT
version_tokens = opensearch_version.tokenize('-')
Expand All @@ -26,7 +26,7 @@ buildscript {

common_utils_version = System.getProperty("common_utils.version", opensearch_build)
job_scheduler_version = System.getProperty("job_scheduler.version", opensearch_build)
kotlin_version = System.getProperty("kotlin.version", "1.6.0")
kotlin_version = System.getProperty("kotlin.version", "1.8.21")
jackson_version = "2.14.1"
}

Expand All @@ -41,8 +41,8 @@ buildscript {
classpath "${opensearch_group}.gradle:build-tools:${opensearch_version}"
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:${kotlin_version}"
classpath "org.jetbrains.kotlin:kotlin-allopen:${kotlin_version}"
classpath "io.gitlab.arturbosch.detekt:detekt-gradle-plugin:1.21.0"
classpath "org.jacoco:org.jacoco.agent:0.8.5"
classpath "io.gitlab.arturbosch.detekt:detekt-gradle-plugin:1.22.0"
classpath "org.jacoco:org.jacoco.agent:0.8.8"
}
}

Expand Down Expand Up @@ -116,6 +116,7 @@ configurations {
ktlint
testCompile
testRuntime
zipArchive
}

detekt {
Expand All @@ -133,7 +134,7 @@ configurations.all {
force "org.jetbrains.kotlin:kotlin-stdlib:${kotlin_version}"
force "org.jetbrains.kotlin:kotlin-stdlib-common:${kotlin_version}"
force "com.fasterxml.jackson.dataformat:jackson-dataformat-cbor:2.11.4"
force "org.yaml:snakeyaml:1.32"
force "org.yaml:snakeyaml:2.0"
}
}

Expand Down Expand Up @@ -167,14 +168,14 @@ repositories {
}

dependencies {
zipArchive group: 'org.opensearch.plugin', name:'opensearch-job-scheduler', version: "${opensearch_build}"
implementation "org.opensearch:opensearch:${opensearch_version}"
implementation "org.jetbrains.kotlin:kotlin-stdlib:${kotlin_version}"
implementation "org.jetbrains.kotlin:kotlin-stdlib-common:${kotlin_version}"
implementation "org.jetbrains.kotlinx:kotlinx-coroutines-core:1.3.9"
implementation "${group}:common-utils:${common_utils_version}"
compileOnly "${group}:opensearch-job-scheduler-spi:${job_scheduler_version}"
implementation group: 'com.google.guava', name: 'guava', version: '31.0.1-jre'
implementation "org.json:json:20180813"
implementation "org.json:json:20230227"
implementation group: 'com.github.wnameless.json', name: 'json-flattener', version: '0.15.1'
// json-base, jackson-databind, jackson-annotations are transitive dependencies by json-flattener
implementation group: 'com.github.wnameless.json', name: 'json-base', version: '2.2.1'
Expand All @@ -192,7 +193,7 @@ dependencies {
testImplementation "org.opensearch.test:framework:${opensearch_version}"
testImplementation "org.jetbrains.kotlin:kotlin-test:${kotlin_version}"
testImplementation "com.nhaarman.mockitokotlin2:mockito-kotlin:2.2.0"
testImplementation "org.mockito:mockito-core:5.1.0"
testImplementation "org.mockito:mockito-core:${versions.mockito}"
testImplementation "org.mockito:mockito-junit-jupiter:4.7.0"
testImplementation 'com.google.code.gson:gson:2.8.9'

Expand Down Expand Up @@ -293,8 +294,6 @@ Zip bundle = (Zip) project.getTasks().getByName("bundlePlugin");
integTest.dependsOn(bundle)
integTest.getClusters().forEach{c -> c.plugin(project.getObjects().fileProperty().value(bundle.getArchiveFile()))}

String jobSchedulerURL = "https://ci.opensearch.org/ci/dbc/distribution-build-opensearch/" + opensearch_version.replace("-SNAPSHOT", "") + "/latest/linux/x64/tar/builds/opensearch/plugins/opensearch-job-scheduler-" + opensearch_build.replace("-SNAPSHOT", "") + ".zip"

testClusters.integTest {
testDistribution = "INTEG_TEST"
// need to install job-scheduler first, need to assemble job-scheduler first
Expand All @@ -304,15 +303,7 @@ testClusters.integTest {
return new RegularFile() {
@Override
File getAsFile() {
File dir = new File("src/test/resources/job-scheduler")
if (!dir.exists()) {
dir.mkdirs()
}
File file = new File(dir, "opensearch-job-scheduler-" + opensearch_build + ".zip")
if (!file.exists()) {
new URL(jobSchedulerURL).withInputStream{ ins -> file.withOutputStream{ it << ins }}
}
return fileTree("src/test/resources/job-scheduler").getSingleFile()
return configurations.zipArchive.asFileTree.getSingleFile()
}
}
}
Expand Down
Binary file modified gradle/wrapper/gradle-wrapper.jar
Binary file not shown.
11 changes: 3 additions & 8 deletions gradle/wrapper/gradle-wrapper.properties
Original file line number Diff line number Diff line change
@@ -1,11 +1,6 @@
##
# Copyright OpenSearch Contributors
# SPDX-License-Identifier: Apache-2.0
##

#Wed Jul 29 13:30:55 PDT 2020
distributionUrl=https\://services.gradle.org/distributions/gradle-7.4.2-bin.zip
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
zipStorePath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-7.6.1-bin.zip
networkTimeout=10000
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
Loading

0 comments on commit d31d78a

Please sign in to comment.