Skip to content

Commit

Permalink
Refactor mantis-shaded 3rd party dependency specifications
Browse files Browse the repository at this point in the history
first pass at refactor 3rd party dependency specifications for mantis-shaded and corresponding changes to root build.gradle. tbd - issue Netflix#194 and grouping (issue Netflix#345)
  • Loading branch information
mabelbot committed Mar 2, 2023
1 parent 1ddb23d commit 3f1770b
Show file tree
Hide file tree
Showing 2 changed files with 42 additions and 22 deletions.
25 changes: 25 additions & 0 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -45,12 +45,16 @@ ext.versions = [
fenzoVersion : '0.13.8',
flink : "1.14.2",
gsonVersion : "2.8.+",
guavaFailureAccessVersion : '1.0.1',
guavaVersion : '31.1-jre',
guiceVersion : "4.2.2",
hadoop : "2.7.7",
hdrHistogramVersion : '2.+',
httpComponentsVersion : '4.5.6',
icebergVersion : "0.14.+",
jacksonVersion : '2.12.+',
jctoolsVersion : "1.+",
jlineVersion : '0.9.94',
jodaTimeVersion : '2.+',
jsonVersion : '20180813',
junit4 : "4.11",
Expand All @@ -61,6 +65,7 @@ ext.versions = [
mockito : "2.18.+",
mockito3 : "3.+",
mqlVersion : '3.4.+',
nettyVersion3 : '3.7.0.Final',
nettyVersion : "4.1.34.Final",
parquetVersion : "1.12.0",
rxJavaMathVersion : "0.20.6",
Expand All @@ -71,6 +76,7 @@ ext.versions = [
slf4j : "1.7.0",
testngVersion : '6.14.+',
vavr : "0.9.2",
zookeeperVersion : '3.4.+',
]

ext.libraries = [
Expand All @@ -93,6 +99,12 @@ ext.libraries = [
commonsLang3 : 'org.apache.commons:commons-lang3:3.5',
configMagic : "org.skife.config:config-magic:${versions.configMagicVersion}",
cliParser : "com.github.spullara.cli-parser:cli-parser:${versions.cliParserVersion}",
curator : [
"org.apache.curator:curator-recipes:${versions.curatorVersion}",
"org.apache.curator:curator-framework:${versions.curatorVersion}",
"org.apache.curator:curator-client:${versions.curatorVersion}",
],
failureaccess : "com.google.guava:failureaccess:${versions.guavaFailureAccessVersion}",
fenzoCore : "com.netflix.fenzo:fenzo-core:${versions.fenzoVersion}",
fenzoTriggers : "com.netflix.fenzo:fenzo-triggers:${versions.fenzoVersion}",
flinkCore : "org.apache.flink:flink-core:${versions.flink}",
Expand All @@ -107,6 +119,7 @@ ext.libraries = [
"junit:junit-dep:${versions.junit4}",
],
gson : "com.google.code.gson:gson:${versions.gsonVersion}",
guava : "com.google.guava:guava:${versions.guavaVersion}",
guice : "com.google.inject:guice:${versions.guiceVersion}",
hadoopCommon : "org.apache.hadoop:hadoop-common:${versions.hadoop}",
hadoopS3 : "org.apache.hadoop:hadoop-aws:${versions.hadoop}",
Expand All @@ -120,8 +133,18 @@ ext.libraries = [
"org.apache.iceberg:iceberg-data:${versions.icebergVersion}",
"org.apache.iceberg:iceberg-parquet:${versions.icebergVersion}",
],
jackson : [
"com.fasterxml.jackson.core:jackson-annotations:${versions.jacksonVersion}",
"com.fasterxml.jackson.core:jackson-core:${versions.jacksonVersion}",
"com.fasterxml.jackson.core:jackson-databind:${versions.jacksonVersion}",
"com.fasterxml.jackson.datatype:jackson-datatype-jdk8:${versions.jacksonVersion}",
],
jacksonDatatypeJsr310 : "com.fasterxml.jackson.datatype:jackson-datatype-jsr310:${versions.jacksonVersion}",
jacksonModuleAfterburner : "com.fasterxml.jackson.module:jackson-module-afterburner:${versions.jacksonVersion}",
jacksonDataformatCbor : "com.fasterxml.jackson.dataformat:jackson-dataformat-cbor:${versions.jacksonVersion}",
jcip : "net.jcip:jcip-annotations:1.0",
jctools : "org.jctools:jctools-core:${versions.jctoolsVersion}",
jline : "jline:jline:${versions.jlineVersion}",
jodaTime : "joda-time:joda-time:${versions.jodaTimeVersion}",
json : "org.json:json:${versions.jsonVersion}",
junitJupiter : [
Expand All @@ -139,6 +162,7 @@ ext.libraries = [
mockitoCore3 : "org.mockito:mockito-core:${versions.mockito3}",
mockneat : "net.andreinc:mockneat:0.4.8",
mqlJvm : "io.mantisrx:mql-jvm:${versions.mqlVersion}",
netty : "io.netty:netty:${versions.nettyVersion}",
nettyAll : "io.netty:netty-all:${versions.nettyVersion}",
nettyBuffer : "io.netty:netty-buffer:${versions.nettyVersion}",
nettyCodec : "io.netty:netty-codec-http:${versions.nettyVersion}",
Expand All @@ -165,6 +189,7 @@ ext.libraries = [
vavrTest : "io.vavr:vavr-test:${versions.vavr}",
wiremock : "com.github.tomakehurst:wiremock-jre8:2.21.0",
zip4j : "net.lingala.zip4j:zip4j:2.9.0",
zookeeper : "org.apache.zookeeper:zookeeper:${versions.zookeeperVersion}"
]

allprojects {
Expand Down
39 changes: 17 additions & 22 deletions mantis-shaded/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -25,13 +25,13 @@ apply plugin: 'com.github.johnrengelman.shadow'
* On the second publish, you update all subprojects that depend on mantis-shaded
*/
ext {
jacksonVersion = '2.12.+'
guavaFailureAccessVersion = '1.0.1'
guavaVersion = '31.1-jre'
curatorVersion = '2.12.+'
zookeeperVersion = '3.4.+'
jlineVersion = '0.9.94'
nettyVersion = '3.7.0.Final'
// jacksonVersion = '2.12.+'
// guavaFailureAccessVersion = '1.0.1'
// guavaVersion = '31.1-jre'
// curatorVersion = '2.12.+'
// zookeeperVersion = '3.4.+'
// jlineVersion = '0.9.94'
// nettyVersion = '3.7.0.Final'
}

configurations {
Expand All @@ -43,26 +43,21 @@ configurations {

dependencies {
// Libraries to be shaded. Add their dependencies that do not need to be shaded as 'implementation' dependencies
shaded "com.fasterxml.jackson.core:jackson-annotations:$jacksonVersion"
shaded "com.fasterxml.jackson.core:jackson-core:$jacksonVersion"
shaded "com.fasterxml.jackson.core:jackson-databind:$jacksonVersion"
shaded "com.fasterxml.jackson.datatype:jackson-datatype-jdk8:$jacksonVersion"
shaded libraries.jackson

// TODO(sundaram): This can only be added when we can get rid of all ObjectMappers spilled throughout the codebase
// as the absence of this change would mean Instant for instance cannot be serialized by the existing ObjectMappers.
// @see <a href="https://github.com/Netflix/mantis/issues/194">Github issue describing the ObjectMapper problem</a>
shaded "com.fasterxml.jackson.datatype:jackson-datatype-jsr310:$jacksonVersion"
shaded "com.fasterxml.jackson.module:jackson-module-afterburner:$jacksonVersion"
shaded "com.fasterxml.jackson.dataformat:jackson-dataformat-cbor:$jacksonVersion"
shaded libraries.jacksonDatatypeJsr310
shaded libraries.jacksonModuleAfterburner
shaded libraries.jacksonDataformatCbor
shaded libraries.vavrJackson
shaded "com.google.guava:guava:$guavaVersion"
shaded "com.google.guava:failureaccess:$guavaFailureAccessVersion"
shaded "org.apache.curator:curator-recipes:$curatorVersion"
shaded "org.apache.curator:curator-framework:$curatorVersion"
shaded "org.apache.curator:curator-client:$curatorVersion"
shaded "org.apache.zookeeper:zookeeper:$zookeeperVersion"
shaded "jline:jline:$jlineVersion"
shaded "io.netty:netty:$nettyVersion"
shaded libraries.guava
shaded libraries.failureaccess
shaded libraries.curator
shaded libraries.zookeeper
shaded libraries.jline
shaded libraries.netty

implementation libraries.vavr
}
Expand Down

0 comments on commit 3f1770b

Please sign in to comment.