From c72fd01cef5ba3bc4d89898338b99441659e4241 Mon Sep 17 00:00:00 2001 From: Carlos Tasada Date: Tue, 20 Jun 2023 16:09:26 +0200 Subject: [PATCH 1/3] build: Specified Maven Compiler Plugin version It's considered a best practice to specify the Maven Plugin versions, otherwise the used version is not guaranteed and depends on the Maven release. --- pom.xml | 1 + 1 file changed, 1 insertion(+) diff --git a/pom.xml b/pom.xml index 9b3b6d45..691b3969 100644 --- a/pom.xml +++ b/pom.xml @@ -209,6 +209,7 @@ org.apache.maven.plugins maven-compiler-plugin + 3.11.0 compile From 9b68046d643f250b781feac15d768b63196eaf2e Mon Sep 17 00:00:00 2001 From: Carlos Tasada Date: Tue, 20 Jun 2023 16:10:18 +0200 Subject: [PATCH 2/3] build: Specified source encoding If no source encoding is specified, Maven defaults to UTF-8, while showing a warning. Here we specify the used format, which is UTF-8 anyway --- pom.xml | 1 + 1 file changed, 1 insertion(+) diff --git a/pom.xml b/pom.xml index 691b3969..391729ad 100644 --- a/pom.xml +++ b/pom.xml @@ -55,6 +55,7 @@ 1.18.26 5.9.2 1.7.0 + UTF-8 From fa9124e060ac54929f9c3f1d231cb72050c691bd Mon Sep 17 00:00:00 2001 From: Carlos Tasada Date: Tue, 20 Jun 2023 16:12:54 +0200 Subject: [PATCH 3/3] fix: Lombok compiler warning The compilation process was complaining about not properly specified defaults. The `asyncapi` values are supposed to be `final`, but that change breaks the `AsyncAPI` contract usage in different ways. The alternative is to indicate the value is the default one for the builder. This solution removes the warning while keeping the contract expectations. --- .../src/main/java/com/asyncapi/v2/_0_0/model/AsyncAPI.java | 1 + .../src/main/java/com/asyncapi/v2/_6_0/model/AsyncAPI.java | 1 + 2 files changed, 2 insertions(+) diff --git a/asyncapi-core/src/main/java/com/asyncapi/v2/_0_0/model/AsyncAPI.java b/asyncapi-core/src/main/java/com/asyncapi/v2/_0_0/model/AsyncAPI.java index 59d02084..440fddec 100644 --- a/asyncapi-core/src/main/java/com/asyncapi/v2/_0_0/model/AsyncAPI.java +++ b/asyncapi-core/src/main/java/com/asyncapi/v2/_0_0/model/AsyncAPI.java @@ -43,6 +43,7 @@ public class AsyncAPI extends ExtendableObject { * and tooling should typically be compatible with the corresponding major.minor (1.0.*). * Patch versions will correspond to patches of this document. */ + @Builder.Default @NotNull private String asyncapi = "2.0.0"; diff --git a/asyncapi-core/src/main/java/com/asyncapi/v2/_6_0/model/AsyncAPI.java b/asyncapi-core/src/main/java/com/asyncapi/v2/_6_0/model/AsyncAPI.java index 716b5338..5944f5c0 100644 --- a/asyncapi-core/src/main/java/com/asyncapi/v2/_6_0/model/AsyncAPI.java +++ b/asyncapi-core/src/main/java/com/asyncapi/v2/_6_0/model/AsyncAPI.java @@ -43,6 +43,7 @@ public class AsyncAPI extends ExtendableObject { * and tooling should typically be compatible with the corresponding major.minor (1.0.*). * Patch versions will correspond to patches of this document. */ + @Builder.Default @NotNull private String asyncapi = "2.6.0";