diff --git a/components/abstractions/gradle/dependencies.gradle b/components/abstractions/gradle/dependencies.gradle index 65eccaadc..3d3c13051 100644 --- a/components/abstractions/gradle/dependencies.gradle +++ b/components/abstractions/gradle/dependencies.gradle @@ -7,10 +7,12 @@ dependencies { // Use JUnit Jupiter Engine for testing. testRuntimeOnly 'org.junit.jupiter:junit-jupiter-engine' + //This dependency is used internally and also by Kiota generated code which leverages this library. + api 'jakarta.annotation:jakarta.annotation-api:2.1.1' + // This dependency is used internally, and not exposed to consumers on their own compile classpath. implementation 'com.google.guava:guava:32.1.2-jre' implementation 'org.javatuples:javatuples:1.2' - implementation 'jakarta.annotation:jakarta.annotation-api:2.1.1' implementation 'io.opentelemetry:opentelemetry-api:1.28.0' implementation 'io.opentelemetry:opentelemetry-context:1.28.0' } \ No newline at end of file diff --git a/components/abstractions/src/main/java/com/microsoft/kiota/PeriodAndDuration.java b/components/abstractions/src/main/java/com/microsoft/kiota/PeriodAndDuration.java index e9508ff67..00d76e322 100644 --- a/components/abstractions/src/main/java/com/microsoft/kiota/PeriodAndDuration.java +++ b/components/abstractions/src/main/java/com/microsoft/kiota/PeriodAndDuration.java @@ -1,7 +1,6 @@ package com.microsoft.kiota; import jakarta.annotation.Nonnull; -import com.google.errorprone.annotations.Immutable; import java.io.Serializable; import java.time.Duration; import java.time.Period; @@ -28,7 +27,6 @@ /** * The aggregate type for {@code Period} and {@code Duration } */ -@Immutable public final class PeriodAndDuration implements TemporalAmount, Comparable, Serializable { /** diff --git a/components/authentication/azure/gradle/dependencies.gradle b/components/authentication/azure/gradle/dependencies.gradle index c81db54c7..d3de84264 100644 --- a/components/authentication/azure/gradle/dependencies.gradle +++ b/components/authentication/azure/gradle/dependencies.gradle @@ -11,7 +11,6 @@ dependencies { implementation 'io.opentelemetry:opentelemetry-api:1.28.0' implementation 'io.opentelemetry:opentelemetry-context:1.28.0' implementation 'com.google.guava:guava:32.1.2-jre' - implementation 'jakarta.annotation:jakarta.annotation-api:2.1.1' api 'com.azure:azure-core:1.42.0' api project(':components:abstractions') diff --git a/components/http/okHttp/gradle/dependencies.gradle b/components/http/okHttp/gradle/dependencies.gradle index 08f65e598..e045a5931 100644 --- a/components/http/okHttp/gradle/dependencies.gradle +++ b/components/http/okHttp/gradle/dependencies.gradle @@ -13,7 +13,6 @@ dependencies { implementation 'io.opentelemetry:opentelemetry-context:1.28.0' implementation 'io.opentelemetry:opentelemetry-semconv:1.28.0-alpha' implementation 'com.google.guava:guava:32.1.2-jre' - implementation 'jakarta.annotation:jakarta.annotation-api:2.1.1' api 'com.squareup.okhttp3:okhttp:4.11.0' api project(':components:abstractions') diff --git a/components/serialization/form/gradle/dependencies.gradle b/components/serialization/form/gradle/dependencies.gradle index 8509d0bad..d2c0793ee 100644 --- a/components/serialization/form/gradle/dependencies.gradle +++ b/components/serialization/form/gradle/dependencies.gradle @@ -7,7 +7,6 @@ dependencies { // This dependency is used internally, and not exposed to consumers on their own compile classpath. implementation 'com.google.guava:guava:32.1.2-jre' - implementation 'jakarta.annotation:jakarta.annotation-api:2.1.1' api project(':components:abstractions') } diff --git a/components/serialization/json/gradle/dependencies.gradle b/components/serialization/json/gradle/dependencies.gradle index c443d0d66..4a239ba94 100644 --- a/components/serialization/json/gradle/dependencies.gradle +++ b/components/serialization/json/gradle/dependencies.gradle @@ -7,7 +7,6 @@ dependencies { // This dependency is used internally, and not exposed to consumers on their own compile classpath. implementation 'com.google.guava:guava:32.1.2-jre' - implementation 'jakarta.annotation:jakarta.annotation-api:2.1.1' api 'com.google.code.gson:gson:2.10.1' api project(':components:abstractions') diff --git a/components/serialization/multipart/gradle/dependencies.gradle b/components/serialization/multipart/gradle/dependencies.gradle index 16e971239..6ef8cf374 100644 --- a/components/serialization/multipart/gradle/dependencies.gradle +++ b/components/serialization/multipart/gradle/dependencies.gradle @@ -8,7 +8,6 @@ dependencies { // This dependency is used internally, and not exposed to consumers on their own compile classpath. implementation 'com.google.guava:guava:32.1.2-jre' - implementation 'jakarta.annotation:jakarta.annotation-api:2.1.1' api project(':components:abstractions') testImplementation project(':components:serialization:json') diff --git a/components/serialization/text/gradle/dependencies.gradle b/components/serialization/text/gradle/dependencies.gradle index 174403073..70bc11818 100644 --- a/components/serialization/text/gradle/dependencies.gradle +++ b/components/serialization/text/gradle/dependencies.gradle @@ -7,7 +7,6 @@ dependencies { // This dependency is used internally, and not exposed to consumers on their own compile classpath. implementation 'com.google.guava:guava:32.1.2-jre' - implementation 'jakarta.annotation:jakarta.annotation-api:2.1.1' api project(':components:abstractions') }