-
Notifications
You must be signed in to change notification settings - Fork 49
/
Copy pathbuild.gradle.kts
121 lines (108 loc) · 4.47 KB
/
build.gradle.kts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
plugins {
`java-library`
`maven-publish`
}
apply(plugin = "project")
subprojects {
group = "core.framework"
version = "9.1.5"
}
val elasticVersion = "8.15.0"
val jacksonVersion = "2.17.2"
val junitVersion = "5.11.3"
val mockitoVersion = "5.14.2"
val assertjVersion = "3.26.3"
project("core-ng-api") {
apply(plugin = "lib")
}
project("core-ng") {
apply(plugin = "lib")
dependencies {
api(project(":core-ng-api"))
api("org.slf4j:slf4j-api:2.0.16")
implementation("org.javassist:javassist:3.30.2-GA")
implementation("com.fasterxml.jackson.module:jackson-module-afterburner:${jacksonVersion}")
implementation("com.fasterxml.jackson.datatype:jackson-datatype-jsr310:${jacksonVersion}")
implementation("com.squareup.okhttp3:okhttp:4.12.0@jar")
implementation("com.squareup.okio:okio:3.2.0") // okio 3.3.0 has synchronization issue with virtual thread
implementation("org.jetbrains.kotlin:kotlin-stdlib:2.0.20")
implementation("io.undertow:undertow-core:2.3.10.Final") // undertow 2.3.11+ has memory leak issue, 2.3.17+ has much worse memory consumption
implementation("org.apache.kafka:kafka-clients:3.9.0")
compileOnly("org.jboss.logging:jboss-logging-annotations:2.2.1.Final")
compileOnly("com.github.spotbugs:spotbugs-annotations:4.8.3")
testImplementation("org.junit.jupiter:junit-jupiter-api:${junitVersion}")
testImplementation("org.mockito:mockito-junit-jupiter:${mockitoVersion}")
testImplementation("org.assertj:assertj-core:${assertjVersion}")
testRuntimeOnly("org.junit.jupiter:junit-jupiter-engine:${junitVersion}")
testRuntimeOnly("org.junit.platform:junit-platform-launcher")
testRuntimeOnly("org.hsqldb:hsqldb:2.7.3")
}
}
project("core-ng-test") {
apply(plugin = "lib")
dependencies {
api("org.junit.jupiter:junit-jupiter-api:${junitVersion}")
api("org.mockito:mockito-junit-jupiter:${mockitoVersion}")
api("org.assertj:assertj-core:${assertjVersion}")
implementation(project(":core-ng"))
implementation("org.junit.jupiter:junit-jupiter-engine:${junitVersion}")
implementation("org.junit.platform:junit-platform-launcher")
testRuntimeOnly("org.hsqldb:hsqldb:2.7.3")
}
}
project("core-ng-mongo") {
apply(plugin = "lib")
dependencies {
api(project(":core-ng"))
api("org.mongodb:mongodb-driver-sync:5.2.1")
testImplementation(project(":core-ng-test"))
}
}
project("core-ng-mongo-test") {
apply(plugin = "lib")
dependencies {
implementation(project(":core-ng-test"))
implementation(project(":core-ng-mongo"))
implementation("de.bwaldvogel:mongo-java-server:1.46.0")
}
}
project("core-ng-search") {
apply(plugin = "lib")
dependencies {
api(project(":core-ng"))
api("co.elastic.clients:elasticsearch-java:${elasticVersion}")
implementation("com.fasterxml.jackson.core:jackson-databind:${jacksonVersion}")
testImplementation(project(":core-ng-test"))
}
}
project("core-ng-search-test") {
apply(plugin = "lib")
dependencies {
implementation(project(":core-ng-test"))
implementation(project(":core-ng-search"))
implementation("org.elasticsearch:elasticsearch:${elasticVersion}")
implementation("org.elasticsearch.plugin:transport-netty4:${elasticVersion}")
implementation("org.codelibs.elasticsearch.module:mapper-extras:${elasticVersion}") // used by elasticsearch scaled_float
implementation("org.codelibs.elasticsearch.module:lang-painless:${elasticVersion}")
implementation("org.codelibs.elasticsearch.module:analysis-common:${elasticVersion}") // used by elasticsearch stemmer
implementation("org.codelibs.elasticsearch.module:reindex:${elasticVersion}@jar") // used by elasticsearch deleteByQuery
}
}
val mavenURL = project.properties["mavenURL"] as String? // usage: "gradlew -PmavenURL=/path clean publish"
subprojects {
if (mavenURL != null && project.name.startsWith("core-ng")) {
apply(plugin = "maven-publish")
val mavenDir = file(mavenURL)
assert(mavenDir.exists())
publishing {
publications {
create<MavenPublication>("maven") {
from(components["java"])
}
}
repositories {
maven { url = uri(mavenURL) }
}
}
}
}