@@ -8,12 +8,12 @@ import org.jetbrains.kotlin.gradle.tasks.KotlinCompile
88plugins {
99 java
1010 `java- library`
11- id(" com.github.spotbugs" ) version " 4.4.5"
1211 checkstyle
1312 jacoco
14- kotlin(" jvm" ) version " 1.3.72" apply false
13+ id(" com.github.spotbugs" )
14+ kotlin(" jvm" ) apply false
1515 id(" org.jlleitschuh.gradle.ktlint" ) apply false
16- id(" io.gitlab.arturbosch.detekt" ) version " 1.10.0 " apply false
16+ id(" io.gitlab.arturbosch.detekt" ) apply false
1717}
1818
1919allprojects {
@@ -27,6 +27,13 @@ allprojects {
2727 }
2828}
2929
30+ val assertJVersion: String by project
31+ val junitJupiterVersion: String by project
32+ val logbackVersion: String by project
33+ val lombokVersion: String by project
34+ val mockitoVersion: String by project
35+ val spotbugsVersion: String by project
36+
3037subprojects {
3138 val isKotlinProject = project.name.contains(" kotlin" ) || project.name.contains(" ktor" )
3239 apply (plugin = " java-library" )
@@ -45,65 +52,25 @@ subprojects {
4552 }
4653
4754 dependencies {
48- // AWS
49- implementation(platform(" software.amazon.awssdk:bom:2.13.66" ))
50- api(platform(" software.amazon.awssdk:bom:2.13.58" ))
51-
52- // Spring Boot
53- api(platform(" org.springframework.boot:spring-boot-dependencies:2.3.2.RELEASE" ))
54-
5555 // Lombok
56- compileOnly(" org.projectlombok:lombok:1.18.12 " )
57- annotationProcessor(" org.projectlombok:lombok:1.18.12 " )
58- testCompileOnly(" org.projectlombok:lombok:1.18.12 " )
59- testAnnotationProcessor(" org.projectlombok:lombok:1.18.12 " )
56+ compileOnly(" org.projectlombok:lombok:$lombokVersion " )
57+ annotationProcessor(" org.projectlombok:lombok:$lombokVersion " )
58+ testCompileOnly(" org.projectlombok:lombok:$lombokVersion " )
59+ testAnnotationProcessor(" org.projectlombok:lombok:$lombokVersion " )
6060
6161 // Testing (JUnit, Mockito, etc)
62- testImplementation(" org.junit.jupiter:junit-jupiter:5.6.2" )
63- testImplementation(" org.mockito:mockito-junit-jupiter:3.4.6" )
64- testImplementation(" org.mockito:mockito-core:3.4.6" )
65- testImplementation(" org.hamcrest:hamcrest:2.2" )
66- testImplementation(" org.assertj:assertj-core:3.16.1" )
62+ testImplementation(" org.assertj:assertj-core:$assertJVersion " )
63+ testImplementation(" org.junit.jupiter:junit-jupiter:$junitJupiterVersion " )
64+ testImplementation(" org.mockito:mockito-junit-jupiter:$mockitoVersion " )
65+ testImplementation(" org.mockito:mockito-core:$mockitoVersion " )
6766
6867 // Logging for tests
69- testImplementation(" ch.qos.logback:logback-core" )
70- testImplementation(" ch.qos.logback:logback-classic" )
68+ testImplementation(" ch.qos.logback:logback-core: $logbackVersion " )
69+ testImplementation(" ch.qos.logback:logback-classic: $logbackVersion " )
7170
7271 if (! isKotlinProject) {
7372 // SpotBugs
74- spotbugs(" com.github.spotbugs:spotbugs:4.1.1" )
75- }
76-
77- constraints {
78- // Jackson
79- implementation(" com.fasterxml.jackson.core:jackson-databind:2.11.1" )
80-
81- // Avro/Spring Cloud Schema Registry
82- implementation(" org.apache.avro:avro:1.10.0" )
83- implementation(" org.springframework.cloud:spring-cloud-schema-registry-client:1.0.7.RELEASE" )
84-
85- // Proxying
86- implementation(" cglib:cglib:3.3.0" )
87-
88- // Slf4j
89- implementation(" org.slf4j:slf4j-api:1.7.30" )
90-
91- // Brave
92- implementation(" io.zipkin.brave:brave:5.12.4" )
93- implementation(" io.zipkin.brave:brave-context-slf4j:5.12.4" )
94- implementation(" io.zipkin.brave:brave-tests:5.12.4" )
95-
96- // ElasticMQ
97- implementation(" org.elasticmq:elasticmq-rest-sqs_2.12:0.15.6" )
98-
99- // AWS Xray
100- implementation(" com.amazonaws:aws-xray-recorder-sdk-core:2.6.1" )
101- implementation(" com.amazonaws:aws-xray-recorder-sdk-spring:2.6.1" )
102- implementation(" com.amazonaws:aws-xray-recorder-sdk-aws-sdk-v2-instrumentor:2.6.1" )
103-
104- // Logback (for tests)
105- implementation(" ch.qos.logback:logback-core:1.2.3" )
106- implementation(" ch.qos.logback:logback-classic:1.2.3" )
73+ spotbugs(" com.github.spotbugs:spotbugs:$spotbugsVersion " )
10774 }
10875 }
10976
0 commit comments