From c83bf89716cdece25be04f3867a64fcfdb0792b2 Mon Sep 17 00:00:00 2001 From: setmiller Date: Wed, 21 Feb 2024 10:19:01 -0500 Subject: [PATCH 1/2] Fixed issue with java 8 compatibility by replacing isBlank with the usable compatibility layer --- .../kiota/http/middleware/ParametersNameDecodingHandler.java | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/components/http/okHttp/src/main/java/com/microsoft/kiota/http/middleware/ParametersNameDecodingHandler.java b/components/http/okHttp/src/main/java/com/microsoft/kiota/http/middleware/ParametersNameDecodingHandler.java index 0d21e0b48..0cab034c9 100644 --- a/components/http/okHttp/src/main/java/com/microsoft/kiota/http/middleware/ParametersNameDecodingHandler.java +++ b/components/http/okHttp/src/main/java/com/microsoft/kiota/http/middleware/ParametersNameDecodingHandler.java @@ -1,5 +1,6 @@ package com.microsoft.kiota.http.middleware; +import com.microsoft.kiota.Compatibility; import com.microsoft.kiota.http.middleware.options.ParametersNameDecodingOption; import io.opentelemetry.api.trace.Span; @@ -107,7 +108,7 @@ public ParametersNameDecodingHandler(@Nonnull final ParametersNameDecodingOption @Nullable final String original, @Nonnull final char[] charactersToDecode) { Objects.requireNonNull(charactersToDecode); - if (original == null || original.isBlank() || charactersToDecode.length == 0) { + if (original == null || Compatibility.isBlank(original) || charactersToDecode.length == 0) { return ""; } @@ -152,7 +153,7 @@ public ParametersNameDecodingHandler(@Nonnull final ParametersNameDecodingOption return toDecode.stream() .map( tuple -> - tuple.getKey().isBlank() + Compatibility.isBlank(tuple.getKey()) ? tuple.getValue() : tuple.getValue() + "=" + tuple.getKey()) .collect(Collectors.joining("&")); From e1fa9bbd066795cfa460de3a908b7d7ec4177334 Mon Sep 17 00:00:00 2001 From: setmiller Date: Wed, 21 Feb 2024 10:41:06 -0500 Subject: [PATCH 2/2] updated versions and added to CHANGELOG.md --- CHANGELOG.md | 6 ++++++ README.md | 28 ++++++++++++++-------------- gradle.properties | 2 +- 3 files changed, 21 insertions(+), 15 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index f8c529e4c..6bb084ab6 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -11,6 +11,12 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ### Changed +## [1.0.3] - 2024-02-21 + +### Changed + +- Fixed compatibility with Java 8 by replacing `isBlank` with `Compatibility.isBlank` + ## [1.0.2] - 2024-02-13 ### Changed diff --git a/README.md b/README.md index fde6c081b..0ca55c4a0 100644 --- a/README.md +++ b/README.md @@ -21,13 +21,13 @@ Read more about Kiota [here](https://github.com/microsoft/kiota/blob/main/README In `build.gradle` in the `dependencies` section: ```Groovy -implementation 'com.microsoft.kiota:microsoft-kiota-abstractions:1.0.0' -implementation 'com.microsoft.kiota:microsoft-kiota-authentication-azure:1.0.0' -implementation 'com.microsoft.kiota:microsoft-kiota-http-okHttp:1.0.0' -implementation 'com.microsoft.kiota:microsoft-kiota-serialization-json:1.0.0' -implementation 'com.microsoft.kiota:microsoft-kiota-serialization-text:1.0.0' -implementation 'com.microsoft.kiota:microsoft-kiota-serialization-form:1.0.0' -implementation 'com.microsoft.kiota:microsoft-kiota-serialization-multipart:1.0.0' +implementation 'com.microsoft.kiota:microsoft-kiota-abstractions:1.0.3' +implementation 'com.microsoft.kiota:microsoft-kiota-authentication-azure:1.0.3' +implementation 'com.microsoft.kiota:microsoft-kiota-http-okHttp:1.0.3' +implementation 'com.microsoft.kiota:microsoft-kiota-serialization-json:1.0.3' +implementation 'com.microsoft.kiota:microsoft-kiota-serialization-text:1.0.3' +implementation 'com.microsoft.kiota:microsoft-kiota-serialization-form:1.0.3' +implementation 'com.microsoft.kiota:microsoft-kiota-serialization-multipart:1.0.3' ``` ### With Maven: @@ -38,37 +38,37 @@ In `pom.xml` in the `dependencies` section: com.microsoft.kiota microsoft-kiota-abstractions - 1.0.0 + 1.0.3 com.microsoft.kiota microsoft-kiota-authentication-azure - 1.0.0 + 1.0.3 com.microsoft.kiota microsoft-kiota-http-okHttp - 1.0.0 + 1.0.3 com.microsoft.kiota microsoft-kiota-serialization-json - 1.0.0 + 1.0.3 com.microsoft.kiota microsoft-kiota-serialization-text - 1.0.0 + 1.0.3 com.microsoft.kiota microsoft-kiota-serialization-form - 1.0.0 + 1.0.3 com.microsoft.kiota microsoft-kiota-serialization-multipart - 1.0.0 + 1.0.3 ``` diff --git a/gradle.properties b/gradle.properties index 405e9078b..2ca01d7eb 100644 --- a/gradle.properties +++ b/gradle.properties @@ -26,7 +26,7 @@ org.gradle.caching=true mavenGroupId = com.microsoft.kiota mavenMajorVersion = 1 mavenMinorVersion = 0 -mavenPatchVersion = 2 +mavenPatchVersion = 3 mavenArtifactSuffix = #These values are used to run functional tests