Repository: smallrye/smallrye-health
Pull request #465 (2023-04-21 12:33:22)

Upgrade SR parent to 39


Patch:
diff --git a/api/src/main/java/io/smallrye/health/api/HealthRegistry.java b/api/src/main/java/io/smallrye/health/api/HealthRegistry.java
index a9ce42c..f2990bd 100644
--- a/api/src/main/java/io/smallrye/health/api/HealthRegistry.java
+++ b/api/src/main/java/io/smallrye/health/api/HealthRegistry.java
@@ -29,25 +29,25 @@ import io.smallrye.common.annotation.Experimental;
  * <p>
  * Programmatic API for the dynamic registrations and removals of health check procedures.
  * </p>
- * 
+ *
  * <p>
  * The {@link HealthRegistry} can be injected as a CDI bean with two qualifiers:
  * </p>
- * 
+ *
  * <ul>
  * <li><b>Liveness</b></li>
  * </ul>
- * 
+ *
  * <pre>
  * &#64;Inject
  * &#64;Liveness
  * HealthRegistry livenessHealthRegistry;
  * </pre>
- * 
+ *
  * <ul>
  * <li><b>Readiness</b>:</li>
  * </ul>
- * 
+ *
  * <pre>
  * &#64;Inject
  * &#64;Readiness
@@ -59,7 +59,7 @@ public interface HealthRegistry {
 
     /**
      * Programmatic registration of a {@link HealthCheck} instances.
-     * 
+     *
      * @param id the id of the registered check which can be later used for its removal
      * @param healthCheck the {@link HealthCheck} instance to be registered
      * @return this instance for fluent registration
@@ -69,7 +69,7 @@ public interface HealthRegistry {
 
     /**
      * Asynchronous variant of the {@link HealthRegistry#register(String, HealthCheck)}.
-     * 
+     *
      * @param id the id of the registered asynchronous check which can be later used for its removal
      * @param asyncHealthCheck the {@link AsyncHealthCheck} instance to be registered
      * @return this instance for fluent registration
@@ -80,7 +80,7 @@ public interface HealthRegistry {
     /**
      * Programmatic registration of a {@link HealthCheck} intances with the id set to
      * to the health check class name.
-     * 
+     *
      * @param healthCheck the {@link HealthCheck} instance to be registered
      * @return this instance for fluent registration
      * @throws IllegalStateException if the {@link HealthCheck} instance cannot be registered
@@ -92,7 +92,7 @@ public interface HealthRegistry {
 
     /**
      * Asynchronous variant of {@link HealthRegistry#register(HealthCheck)}.
-     * 
+     *
      * @param asyncHealthCheck the {@link AsyncHealthCheck} instance to be registered
      * @return this instance for fluent registration
      * @throws IllegalStateException if the {@link HealthCheck} instance cannot be registered
@@ -105,7 +105,7 @@ public interface HealthRegistry {
     /**
      * Programmatic removal of a programmatically registered check
      * ({@link HealthCheck} or {@link AsyncHealthCheck}) instances.
-     * 
+     *
      * @param id the id of the registered check to be removed
      * @return this instance for fluent registration
      * @throws IllegalStateException if the {@link HealthCheck} instance cannot be removed
@@ -115,7 +115,7 @@ public interface HealthRegistry {
     /**
      * Programmatic removal of a programmatically registered {@link HealthCheck} instances with the id set to
      * the the health check class name.
-     * 
+     *
      * @param healthCheck the {@link HealthCheck} instance to be removed
      * @return this instance for fluent registration
      * @throws IllegalStateException if the {@link HealthCheck} instance cannot be removed
@@ -127,7 +127,7 @@ public interface HealthRegistry {
 
     /**
      * Asynchronous variant of {@link HealthRegistry#remove(HealthCheck)}.
-     * 
+     *
      * @param asyncHealthCheck the {@link AsyncHealthCheck} instance to be removed
      * @return this instance for fluent registration
      * @throws IllegalStateException if the {@link HealthCheck} instance cannot be removed
diff --git a/implementation/pom.xml b/implementation/pom.xml
index 3a37302..0f63b66 100644
--- a/implementation/pom.xml
+++ b/implementation/pom.xml
@@ -69,8 +69,9 @@
       <artifactId>jakarta.json-api</artifactId>
     </dependency>
     <dependency>
-      <groupId>org.glassfish</groupId>
+      <groupId>org.eclipse.parsson</groupId>
       <artifactId>jakarta.json</artifactId>
+      <version>${version.eclipse.parsson}</version>
     </dependency>
 
     <dependency>
diff --git a/implementation/src/main/java/io/smallrye/health/HealthStatus.java b/implementation/src/main/java/io/smallrye/health/HealthStatus.java
index 0713117..e6cf878 100644
--- a/implementation/src/main/java/io/smallrye/health/HealthStatus.java
+++ b/implementation/src/main/java/io/smallrye/health/HealthStatus.java
@@ -12,7 +12,7 @@ public class HealthStatus {
 
     /**
      * Creates a health check with status up.
-     * 
+     *
      * @param name of the health check
      * @return Health check with status up and given name.
      */
@@ -22,7 +22,7 @@ public class HealthStatus {
 
     /**
      * Creates a health check with status down.
-     * 
+     *
      * @param name of the health check
      * @return Health check with status down and given name.
      */
@@ -32,7 +32,7 @@ public class HealthStatus {
 
     /**
      * Creates a health check with status set from supplier and default health check name (health-check).
-     * 
+     *
      * @param supplier to get status.
      * @return Health check with given status and default name.
      */
@@ -42,7 +42,7 @@ public class HealthStatus {
 
     /**
      * Creates a health check with given status and default health check name (health-check).
-     * 
+     *
      * @param status
      * @return Health check with given status and default name.
      */
@@ -52,7 +52,7 @@ public class HealthStatus {
 
     /**
      * Creates a health check with given status and health check name.
-     * 
+     *
      * @param name of the status.
      * @param supplier to get status.
      * @return Health check with given status and name.
@@ -63,7 +63,7 @@ public class HealthStatus {
 
     /**
      * Creates a health check with given status and health check name.
-     * 
+     *
      * @param name of the status.
      * @param status
      * @return Health check with given status and name.
diff --git a/pom.xml b/pom.xml
index 0c5b413..c3abe5b 100644
--- a/pom.xml
+++ b/pom.xml
@@ -21,8 +21,8 @@
 
   <parent>
     <groupId>io.smallrye</groupId>
-    <artifactId>smallrye-jakarta-parent</artifactId>
-    <version>37</version>
+    <artifactId>smallrye-parent</artifactId>
+    <version>39</version>
   </parent>
 
   <artifactId>smallrye-health-parent</artifactId>
@@ -35,12 +35,13 @@
   <properties>
     <version.eclipse.microprofile.config>3.0.3</version.eclipse.microprofile.config>
     <version.eclipse.microprofile.health>4.0.1</version.eclipse.microprofile.health>
+    <version.eclipse.parsson>1.1.1</version.eclipse.parsson>
     <version.httpclient>4.5.14</version.httpclient>
     <version.jakarta.servlet>6.0.0</version.jakarta.servlet>
     <version.mutiny>2.1.0</version.mutiny>
-    <version.smallrye-config>3.2.1</version.smallrye-config>
-    <version.smallrye-common>2.1.0</version.smallrye-common>
-    <version.smallrye.testing.utilities>2.3.0</version.smallrye.testing.utilities>
+    <version.smallrye.config>3.2.1</version.smallrye.config>
+    <version.smallrye.common>2.1.0</version.smallrye.common>
+    <version.smallrye.testing>2.3.0</version.smallrye.testing>
     <version.testng>7.5</version.testng>
     <version.wildfly>27.0.0.Alpha4</version.wildfly>
 
@@ -102,6 +103,7 @@
           </exclusion>
         </exclusions>
       </dependency>
+
       <dependency>
         <groupId>org.eclipse.microprofile.health</groupId>
         <artifactId>microprofile-health-tck</artifactId>
@@ -138,35 +140,39 @@
         <version>${version.jakarta.servlet}</version>
       </dependency>
 
-      <dependency>
-        <groupId>org.jboss.weld.servlet</groupId>
-        <artifactId>weld-servlet-core</artifactId>
-        <version>${version.weld.core}</version>
-        <scope>test</scope>
-        <exclusions>
-          <exclusion>
-            <groupId>jakarta.enterprise</groupId>
-            <artifactId>jakarta.enterprise.cdi-api</artifactId>
-          </exclusion>
-        </exclusions>
-      </dependency>
-
       <dependency>
         <groupId>io.smallrye.config</groupId>
         <artifactId>smallrye-config</artifactId>
-        <version>${version.smallrye-config}</version>
+        <version>${version.smallrye.config}</version>
       </dependency>
+
       <dependency>
         <groupId>io.smallrye.common</groupId>
         <artifactId>smallrye-common-annotation</artifactId>
-        <version>${version.smallrye-common}</version>
+        <version>${version.smallrye.common}</version>
+      </dependency>
+
+      <dependency>
+        <groupId>io.smallrye.common</groupId>
+        <artifactId>smallrye-common-bom</artifactId>
+        <version>${version.smallrye.common}</version>
+        <scope>import</scope>
+        <type>pom</type>
       </dependency>
 
       <!-- Test Dependencies -->
+      <dependency>
+        <groupId>io.smallrye.testing</groupId>
+        <artifactId>smallrye-testing-bom</artifactId>
+        <version>${version.smallrye.testing}</version>
+        <scope>import</scope>
+        <type>pom</type>
+      </dependency>
+
       <dependency>
         <groupId>io.smallrye.testing</groupId>
         <artifactId>smallrye-testing-utilities</artifactId>
-        <version>${version.smallrye.testing.utilities}</version>
+        <version>${version.smallrye.testing}</version>
         <scope>test</scope>
       </dependency>
 
diff --git a/provided-checks/src/main/java/io/smallrye/health/checks/HeapMemoryHealthCheck.java b/provided-checks/src/main/java/io/smallrye/health/checks/HeapMemoryHealthCheck.java
index 95c6f7f..a071444 100644
--- a/provided-checks/src/main/java/io/smallrye/health/checks/HeapMemoryHealthCheck.java
+++ b/provided-checks/src/main/java/io/smallrye/health/checks/HeapMemoryHealthCheck.java
@@ -13,7 +13,7 @@ import org.eclipse.microprofile.health.HealthCheckResponse;
  * &#64;ApplicationScoped
  * &#64;Liveness
  * HealthCheck check1() {
- *   return new HeapMemoryHealthCheck();
+ *     return new HeapMemoryHealthCheck();
  * }
  * }
  * </pre>
diff --git a/provided-checks/src/main/java/io/smallrye/health/checks/InetAddressHealthCheck.java b/provided-checks/src/main/java/io/smallrye/health/checks/InetAddressHealthCheck.java
index e1ec6c4..d073c1c 100644
--- a/provided-checks/src/main/java/io/smallrye/health/checks/InetAddressHealthCheck.java
+++ b/provided-checks/src/main/java/io/smallrye/health/checks/InetAddressHealthCheck.java
@@ -16,7 +16,7 @@ import org.eclipse.microprofile.health.HealthCheckResponseBuilder;
  * &#64;ApplicationScoped
  * &#64;Liveness
  * HealthCheck check1() {
- *   return new InetAddressHealthCheck("service.com");
+ *     return new InetAddressHealthCheck("service.com");
  * }
  * }
  * </pre>
@@ -62,7 +62,7 @@ public class InetAddressHealthCheck implements HealthCheck {
 
     /**
      * Sets timeout in millis.
-     * 
+     *
      * @param timeout in millis.
      * @return InetAddressHealthCheck instance.
      */
@@ -73,7 +73,7 @@ public class InetAddressHealthCheck implements HealthCheck {
 
     /**
      * Sets the name of the health check.
-     * 
+     *
      * @param name of health check.
      * @return InetAddressHealthCheck instance.
      */
diff --git a/provided-checks/src/main/java/io/smallrye/health/checks/NonHeapMemoryHealthCheck.java b/provided-checks/src/main/java/io/smallrye/health/checks/NonHeapMemoryHealthCheck.java
index 49feedc..7294199 100644
--- a/provided-checks/src/main/java/io/smallrye/health/checks/NonHeapMemoryHealthCheck.java
+++ b/provided-checks/src/main/java/io/smallrye/health/checks/NonHeapMemoryHealthCheck.java
@@ -13,7 +13,7 @@ import org.eclipse.microprofile.health.HealthCheckResponse;
  * &#64;ApplicationScoped
  * &#64;Liveness
  * HealthCheck check1() {
- *   return new NonHeapMemoryHealthCheck();
+ *     return new NonHeapMemoryHealthCheck();
  * }
  * }
  * </pre>
diff --git a/provided-checks/src/main/java/io/smallrye/health/checks/SocketHealthCheck.java b/provided-checks/src/main/java/io/smallrye/health/checks/SocketHealthCheck.java
index dd04d0a..0755cc0 100644
--- a/provided-checks/src/main/java/io/smallrye/health/checks/SocketHealthCheck.java
+++ b/provided-checks/src/main/java/io/smallrye/health/checks/SocketHealthCheck.java
@@ -18,7 +18,7 @@ import org.eclipse.microprofile.health.HealthCheckResponseBuilder;
  * &#64;ApplicationScoped
  * &#64;Liveness
  * HealthCheck check1() {
- *   return new SocketHealthCheck("192.168.0.2", 5432);
+ *     return new SocketHealthCheck("192.168.0.2", 5432);
  * }
  * }
  * </pre>
@@ -62,7 +62,7 @@ public class SocketHealthCheck implements HealthCheck {
 
     /**
      * Sets the name of the health check.
-     * 
+     *
      * @param name of health check.
      * @return SocketHealthCheck instance.
      */
diff --git a/provided-checks/src/main/java/io/smallrye/health/checks/SystemLoadHealthCheck.java b/provided-checks/src/main/java/io/smallrye/health/checks/SystemLoadHealthCheck.java
index 79987e8..53333d9 100644
--- a/provided-checks/src/main/java/io/smallrye/health/checks/SystemLoadHealthCheck.java
+++ b/provided-checks/src/main/java/io/smallrye/health/checks/SystemLoadHealthCheck.java
@@ -16,7 +16,7 @@ import org.eclipse.microprofile.health.HealthCheckResponseBuilder;
  * &#64;ApplicationScoped
  * &#64;Liveness
  * HealthCheck check1() {
- *   return new SystemLoadHealthCheck();
+ *     return new SystemLoadHealthCheck();
  * }
  * }
  * </pre>
diff --git a/provided-checks/src/main/java/io/smallrye/health/checks/ThreadHealthCheck.java b/provided-checks/src/main/java/io/smallrye/health/checks/ThreadHealthCheck.java
index 0d6af81..0e08a73 100644
--- a/provided-checks/src/main/java/io/smallrye/health/checks/ThreadHealthCheck.java
+++ b/provided-checks/src/main/java/io/smallrye/health/checks/ThreadHealthCheck.java
@@ -16,7 +16,7 @@ import org.eclipse.microprofile.health.HealthCheckResponseBuilder;
  * &#64;ApplicationScoped
  * &#64;Liveness
  * HealthCheck check1() {
- *   return new ThreadHealthCheck(9999999L);
+ *     return new ThreadHealthCheck(9999999L);
  * }
  * }
  * </pre>
diff --git a/provided-checks/src/main/java/io/smallrye/health/checks/UrlHealthCheck.java b/provided-checks/src/main/java/io/smallrye/health/checks/UrlHealthCheck.java
index 55437d0..a9b06a1 100644
--- a/provided-checks/src/main/java/io/smallrye/health/checks/UrlHealthCheck.java
+++ b/provided-checks/src/main/java/io/smallrye/health/checks/UrlHealthCheck.java
@@ -17,7 +17,7 @@ import org.eclipse.microprofile.health.HealthCheckResponseBuilder;
  * &#64;ApplicationScoped
  * &#64;Liveness
  * HealthCheck check1() {
- *   return new UrlHealthCheck("www.google.com");
+ *     return new UrlHealthCheck("www.google.com");
  * }
  * }
  * </pre>
@@ -86,7 +86,7 @@ public class UrlHealthCheck implements HealthCheck {
 
     /**
      * Sets the name of the health check.
-     * 
+     *
      * @param name of health check.
      * @return UrlHealthCheck instance.
      */
@@ -97,7 +97,7 @@ public class UrlHealthCheck implements HealthCheck {
 
     /**
      * Sets timeout in millis.
-     * 
+     *
      * @param timeout in millis.
      * @return UrlHealthCheck instance.
      */
@@ -108,7 +108,7 @@ public class UrlHealthCheck implements HealthCheck {
 
     /**
      * Sets the expected status code to be returned as valid.
-     * 
+     *
      * @param statusCode expected.
      * @return UrlHealthCheck instance.
      */
@@ -119,7 +119,7 @@ public class UrlHealthCheck implements HealthCheck {
 
     /**
      * Sets the request method to be used (ie GET, POST, PUT, ...)
-     * 
+     *
      * @param requestMethod to use.
      * @return UrlHealthCheck instance.
      */


Test patch:
diff --git a/testsuite/pom.xml b/testsuite/pom.xml
index 6b43cd4..4ce2372 100644
--- a/testsuite/pom.xml
+++ b/testsuite/pom.xml
@@ -16,5 +16,16 @@
     <module>tck</module>
   </modules>
 
+  <dependencyManagement>
+    <dependencies>
+      <dependency>
+        <groupId>io.smallrye.testing</groupId>
+        <artifactId>smallrye-testing-bom-tck</artifactId>
+        <version>${version.smallrye.testing}</version>
+        <scope>import</scope>
+        <type>pom</type>
+      </dependency>
+    </dependencies>
+  </dependencyManagement>
 
 </project>