-
Notifications
You must be signed in to change notification settings - Fork 870
/
build.gradle.kts
78 lines (66 loc) · 2.38 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
plugins {
id("otel.java-conventions")
id("org.springframework.boot") version "3.3.0"
id("org.graalvm.buildtools.native")
}
description = "smoke-tests-otel-starter-spring-boot-reactive-3"
otelJava {
minJavaVersionSupported.set(JavaVersion.VERSION_17)
}
dependencies {
implementation(project(":instrumentation:spring:starters:spring-boot-starter"))
implementation(platform(org.springframework.boot.gradle.plugin.SpringBootPlugin.BOM_COORDINATES))
implementation(project(":smoke-tests-otel-starter:spring-boot-reactive-common"))
implementation("org.springframework.boot:spring-boot-starter-webflux")
implementation("org.springframework.boot:spring-boot-starter-data-r2dbc")
runtimeOnly("com.h2database:h2")
runtimeOnly("io.r2dbc:r2dbc-h2")
testImplementation("org.springframework.boot:spring-boot-starter-test")
testImplementation("io.projectreactor:reactor-test")
}
springBoot {
mainClass = "io.opentelemetry.spring.smoketest.OtelReactiveSpringStarterSmokeTestApplication"
}
tasks {
compileAotJava {
with(options) {
compilerArgs.add("-Xlint:-deprecation,-unchecked,none")
// To disable warnings/failure coming from the Java compiler during the Spring AOT processing
// -deprecation,-unchecked and none are required (none is not enough)
}
}
compileAotTestJava {
with(options) {
compilerArgs.add("-Xlint:-deprecation,-unchecked,none")
// To disable warnings/failure coming from the Java compiler during the Spring AOT processing
// -deprecation,-unchecked and none are required (none is not enough)
}
}
checkstyleAot {
isEnabled = false
}
checkstyleAotTest {
isEnabled = false
}
}
// To be able to execute the tests as GraalVM native executables
configurations.configureEach {
exclude("org.apache.groovy", "groovy")
exclude("org.apache.groovy", "groovy-json")
exclude("org.spockframework", "spock-core")
}
graalvmNative {
binaries.all {
// Workaround for https://github.com/junit-team/junit5/issues/3405
buildArgs.add("--initialize-at-build-time=org.junit.platform.launcher.core.LauncherConfig")
buildArgs.add("--initialize-at-build-time=org.junit.jupiter.engine.config.InstantiatingConfigurationParameterConverter")
}
// See https://github.com/graalvm/native-build-tools/issues/572
metadataRepository {
enabled.set(false)
}
tasks.test {
useJUnitPlatform()
setForkEvery(1)
}
}