forked from open-telemetry/opentelemetry-java
-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.gradle.kts
85 lines (71 loc) · 2.29 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
plugins {
id("otel.java-conventions")
id("otel.publish-conventions")
id("otel.animalsniffer-conventions")
}
description = "OpenTelemetry Exporter Common"
otelJava.moduleName.set("io.opentelemetry.exporter.internal")
val versions: Map<String, String> by project
dependencies {
api(project(":api:all"))
api(project(":sdk-extensions:autoconfigure-spi"))
compileOnly(project(":sdk:common"))
compileOnly(project(":exporters:common:compile-stub"))
compileOnly("org.codehaus.mojo:animal-sniffer-annotations")
annotationProcessor("com.google.auto.value:auto-value")
// We include helpers shared by gRPC exporters but do not want to impose these
// dependency on all of our consumers.
compileOnly("com.fasterxml.jackson.core:jackson-core")
// sun.misc.Unsafe from the JDK isn't found by the compiler, we provide our own trimmed down
// version that we can compile against.
compileOnly("io.grpc:grpc-stub")
testImplementation(project(":sdk:common"))
testImplementation("com.google.protobuf:protobuf-java-util")
testImplementation("com.linecorp.armeria:armeria-junit5")
testImplementation("org.skyscreamer:jsonassert")
testImplementation("com.google.api.grpc:proto-google-common-protos")
testImplementation("io.grpc:grpc-testing")
testImplementation("edu.berkeley.cs.jqf:jqf-fuzz")
testRuntimeOnly("io.grpc:grpc-netty-shaded")
}
val testJavaVersion: String? by project
testing {
suites {
register<JvmTestSuite>("testHttpSenderProvider") {
dependencies {
implementation(project(":exporters:sender:jdk"))
implementation(project(":exporters:sender:okhttp"))
}
targets {
all {
testTask {
enabled = !testJavaVersion.equals("8")
}
}
}
}
}
suites {
register<JvmTestSuite>("testGrpcSenderProvider") {
dependencies {
implementation(project(":exporters:sender:okhttp"))
implementation(project(":exporters:sender:grpc-managed-channel"))
implementation("io.grpc:grpc-stub")
implementation("io.grpc:grpc-netty")
}
}
}
suites {
register<JvmTestSuite>("testWithoutUnsafe") {}
}
}
tasks {
check {
dependsOn(testing.suites)
}
}
afterEvaluate {
tasks.named<JavaCompile>("compileTestHttpSenderProviderJava") {
options.release.set(11)
}
}