diff --git a/README.md b/README.md index a63a855e..990f4814 100644 --- a/README.md +++ b/README.md @@ -131,6 +131,10 @@ The Microsoft Graph SDK is open for contribution. To contribute to this project, The Microsoft Graph SDK for Java library is supported at runtime for Java 8 and [Android API revision 26](http://source.android.com/source/build-numbers.html) or greater. +Android builds require `compileSdk` 37 or later, Android Gradle Plugin 9.1.1 or later with JDK 17 or later, and AndroidX enabled with `android.useAndroidX=true` in `gradle.properties`. + +Use a repository that serves Gradle module metadata so the Android OkHttp variant is selected. If only Maven POM metadata is available, exclude the transitive `okhttp-jvm` dependency and add `okhttp-android` explicitly. + ## 7. License Copyright (c) Microsoft Corporation. All Rights Reserved. Licensed under the [MIT license](LICENSE). diff --git a/android/build.gradle b/android/build.gradle index 7a3a2686..6a540ed9 100644 --- a/android/build.gradle +++ b/android/build.gradle @@ -6,7 +6,7 @@ buildscript { dependencies { classpath "com.gradle:gradle-enterprise-gradle-plugin:3.19.2" - classpath "com.android.tools.build:gradle:8.13.0" + classpath "com.android.tools.build:gradle:9.2.1" classpath "com.github.ben-manes:gradle-versions-plugin:0.54.0" } } @@ -52,7 +52,7 @@ android { checkAllWarnings true warningsAsErrors true lintConfig file("lint.xml") - disable 'AndroidGradlePluginVersion' // We will not be upgrading gradle to version 9 as it does not support our minimum required version of jdk8 + disable 'AndroidGradlePluginVersion' } sourceSets { @@ -77,14 +77,13 @@ dependencies { runtimeOnly 'io.jsonwebtoken:jjwt-jackson:0.13.0' implementation 'com.auth0:jwks-rsa:0.24.2' - api 'com.squareup.okhttp3:okhttp:4.12.0' api 'com.azure:azure-core:1.61.0' - api 'com.microsoft.kiota:microsoft-kiota-abstractions:1.10.5' - api 'com.microsoft.kiota:microsoft-kiota-authentication-azure:1.10.5' - implementation 'com.microsoft.kiota:microsoft-kiota-http-okHttp:1.10.5' - implementation 'com.microsoft.kiota:microsoft-kiota-serialization-json:1.10.5' - implementation 'com.microsoft.kiota:microsoft-kiota-serialization-text:1.10.5' - implementation 'com.microsoft.kiota:microsoft-kiota-serialization-form:1.10.5' - implementation 'com.microsoft.kiota:microsoft-kiota-serialization-multipart:1.10.5' + api 'com.microsoft.kiota:microsoft-kiota-abstractions:2.0.0' + api 'com.microsoft.kiota:microsoft-kiota-authentication-azure:2.0.0' + api 'com.microsoft.kiota:microsoft-kiota-http-okHttp:2.0.0' + implementation 'com.microsoft.kiota:microsoft-kiota-serialization-json:2.0.0' + implementation 'com.microsoft.kiota:microsoft-kiota-serialization-text:2.0.0' + implementation 'com.microsoft.kiota:microsoft-kiota-serialization-form:2.0.0' + implementation 'com.microsoft.kiota:microsoft-kiota-serialization-multipart:2.0.0' } diff --git a/android/gradle.properties b/android/gradle.properties index 9bb6fa75..5b782d4e 100644 --- a/android/gradle.properties +++ b/android/gradle.properties @@ -22,6 +22,7 @@ org.gradle.jvmargs=-Xmx2g org.gradle.parallel=true org.gradle.caching=true +android.useAndroidX=true mavenGroupId = com.microsoft.graph mavenArtifactId = microsoft-graph-core diff --git a/android/gradle/wrapper/gradle-wrapper.properties b/android/gradle/wrapper/gradle-wrapper.properties index aaaabb3c..60d3852c 100644 --- a/android/gradle/wrapper/gradle-wrapper.properties +++ b/android/gradle/wrapper/gradle-wrapper.properties @@ -1,6 +1,6 @@ distributionBase=GRADLE_USER_HOME distributionPath=wrapper/dists -distributionUrl=https\://services.gradle.org/distributions/gradle-8.14.4-bin.zip +distributionUrl=https\://services.gradle.org/distributions/gradle-9.9.1-bin.zip networkTimeout=10000 validateDistributionUrl=true zipStoreBase=GRADLE_USER_HOME diff --git a/android/lint.xml b/android/lint.xml index 65178f8e..0a383f74 100644 --- a/android/lint.xml +++ b/android/lint.xml @@ -3,13 +3,11 @@ - + - - diff --git a/pom.xml b/pom.xml index 5329523e..bc5518ee 100644 --- a/pom.xml +++ b/pom.xml @@ -55,14 +55,13 @@ 2.1.1 0.13.0 0.24.2 - 4.12.0 1.61.0 - 1.10.4 + 2.0.0 6.1.0 5.23.0 - 1.63.0 + 1.68.0 1.0.6 @@ -150,12 +149,6 @@ ${jwks-rsa.version} - - com.squareup.okhttp3 - okhttp - ${okhttp.version} - - com.azure azure-core