Skip to content

Commit

Permalink
Using jackson and jackson_databind version defined in OpenSearch (ope…
Browse files Browse the repository at this point in the history
…nsearch-project#1169)

Signed-off-by: Peng Huo <[email protected]>
(cherry picked from commit 5073215)
  • Loading branch information
penghuo committed Dec 15, 2022
1 parent 777bc5d commit 1ae47cc
Show file tree
Hide file tree
Showing 7 changed files with 27 additions and 24 deletions.
6 changes: 4 additions & 2 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,6 @@ buildscript {
ext {
opensearch_version = System.getProperty("opensearch.version", "2.4.1-SNAPSHOT")
spring_version = "5.3.22"
jackson_version = "2.14.1"
jackson_databind_version = "2.14.1"
isSnapshot = "true" == System.getProperty("build.snapshot", "true")
buildVersionQualifier = System.getProperty("build.version_qualifier", "")
version_tokens = opensearch_version.tokenize('-')
Expand Down Expand Up @@ -69,6 +67,10 @@ plugins {
id 'jacoco'
}

// import versions defined in https://github.com/opensearch-project/OpenSearch/blob/main/buildSrc/src/main/java/org/opensearch/gradle/OpenSearchJavaPlugin.java#L94
// versions https://github.com/opensearch-project/OpenSearch/blob/main/buildSrc/version.properties
apply plugin: 'opensearch.java'

// Repository on root level is for dependencies that project code depends on. And this block must be placed after plugins{}
repositories {
mavenLocal()
Expand Down
6 changes: 3 additions & 3 deletions core/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -45,9 +45,9 @@ dependencies {
api group: 'org.apache.commons', name: 'commons-lang3', version: '3.10'
api group: 'com.facebook.presto', name: 'presto-matching', version: '0.240'
api group: 'org.apache.commons', name: 'commons-math3', version: '3.6.1'
api "com.fasterxml.jackson.core:jackson-core:${jackson_version}"
api "com.fasterxml.jackson.core:jackson-databind:${jackson_databind_version}"
api "com.fasterxml.jackson.core:jackson-annotations:${jackson_version}"
api "com.fasterxml.jackson.core:jackson-core:${versions.jackson}"
api "com.fasterxml.jackson.core:jackson-databind:${versions.jackson_databind}"
api "com.fasterxml.jackson.core:jackson-annotations:${versions.jackson}"
api project(':common')

testImplementation('org.junit.jupiter:junit-jupiter:5.6.2')
Expand Down
7 changes: 4 additions & 3 deletions integ-test/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -66,9 +66,10 @@ configurations.all {
// enforce 1.1.3, https://www.whitesourcesoftware.com/vulnerability-database/WS-2019-0379
resolutionStrategy.force 'commons-codec:commons-codec:1.13'
resolutionStrategy.force 'com.google.guava:guava:31.0.1-jre'
resolutionStrategy.force "com.fasterxml.jackson.core:jackson-core:${jackson_version}"
resolutionStrategy.force "com.fasterxml.jackson.dataformat:jackson-dataformat-cbor:${jackson_version}"
resolutionStrategy.force "com.fasterxml.jackson.core:jackson-databind:${jackson_databind_version}"
resolutionStrategy.force "com.fasterxml.jackson.core:jackson-core:${versions.jackson}"
resolutionStrategy.force "com.fasterxml.jackson.dataformat:jackson-dataformat-cbor:${versions.jackson}"
resolutionStrategy.force "com.fasterxml.jackson.core:jackson-databind:${versions.jackson_databind}"

resolutionStrategy.force "org.jetbrains.kotlin:kotlin-stdlib:1.6.0"
resolutionStrategy.force "org.jetbrains.kotlin:kotlin-stdlib-common:1.6.0"
resolutionStrategy.force "com.squareup.okhttp3:okhttp:4.9.3"
Expand Down
6 changes: 3 additions & 3 deletions opensearch/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -32,9 +32,9 @@ dependencies {
api project(':core')
api group: 'org.opensearch', name: 'opensearch', version: "${opensearch_version}"
implementation "io.github.resilience4j:resilience4j-retry:1.5.0"
implementation group: 'com.fasterxml.jackson.core', name: 'jackson-core', version: "${jackson_version}"
implementation group: 'com.fasterxml.jackson.core', name: 'jackson-databind', version: "${jackson_databind_version}"
implementation group: 'com.fasterxml.jackson.dataformat', name: 'jackson-dataformat-cbor', version: "${jackson_version}"
implementation group: 'com.fasterxml.jackson.core', name: 'jackson-core', version: "${versions.jackson}"
implementation group: 'com.fasterxml.jackson.core', name: 'jackson-databind', version: "${versions.jackson_databind}"
implementation group: 'com.fasterxml.jackson.dataformat', name: 'jackson-dataformat-cbor', version: "${versions.jackson}"
implementation group: 'org.json', name: 'json', version:'20180813'
compileOnly group: 'org.opensearch.client', name: 'opensearch-rest-high-level-client', version: "${opensearch_version}"
implementation group: 'org.opensearch', name:'opensearch-ml-client', version: "${opensearch_build}"
Expand Down
12 changes: 6 additions & 6 deletions plugin/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -84,12 +84,12 @@ configurations.all {
// conflict with spring-jcl
exclude group: "commons-logging", module: "commons-logging"
// enforce 2.12.6, https://github.com/opensearch-project/sql/issues/424
resolutionStrategy.force "com.fasterxml.jackson.core:jackson-core:${jackson_version}"
resolutionStrategy.force "com.fasterxml.jackson.core:jackson-core:${versions.jackson}"
// enforce 1.1.3, https://www.whitesourcesoftware.com/vulnerability-database/WS-2019-0379
resolutionStrategy.force 'commons-codec:commons-codec:1.13'
resolutionStrategy.force 'com.google.guava:guava:31.0.1-jre'
resolutionStrategy.force "com.fasterxml.jackson.dataformat:jackson-dataformat-cbor:${jackson_version}"
resolutionStrategy.force "com.fasterxml.jackson.core:jackson-databind:${jackson_databind_version}"
resolutionStrategy.force "com.fasterxml.jackson.dataformat:jackson-dataformat-cbor:${versions.jackson}"
resolutionStrategy.force "com.fasterxml.jackson.core:jackson-databind:${versions.jackson_databind}"
resolutionStrategy.force "org.jetbrains.kotlin:kotlin-stdlib:1.6.0"
resolutionStrategy.force "org.jetbrains.kotlin:kotlin-stdlib-common:1.6.0"
resolutionStrategy.force "com.squareup.okhttp3:okhttp:4.9.3"
Expand All @@ -104,9 +104,9 @@ compileTestJava {

dependencies {
api group: 'org.springframework', name: 'spring-beans', version: "${spring_version}"
api "com.fasterxml.jackson.core:jackson-core:${jackson_version}"
api "com.fasterxml.jackson.core:jackson-databind:${jackson_databind_version}"
api "com.fasterxml.jackson.core:jackson-annotations:${jackson_version}"
api "com.fasterxml.jackson.core:jackson-core:${versions.jackson}"
api "com.fasterxml.jackson.core:jackson-databind:${versions.jackson_databind}"
api "com.fasterxml.jackson.core:jackson-annotations:${versions.jackson}"


api project(":ppl")
Expand Down
6 changes: 3 additions & 3 deletions prometheus/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,9 @@ repositories {
dependencies {
api project(':core')
implementation "io.github.resilience4j:resilience4j-retry:1.5.0"
implementation group: 'com.fasterxml.jackson.core', name: 'jackson-core', version: "${jackson_version}"
implementation group: 'com.fasterxml.jackson.core', name: 'jackson-databind', version: "${jackson_databind_version}"
implementation group: 'com.fasterxml.jackson.dataformat', name: 'jackson-dataformat-cbor', version: "${jackson_version}"
implementation group: 'com.fasterxml.jackson.core', name: 'jackson-core', version: "${versions.jackson}"
implementation group: 'com.fasterxml.jackson.core', name: 'jackson-databind', version: "${versions.jackson_databind}"
implementation group: 'com.fasterxml.jackson.dataformat', name: 'jackson-dataformat-cbor', version: "${versions.jackson}"
implementation group: 'com.squareup.okhttp3', name: 'okhttp', version: '4.9.3'
implementation 'com.github.babbel:okhttp-aws-signer:1.0.2'
implementation group: 'org.json', name: 'json', version: '20180813'
Expand Down
8 changes: 4 additions & 4 deletions protocol/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -30,9 +30,9 @@ plugins {

dependencies {
implementation group: 'com.google.guava', name: 'guava', version: '31.0.1-jre'
implementation group: 'com.fasterxml.jackson.core', name: 'jackson-core', version: "${jackson_version}"
implementation group: 'com.fasterxml.jackson.core', name: 'jackson-databind', version: "${jackson_databind_version}"
implementation group: 'com.fasterxml.jackson.dataformat', name: 'jackson-dataformat-cbor', version: "${jackson_version}"
implementation group: 'com.fasterxml.jackson.core', name: 'jackson-core', version: "${versions.jackson}"
implementation group: 'com.fasterxml.jackson.core', name: 'jackson-databind', version: "${versions.jackson_databind}"
implementation group: 'com.fasterxml.jackson.dataformat', name: 'jackson-dataformat-cbor', version: "${versions.jackson}"
implementation 'com.google.code.gson:gson:2.8.9'
implementation project(':core')
implementation project(':opensearch')
Expand All @@ -44,7 +44,7 @@ dependencies {
}

configurations.all {
resolutionStrategy.force "com.fasterxml.jackson.core:jackson-databind:${jackson_databind_version}"
resolutionStrategy.force "com.fasterxml.jackson.core:jackson-databind:${versions.jackson_databind}"
}

test {
Expand Down

0 comments on commit 1ae47cc

Please sign in to comment.