1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586 |
- group 'io.opentelemetry.example'
- version '1.0-SNAPSHOT'
- buildscript {
- repositories {
- maven {
- url "https://plugins.gradle.org/m2/"
- }
- maven {
- name = "sonatype"
- url = uri("https://oss.sonatype.org/content/repositories/snapshots")
- }
- }
- dependencies {
- classpath "com.diffplug.spotless:spotless-plugin-gradle:6.25.0"
- classpath "com.github.johnrengelman:shadow:8.1.1"
- classpath "io.opentelemetry.instrumentation:gradle-plugins:2.5.0-alpha"
- }
- }
- subprojects {
- version = rootProject.version
- apply plugin: "java"
- apply plugin: "com.diffplug.spotless"
- ext {
- versions = [
- // this line is managed by .github/scripts/update-sdk-version.sh
- opentelemetrySdk : "1.39.0",
- // these lines are managed by .github/scripts/update-version.sh
- opentelemetryJavaagent : "2.5.0",
- opentelemetryJavaagentAlpha: "2.5.0-alpha",
- autoservice : "1.1.1",
- junit : "5.10.2"
- ]
- deps = [
- autoservice: [
- "com.google.auto.service:auto-service:${versions.autoservice}",
- "com.google.auto.service:auto-service-annotations:${versions.autoservice}",
- ]
- ]
- }
- repositories {
- mavenCentral()
- maven {
- name = "sonatype"
- url = uri("https://oss.sonatype.org/content/repositories/snapshots")
- }
- }
- spotless {
- java {
- googleJavaFormat()
- licenseHeaderFile(rootProject.file("../../buildscripts/spotless.license.java"), "(package|import|public)")
- target("src/**/*.java")
- }
- }
- dependencies {
- implementation(platform("io.opentelemetry:opentelemetry-bom:${versions.opentelemetrySdk}"))
- // these serve as a test of the instrumentation boms
- implementation(platform("io.opentelemetry.instrumentation:opentelemetry-instrumentation-bom:${versions.opentelemetryJavaagent}"))
- implementation(platform("io.opentelemetry.instrumentation:opentelemetry-instrumentation-bom-alpha:${versions.opentelemetryJavaagentAlpha}"))
- testImplementation("org.mockito:mockito-core:5.12.0")
- testImplementation(enforcedPlatform("org.junit:junit-bom:${versions.junit}"))
- testImplementation("org.junit.jupiter:junit-jupiter-api:${versions.junit}")
- testRuntimeOnly("org.junit.jupiter:junit-jupiter-engine:${versions.junit}")
- }
- tasks {
- test {
- useJUnitPlatform()
- }
- compileJava {
- options.release.set(8)
- }
- }
- }
|