diff --git a/.github/workflows/codeql-verification.yml b/.github/workflows/codeql-verification.yml index e616ec019719d..16d1dd2994fe3 100644 --- a/.github/workflows/codeql-verification.yml +++ b/.github/workflows/codeql-verification.yml @@ -22,7 +22,7 @@ jobs: timeout-minutes: 120 steps: - name: Check out candidate - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 + uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1 with: fetch-depth: 0 persist-credentials: false @@ -46,7 +46,7 @@ jobs: "$java_home/bin/java" -version - name: Install pinned evidence verifier runtime - uses: actions/setup-python@5fda3b95a4ea91299a34e894583c3862153e4b97 + uses: actions/setup-python@5fda3b95a4ea91299a34e894583c3862153e4b97 # v7.0.0 with: python-version: '3.14.7' check-latest: false @@ -57,15 +57,15 @@ jobs: run: | set -euo pipefail test -z "$(git status --porcelain)" - test "$(git rev-parse 60c31e3750cbad64f5720e2e02f0a9830973193c^{commit})" = \ - 60c31e3750cbad64f5720e2e02f0a9830973193c - git merge-base --is-ancestor 60c31e3750cbad64f5720e2e02f0a9830973193c HEAD - grep -Fxq 'distributionSha256Sum=55fadd669532a3205d5db95f490bf13971d8b0843526f407f29db0e61f074ab3' \ + test "$(git rev-parse 520a6d217e8809bd2a0d44ecbae5a8bcdb958b2c^{commit})" = \ + 520a6d217e8809bd2a0d44ecbae5a8bcdb958b2c + git merge-base --is-ancestor 520a6d217e8809bd2a0d44ecbae5a8bcdb958b2c HEAD + grep -Fxq 'distributionSha256Sum=5af3b743dd8b876b5c45da33b676251e5f1687712644abb4ee519ca56e1d89ce' \ .mvn/wrapper/maven-wrapper.properties test "$(python --version)" = 'Python 3.14.7' - name: Initialize CodeQL - uses: github/codeql-action/init@ff2f1c621b7f889edc0d3c761ac2e6a3f8cdb0dd + uses: github/codeql-action/init@db488ddef3bf6cb639b32c2e9a7c0a7ea8271d28 # v4.37.8 with: languages: java-kotlin build-mode: manual @@ -90,7 +90,7 @@ jobs: test-compile - name: Analyze without publishing temporary alerts - uses: github/codeql-action/analyze@ff2f1c621b7f889edc0d3c761ac2e6a3f8cdb0dd + uses: github/codeql-action/analyze@db488ddef3bf6cb639b32c2e9a7c0a7ea8271d28 # v4.37.8 with: category: '/language:java-kotlin' upload: never @@ -169,7 +169,7 @@ jobs: - name: Upload verification evidence if: always() - uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a + uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1 with: name: distributed-cache-codeql-${{ github.sha }} path: codeql-results/ diff --git a/.github/workflows/security-release-gate.yml b/.github/workflows/security-release-gate.yml index 66f1f56ecb6fc..ad6d7b8fdd0ab 100644 --- a/.github/workflows/security-release-gate.yml +++ b/.github/workflows/security-release-gate.yml @@ -24,7 +24,7 @@ jobs: TRIVY_IMAGE: aquasec/trivy:0.74.0@sha256:62b1e65e8869bc4b4c6aa4fa2b21595256c7c2f6018a9d9ad61caf87187c1969 steps: - name: Check out candidate - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 + uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1 with: fetch-depth: 0 persist-credentials: false @@ -48,7 +48,7 @@ jobs: "$java_home/bin/java" -version - name: Install pinned evidence verifier runtime - uses: actions/setup-python@5fda3b95a4ea91299a34e894583c3862153e4b97 + uses: actions/setup-python@5fda3b95a4ea91299a34e894583c3862153e4b97 # v7.0.0 with: python-version: '3.14.7' check-latest: false @@ -59,10 +59,10 @@ jobs: run: | set -euo pipefail test -z "$(git status --porcelain)" - test "$(git rev-parse 60c31e3750cbad64f5720e2e02f0a9830973193c^{commit})" = \ - 60c31e3750cbad64f5720e2e02f0a9830973193c - git merge-base --is-ancestor 60c31e3750cbad64f5720e2e02f0a9830973193c HEAD - grep -Fxq 'distributionSha256Sum=55fadd669532a3205d5db95f490bf13971d8b0843526f407f29db0e61f074ab3' \ + test "$(git rev-parse 520a6d217e8809bd2a0d44ecbae5a8bcdb958b2c^{commit})" = \ + 520a6d217e8809bd2a0d44ecbae5a8bcdb958b2c + git merge-base --is-ancestor 520a6d217e8809bd2a0d44ecbae5a8bcdb958b2c HEAD + grep -Fxq 'distributionSha256Sum=5af3b743dd8b876b5c45da33b676251e5f1687712644abb4ee519ca56e1d89ce' \ .mvn/wrapper/maven-wrapper.properties test "$(python --version)" = 'Python 3.14.7' mkdir -p evidence @@ -512,7 +512,7 @@ jobs: - name: Upload review evidence if: always() - uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a + uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1 with: name: distributed-cache-security-${{ github.sha }} path: evidence/ diff --git a/.mvn/wrapper/maven-wrapper.properties b/.mvn/wrapper/maven-wrapper.properties index 2dc47af023d4e..e4af3acf8c4ff 100644 --- a/.mvn/wrapper/maven-wrapper.properties +++ b/.mvn/wrapper/maven-wrapper.properties @@ -1,4 +1,5 @@ wrapperVersion=3.3.4 distributionType=only-script -distributionUrl=https://repo.maven.apache.org/maven2/org/apache/maven/apache-maven/3.9.14/apache-maven-3.9.14-bin.zip -distributionSha256Sum=55fadd669532a3205d5db95f490bf13971d8b0843526f407f29db0e61f074ab3 +distributionUrl=https://repo.maven.apache.org/maven2/org/apache/maven/apache-maven/3.9.16/apache-maven-3.9.16-bin.zip +distributionSha256Sum=5af3b743dd8b876b5c45da33b676251e5f1687712644abb4ee519ca56e1d89ce +distributionSha256SumTarGz=80ffca22aed9e8b9713a232f3394fd81d7f20322df75efdb2b047dbd3e3a23bb diff --git a/SECURITY-MAINTENANCE.md b/SECURITY-MAINTENANCE.md index d99f88cf8dcb3..45912efb89b41 100644 --- a/SECURITY-MAINTENANCE.md +++ b/SECURITY-MAINTENANCE.md @@ -8,7 +8,7 @@ The resulting reviewed Maven artifact version is `5.7.3-pasturestack.2`; it is a | Component | Upstream 5.7.0 | PastureStack maintained version | Scope | | --- | --- | --- | --- | -| Java release / cloud test VM | 17 / Java 8 or 17 | 25 LTS / Ubuntu 24.04 LTS | Compiler target, CI, and cloud integration runtime | +| Java release / cloud test VM | 17 / retired mixed-runtime fixtures | 25 LTS / Ubuntu 24.04 LTS | Compiler target, CI, and cloud integration runtime | | Container build JDK | Unpinned release line | Temurin 25.0.4+7 on Ubuntu 24.04, digest pinned | Reproducible OCI build stage aligned with CI; build-only `unzip` preserves Maven ZIP checksum verification; a bounded 1.2 GiB Maven heap prevents javac OOM on the 2 GiB builder | | Jackson 2 core and databind | 2.21.2 | 2.22.2 | Shaded runtime | | Jackson 3 core, databind, and JR | 3.1.2 | 3.2.2 | Shaded runtime | @@ -23,7 +23,7 @@ The resulting reviewed Maven artifact version is `5.7.3-pasturestack.2`; it is a | Janino | 3.1.10 | 3.1.12 | SQL expression runtime | | Checkstyle | 12.3.1 | 14.0.0 | Build-time source policy | | gRPC Java / Python | 1.73.0 | 1.83.1 / 1.83.0 | gRPC and cloud extension dependencies | -| Aircompressor | 2.0.2 | 2.0.3 | Hadoop compression dependency | +| Aircompressor | 2.0.2 | 2.0.3 | Current Parquet 1.18 byte-array codec dependency; Aircompressor v3 uses a different artifact/package and MemorySegment API | | Hazelcast test-job dependency | 5.0.5 | 5.7.3-pasturestack.2 | Command-line integration test fixtures | | Maven Compiler Plugin | implicit | 3.15.0 | Reproducible test-fixture builds | | Maven JAR Plugin | 3.1.2 | 3.5.1 | Reproducible test-fixture packaging | @@ -52,13 +52,11 @@ The resulting reviewed Maven artifact version is `5.7.3-pasturestack.2`; it is a | Logback | 1.3.15 | 1.6.3 | Test logging | | Vert.x Core | 4.5.24 | 5.1.6 | Cloud integration tests | | Apache Hadoop | 3.4.3 | 3.5.0 | Hadoop, Azure, and S3 connector runtime | -| Spring Boot 3 | 3.5.14 | 3.5.16 | Legacy Spring 6 compatibility tests | -| Spring Framework 6 | 6.2.18 | 6.2.19 | Spring 6 integration tests | -| Spring Boot 4 | 4.0.6 | 4.1.1 | Primary Spring 7 integration tests | -| Spring Framework 7 | 7.0.7 | 7.0.9 | Spring 7 integration tests | +| Spring Boot | 4.1.0 | 4.1.1 | Runtime and integration tests | +| Spring Framework | 7.0.8 | 7.0.9 | Runtime and integration tests | | Jetty test servers | Jetty 9.4.58 | removed | Schema Registry and Hadoop test infrastructure | -The Jackson updates address the High-severity findings reported against the original shaded runtime by the Trivy Java vulnerability database on 2026-07-22, including `GHSA-r7wm-3cxj-wff9`, `CVE-2026-54512`, and `CVE-2026-54513`. The 2026-08-07 full-source review also covers Netty, gRPC Java, Aircompressor, MINA, Tomcat, PostgreSQL JDBC, Hibernate ORM, LZ4 Java, and Spring advisories tracked by GitHub and the respective upstream security notices. The 2026-08-23 maintenance pass additionally updates the shared dependency-management boundary for Apache HTTP Core/Client, Commons Configuration, OpenTelemetry, Log4j, Bouncy Castle, ZooKeeper, Wire, Micrometer, RabbitMQ, Plexus Utils, Logback, and Vert.x. The obsolete Log4j 1 bridge was removed from the Elasticsearch 7 tests, the legacy MySQL connector coordinate was replaced with `com.mysql:mysql-connector-j`, and the unused Hadoop `jsonschema2pojo-core` transitive was excluded at its direct introducing dependency. The sole Commons Lang 2 test call was migrated to the already managed Commons Lang 3 API before excluding Commons Lang 2 from the same path. The final compatibility pass moves the product and CI target to Java 25 LTS, upgrades Netty and Lettuce together onto the 4.2-native line, replaces JLine's Jansi provider with the Java FFM provider, and migrates Protobuf serializers to the stable `Message` API so generated classes from both the previous V3 hierarchy and Protobuf Java 4 remain supported. Java gRPC remains at 1.83.1, while the Python runtime uses 1.83.0 because gRPC patch releases are language-specific and 1.83.1 is not published on PyPI. Aircompressor remains at the current reviewed 2.0.3 release. The standalone command-line test fixtures now pin stable Maven plugin releases and use the intended compiler release setting so their build output is reproducible. Hibernate ORM 5.6 has no patched release and is end-of-life, so the distribution test was migrated to the current stable 7.4 line instead of suppressing the alert or deleting coverage. LZ4 Java 1.11.2 was accepted only after matching its Maven Central publication to the upstream security release, signed tag history, and verified commits. Development and test scope reduces production reachability, but it does not make vulnerable code safe to execute in CI or release builds. +The Jackson updates address the High-severity findings reported against the original shaded runtime by the Trivy Java vulnerability database on 2026-07-22, including `GHSA-r7wm-3cxj-wff9`, `CVE-2026-54512`, and `CVE-2026-54513`. The 2026-08-07 full-source review also covers Netty, gRPC Java, Aircompressor, MINA, Tomcat, PostgreSQL JDBC, Hibernate ORM, LZ4 Java, and Spring advisories tracked by GitHub and the respective upstream security notices. The 2026-08-23 maintenance pass additionally updates the shared dependency-management boundary for Apache HTTP Core/Client, Commons Configuration, OpenTelemetry, Log4j, Bouncy Castle, ZooKeeper, Wire, Micrometer, RabbitMQ, Plexus Utils, Logback, and Vert.x. The obsolete Log4j 1 bridge was removed from the Elasticsearch 7 tests, the legacy MySQL connector coordinate was replaced with `com.mysql:mysql-connector-j`, and the unused Hadoop `jsonschema2pojo-core` transitive was excluded at its direct introducing dependency. The sole Commons Lang 2 test call was migrated to the already managed Commons Lang 3 API before excluding Commons Lang 2 from the same path. The final compatibility pass moves the product, fixtures, and CI target to Java 25 LTS, upgrades Netty and Lettuce together onto the 4.2-native line, replaces JLine's Jansi provider with the Java FFM provider, and migrates Protobuf serializers to the stable `Message` API so generated classes from both the previous V3 hierarchy and Protobuf Java 4 remain supported. Java gRPC remains at 1.83.1, while the Python runtime uses 1.83.0 because gRPC patch releases are language-specific and 1.83.1 is not published on PyPI. Parquet 1.18.0 still compiles against Aircompressor 2.0.3's byte-array API; Aircompressor v3 is not binary-compatible because it moved to a separate artifact, package, and MemorySegment API. The standalone command-line test fixtures now pin stable Maven plugin releases and use Java 25 so their build output matches the product runtime. Hibernate ORM 5.6 has no patched release and is end-of-life, so the distribution test was migrated to the current stable 7.4 line instead of suppressing the alert or deleting coverage. LZ4 Java 1.11.2 was accepted only after matching its Maven Central publication to the upstream security release, signed tag history, and verified commits. Development and test scope reduces production reachability, but it does not make vulnerable code safe to execute in CI or release builds. Debezium was migrated from the end-of-life 1.9 line to 3.6.1.Final. The CDC implementation now uses the current schema-history SPI and configuration keys (`schema.history.internal`, `topic.prefix`, and the `*.include.list` / `*.exclude.list` family). PostgreSQL snapshot mode `NEVER` maps to the current `NO_DATA` mode, while custom snapshotters use the current Debezium snapshotter SPI and custom-name setting. This is a runtime migration, not an alert suppression. @@ -95,14 +93,14 @@ The standalone release gates `scripts/check-xml-parser-hardening` and `scripts/c The reviewed core JAR build invokes Maven and the pinned JDK; it does not compile the repository's C source companions or package the optional Python extension. The gate records hashes for the tracked C headers, C sources, and prebuilt native resources, then requires the native bytes embedded in the JAR to match the tracked resources exactly. It also rejects Python extension resources in the core JAR. Python 3.14.7 is pinned only for evidence validation in CI. A C compiler therefore is not a hidden input to this artifact build, and the verifier Python is not a deployed runtime component. -The opt-in `spring-5` compatibility profile has been removed because Spring Boot 2.7 and Spring Framework 5.3 are end-of-life. The maintained compatibility matrix starts at Spring Boot 3 / Spring Framework 6 and also covers Spring Boot 4 / Spring Framework 7. XML schema names such as `hazelcast-spring-5.7.xsd` identify the Hazelcast schema version and are unrelated to the removed Spring Framework 5 dependency line. +All Spring Boot 3 / Spring Framework 6 compatibility profiles and the `hazelcast-spring-boot3` artifact have been removed. The maintained runtime is Spring Boot 4 / Spring Framework 7 only. XML schema names such as `hazelcast-spring-5.7.xsd` identify the Hazelcast schema version and are unrelated to a Spring Framework dependency line. ## Required Release Gates A release is acceptable only when all of the following are true: 1. The upstream `v5.7.0` boundary recorded in [ORIGIN.md](ORIGIN.md) is an ancestor of the candidate, and every later commit remains on the linear PastureStack maintenance line. -2. Every reactor POM and command-line test fixture resolves the maintained artifact at 5.7.3-pasturestack.2, while generated cluster runtime metadata resolves to numeric version 5.7.3. Maven Wrapper 3.9.14 is downloaded only from Maven Central and is verified against the committed SHA-256 before execution. The source version gate requires Java 25, Ubuntu 24.04 LTS cloud test images, Checkstyle 14.0.0, Avro 1.12.2, Jackson 2.22.2 and 3.2.2, Janino 3.1.12, Parquet 1.18.0, JLine 4.3.1 with FFM, Protobuf Java 4.36.0 and Python 7.36.0, Netty 4.2.17.Final, Lettuce 7.7.0.RELEASE, Kafka 4.3.1, Confluent Platform 8.3.1, gRPC Java 1.83.1 and Python 1.83.0, Aircompressor 2.0.3, Hadoop 3.5.0, Maven Compiler Plugin 3.15.0, Maven JAR Plugin 3.5.1, Maven Install Plugin 3.1.4, Maven Dependency Plugin 3.11.0, an in-process Kotlin Maven compiler, MINA 2.2.9, Tomcat 11.0.25, PostgreSQL JDBC 42.7.13, Hibernate ORM 7.4.5.Final, LZ4 Java 1.11.2, Apache HTTP Core 5.4.3, Apache HTTP Client 5.6.4, Elasticsearch Java API Client 9.5.1, Commons Configuration 2.15.1, OpenTelemetry 1.65.0, Log4j 2.26.1, Debezium 3.6.1.Final, Bouncy Castle 1.85, ZooKeeper 3.9.5, Wire 6.4.6, Micrometer 1.17.1, RabbitMQ client 5.35.0, Plexus Utils 4.1.0, Logback 1.6.3, Vert.x 5.1.6, Spring Boot 3.5.16 and 4.1.1, and Spring Framework 6.2.19 and 7.0.9. It also verifies that Jansi, the removed Spring 5 profile, legacy Debezium configuration keys, Elasticsearch HLRC, embedded Schema Registry server, Hadoop MiniDFSCluster, Jetty, and dependency-owned JUnit platform settings are absent from their governed outputs. +2. Every reactor POM and command-line test fixture resolves the maintained artifact at 5.7.3-pasturestack.2, while generated cluster runtime metadata resolves to numeric version 5.7.3. Maven Wrapper 3.9.16 is downloaded only from Maven Central; its ZIP and tar.gz distributions are verified against separate committed SHA-256 values before execution. The source version gate requires Java 25, Ubuntu 24.04 LTS cloud test images, Checkstyle 14.0.0, Avro 1.12.2, Jackson 2.22.2 and 3.2.2, Janino 3.1.12, Parquet 1.18.0, JLine 4.3.1 with FFM, Protobuf Java 4.36.0 and Python 7.36.0, Netty 4.2.17.Final, Lettuce 7.7.0.RELEASE, Kafka 4.3.1, Confluent Platform 8.3.1, gRPC Java 1.83.1 and Python 1.83.0, Aircompressor 2.0.3, Hadoop 3.5.0, Maven Compiler Plugin 3.15.0, Maven JAR Plugin 3.5.1, Maven Install Plugin 3.1.4, Maven Dependency Plugin 3.11.0, an in-process Kotlin Maven compiler, MINA 2.2.9, Tomcat 11.0.25, PostgreSQL JDBC 42.7.13, Hibernate ORM 7.4.5.Final, LZ4 Java 1.11.2, Apache HTTP Core 5.4.3, Apache HTTP Client 5.6.4, Elasticsearch Java API Client 9.5.1, Commons Configuration 2.15.1, OpenTelemetry 1.65.0, Log4j 2.26.1, Debezium 3.6.1.Final, Bouncy Castle 1.85, ZooKeeper 3.9.5, Wire 6.4.6, Micrometer 1.17.1, RabbitMQ client 5.35.0, Plexus Utils 4.1.0, Logback 1.6.3, Vert.x 5.1.6, Spring Boot 4.1.1, and Spring Framework 7.0.9. It also verifies that Jansi, all Spring Boot 3 / Spring Framework 6 compatibility profiles and artifacts, legacy Debezium configuration keys, Elasticsearch HLRC, embedded Schema Registry server, Hadoop MiniDFSCluster, Jetty, and dependency-owned JUnit platform settings are absent from their governed outputs. 3. Maven's resolved dependency graph contains those reviewed versions, no older duplicate of the same artifacts, no Elasticsearch HLRC/server/Lucene legacy graph in the Elasticsearch connector, and no `org.eclipse.jetty` graph in the Kafka, SQL, Hadoop distribution, Azure, or S3 modules. 4. The produced file is `hazelcast-5.7.3-pasturestack.2.jar`; its embedded core Maven metadata reports 5.7.3-pasturestack.2, its generated cluster runtime metadata reports numeric version 5.7.3, and its embedded Jackson metadata reports Jackson 2.22.2 and Jackson 3.2.2. The full source commit and abbreviated revision embedded in `GeneratedBuildProperties` must match the OCI revision supplied to the build; unresolved placeholders are rejected during packaging. 5. Relevant core, Spring, database, and distribution integration tests pass on Java 25 LTS. The focused source-boundary suite must retain its expected suite and test counts so an accidentally undiscovered test cannot appear successful. diff --git a/hazelcast-archunit-rules/src/main/java/com/hazelcast/test/archunit/CompletableFutureUsageCondition.java b/hazelcast-archunit-rules/src/main/java/com/hazelcast/test/archunit/CompletableFutureUsageCondition.java index 0240b26245007..3f72424b7ae16 100644 --- a/hazelcast-archunit-rules/src/main/java/com/hazelcast/test/archunit/CompletableFutureUsageCondition.java +++ b/hazelcast-archunit-rules/src/main/java/com/hazelcast/test/archunit/CompletableFutureUsageCondition.java @@ -24,8 +24,6 @@ import com.tngtech.archunit.lang.ArchCondition; import com.tngtech.archunit.lang.ConditionEvents; -import java.util.Arrays; -import java.util.Collection; import java.util.List; import java.util.Set; import java.util.concurrent.CompletableFuture; @@ -56,13 +54,6 @@ public class CompletableFutureUsageCondition extends ArchCondition { .collect(toSet()); private static final Set SYNC_AND_ASYNC_METHODS = collectSyncAndAsyncCounterpartMethods(); - //TODO Remove Java 8 compatibility code after JDK upgrade - static { - Collection excludedSyncMethodsForJava8Compatibility - = Arrays.asList("exceptionally"); - SYNC_AND_ASYNC_METHODS.removeAll(excludedSyncMethodsForJava8Compatibility); - } - CompletableFutureUsageCondition() { super("use only CompletableFuture async methods with explicit executor service"); } diff --git a/hazelcast-parent/pom.xml b/hazelcast-parent/pom.xml index 936d2713854c6..e572bc54f1d03 100644 --- a/hazelcast-parent/pom.xml +++ b/hazelcast-parent/pom.xml @@ -93,7 +93,10 @@ 1.12.2 - + 2.0.3 2.54.2 1.42.0 @@ -129,11 +132,8 @@ 1.18.0 - 3.5.16 - 6.2.19 - - 4.1.1 - 7.0.9 + 4.1.1 + 7.0.9 2.2.9 @@ -1658,61 +1658,6 @@ - - - spring-7 - - - - !tested.spring.override - - - - - ${spring.boot4.version} - ${org.springframework7.version} - - - - jakarta.inject - jakarta.inject-api - 2.0.1 - test - - - - - spring-6 - - - tested.spring.override - 6 - - - - - ${spring.boot3.version} - ${org.springframework6.version} - - - - javax.inject - javax.inject - 1 - test - - - diff --git a/hazelcast-spring-boot-autoconfiguration/hazelcast-spring-boot3/pom.xml b/hazelcast-spring-boot-autoconfiguration/hazelcast-spring-boot3/pom.xml deleted file mode 100644 index df1c9d88bc62e..0000000000000 --- a/hazelcast-spring-boot-autoconfiguration/hazelcast-spring-boot3/pom.xml +++ /dev/null @@ -1,131 +0,0 @@ - - - - 4.0.0 - - hazelcast-spring-boot3 - hazelcast-spring-boot3 - jar - - - com.hazelcast - hazelcast-spring-boot-autoconfiguration - 5.7.3-pasturestack.2 - ../pom.xml - - - - - ${project.parent.parent.basedir} - - - - - - org.apache.maven.plugins - maven-jar-plugin - - - - false - true - true - - - - - - - maven-resources-plugin - - - add-notice-and-license - process-classes - - - - - - - - - - - com.hazelcast - hazelcast-parent - ${project.parent.version} - pom - import - - - org.springframework.boot - spring-boot-dependencies - ${spring.boot3.version} - pom - import - - - - - - - com.hazelcast - hazelcast-spring - ${project.parent.version} - - - - com.hazelcast - hazelcast - - - - - org.springframework.boot - spring-boot-autoconfigure - provided - - - - - org.springframework - spring-test - test - - - org.springframework.boot - spring-boot-starter-test - test - - - org.springframework.boot - spring-boot-starter-logging - - - org.junit.vintage - junit-vintage-engine - - - - - org.springframework.boot - spring-boot-starter-log4j2 - test - - - diff --git a/hazelcast-spring-boot-autoconfiguration/hazelcast-spring-boot3/src/main/java/com/hazelcast/spring/boot3/HazelcastBoot3ObjectExtractionAutoConfiguration.java b/hazelcast-spring-boot-autoconfiguration/hazelcast-spring-boot3/src/main/java/com/hazelcast/spring/boot3/HazelcastBoot3ObjectExtractionAutoConfiguration.java deleted file mode 100644 index 1a9be7c2e6acd..0000000000000 --- a/hazelcast-spring-boot-autoconfiguration/hazelcast-spring-boot3/src/main/java/com/hazelcast/spring/boot3/HazelcastBoot3ObjectExtractionAutoConfiguration.java +++ /dev/null @@ -1,55 +0,0 @@ -/* - * Copyright (c) 2008-2026, Hazelcast, Inc. All Rights Reserved. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package com.hazelcast.spring.boot3; - -import com.hazelcast.core.HazelcastException; -import com.hazelcast.spring.HazelcastObjectExtractionConfiguration; -import org.springframework.beans.factory.InitializingBean; -import org.springframework.boot.SpringBootVersion; -import org.springframework.boot.autoconfigure.AutoConfiguration; -import org.springframework.boot.autoconfigure.AutoConfigureAfter; -import org.springframework.context.annotation.Configuration; -import org.springframework.context.annotation.Import; - -/** - * Auto Configuration for {@link HazelcastObjectExtractionConfiguration}, compatible with Spring Boot 3. - * @since 5.7 - */ -@Configuration(proxyBeanMethods = false) -@AutoConfiguration -@AutoConfigureAfter(name = { - // Boot 3.x, avoid direct class usage due to JavaDoc generation error - it does not see actuator 3.x when - // applying javadoc:aggregate, as it sees 4.x from the boot 4 module. - "org.springframework.boot.autoconfigure.hazelcast.HazelcastAutoConfiguration", - "com.hazelcast.spring.HazelcastExposeObjectRegistrar" }) -@Import(HazelcastObjectExtractionConfiguration.class) -public class HazelcastBoot3ObjectExtractionAutoConfiguration implements InitializingBean { - - private static final int REQUIRED_SPRING_BOOT_VERSION = 3; - - @Override - public void afterPropertiesSet() { - String version = SpringBootVersion.getVersion(); - int detectedSpringMajorVersion = Integer.parseInt(version.split("\\.")[0]); - - if (detectedSpringMajorVersion != REQUIRED_SPRING_BOOT_VERSION) { - String msg = "You're using hazelcast-spring-boot3 for Spring Boot 3.x, " - + "but your Spring Boot version is " + SpringBootVersion.getVersion() + ". " - + "Please use hazelcast-spring-boot" + detectedSpringMajorVersion + " instead."; - throw new HazelcastException(msg); - } - } -} diff --git a/hazelcast-spring-boot-autoconfiguration/hazelcast-spring-boot3/src/main/java/com/hazelcast/spring/boot3/package-info.java b/hazelcast-spring-boot-autoconfiguration/hazelcast-spring-boot3/src/main/java/com/hazelcast/spring/boot3/package-info.java deleted file mode 100644 index 8c1537986229c..0000000000000 --- a/hazelcast-spring-boot-autoconfiguration/hazelcast-spring-boot3/src/main/java/com/hazelcast/spring/boot3/package-info.java +++ /dev/null @@ -1,20 +0,0 @@ -/* - * Copyright (c) 2008-2026, Hazelcast, Inc. All Rights Reserved. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -/** - * Provides Spring interfaces/classes for Hazelcast. - */ -package com.hazelcast.spring.boot3; diff --git a/hazelcast-spring-boot-autoconfiguration/hazelcast-spring-boot3/src/main/resources/META-INF/spring/org.springframework.boot.autoconfigure.AutoConfiguration.imports b/hazelcast-spring-boot-autoconfiguration/hazelcast-spring-boot3/src/main/resources/META-INF/spring/org.springframework.boot.autoconfigure.AutoConfiguration.imports deleted file mode 100644 index d59f6e6161490..0000000000000 --- a/hazelcast-spring-boot-autoconfiguration/hazelcast-spring-boot3/src/main/resources/META-INF/spring/org.springframework.boot.autoconfigure.AutoConfiguration.imports +++ /dev/null @@ -1 +0,0 @@ -com.hazelcast.spring.boot3.HazelcastBoot3ObjectExtractionAutoConfiguration diff --git a/hazelcast-spring-boot-autoconfiguration/hazelcast-spring-boot3/src/test/java/com/hazelcast/it/CheckSpringNoticeFileIT.java b/hazelcast-spring-boot-autoconfiguration/hazelcast-spring-boot3/src/test/java/com/hazelcast/it/CheckSpringNoticeFileIT.java deleted file mode 100644 index 2a8f97bb6d93c..0000000000000 --- a/hazelcast-spring-boot-autoconfiguration/hazelcast-spring-boot3/src/test/java/com/hazelcast/it/CheckSpringNoticeFileIT.java +++ /dev/null @@ -1,20 +0,0 @@ -/* - * Copyright (c) 2008-2026, Hazelcast, Inc. All Rights Reserved. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package com.hazelcast.it; - -public class CheckSpringNoticeFileIT extends CheckNoticeFileIT { -} diff --git a/hazelcast-spring-boot-autoconfiguration/hazelcast-spring-boot3/src/test/java/com/hazelcast/spring/boot3/AllDistributedObjectsAreIncludedTest.java b/hazelcast-spring-boot-autoconfiguration/hazelcast-spring-boot3/src/test/java/com/hazelcast/spring/boot3/AllDistributedObjectsAreIncludedTest.java deleted file mode 100644 index 6214f2c1a8938..0000000000000 --- a/hazelcast-spring-boot-autoconfiguration/hazelcast-spring-boot3/src/test/java/com/hazelcast/spring/boot3/AllDistributedObjectsAreIncludedTest.java +++ /dev/null @@ -1,30 +0,0 @@ -/* - * Copyright (c) 2008-2026, Hazelcast, Inc. All Rights Reserved. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package com.hazelcast.spring.boot3; - -import com.hazelcast.spring.CustomSpringExtension; -import com.hazelcast.spring.java.AllDistributedObjectsAreIncludedTestBase; -import org.junit.jupiter.api.extension.ExtendWith; -import org.springframework.boot.test.context.SpringBootTest; -import org.springframework.test.annotation.DirtiesContext; -import org.springframework.test.context.junit.jupiter.SpringExtension; - -@SpringBootTest(classes = Spring3HazelcastConfiguration.class) -@DirtiesContext(classMode = DirtiesContext.ClassMode.AFTER_CLASS) -@ExtendWith({SpringExtension.class, CustomSpringExtension.class}) -public class AllDistributedObjectsAreIncludedTest extends AllDistributedObjectsAreIncludedTestBase { - -} diff --git a/hazelcast-spring-boot-autoconfiguration/hazelcast-spring-boot3/src/test/java/com/hazelcast/spring/boot3/BootConfiguredContextTest.java b/hazelcast-spring-boot-autoconfiguration/hazelcast-spring-boot3/src/test/java/com/hazelcast/spring/boot3/BootConfiguredContextTest.java deleted file mode 100644 index 2a5c3fe2258b2..0000000000000 --- a/hazelcast-spring-boot-autoconfiguration/hazelcast-spring-boot3/src/test/java/com/hazelcast/spring/boot3/BootConfiguredContextTest.java +++ /dev/null @@ -1,61 +0,0 @@ -/* - * Copyright (c) 2008-2026, Hazelcast, Inc. All Rights Reserved. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package com.hazelcast.spring.boot3; - -import com.hazelcast.core.HazelcastInstance; -import com.hazelcast.instance.impl.HazelcastInstanceFactory; -import com.hazelcast.spring.ConfigCreator; -import com.hazelcast.spring.CustomSpringExtension; -import com.hazelcast.spring.java.AppContextTestBase; -import org.junit.jupiter.api.Test; -import org.junit.jupiter.api.extension.ExtendWith; -import org.springframework.boot.SpringApplication; -import org.springframework.boot.autoconfigure.SpringBootApplication; -import org.springframework.boot.test.context.SpringBootTest; -import org.springframework.context.annotation.Bean; -import org.springframework.test.context.junit.jupiter.SpringExtension; - -import static com.hazelcast.test.HazelcastTestSupport.assertEqualsEventually; -import static org.assertj.core.api.Assertions.assertThat; - -@SpringBootTest(classes = BootConfiguredContextTest.SpringHazelcastBootConfiguration.class) -@ExtendWith({SpringExtension.class, CustomSpringExtension.class}) -public class BootConfiguredContextTest extends AppContextTestBase { - - @Test - @Override - public void testMap() { - assertThat((Object) map1).isNotNull(); - assertThat((Object) testMap).isNotNull(); - - testMap.set("key1", "value1"); - assertEqualsEventually(() -> testMap.get("key1"), "value1"); - } - - @SpringBootApplication(scanBasePackages = "com.hazelcast.non.existing") - public static class SpringHazelcastBootConfiguration { - - public static void main(String[] args) { - SpringApplication.run(SpringHazelcastBootConfiguration.class, args); - } - - @Bean(destroyMethod = "shutdown") - public HazelcastInstance hazelcastInstance() { - return HazelcastInstanceFactory.newHazelcastInstance(ConfigCreator.createConfigWithStructures()); - } - } -} diff --git a/hazelcast-spring-boot-autoconfiguration/hazelcast-spring-boot3/src/test/java/com/hazelcast/spring/boot3/ExcludeByNameTest.java b/hazelcast-spring-boot-autoconfiguration/hazelcast-spring-boot3/src/test/java/com/hazelcast/spring/boot3/ExcludeByNameTest.java deleted file mode 100644 index 849daafc79b4f..0000000000000 --- a/hazelcast-spring-boot-autoconfiguration/hazelcast-spring-boot3/src/test/java/com/hazelcast/spring/boot3/ExcludeByNameTest.java +++ /dev/null @@ -1,29 +0,0 @@ -/* - * Copyright (c) 2008-2026, Hazelcast, Inc. All Rights Reserved. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package com.hazelcast.spring.boot3; - -import com.hazelcast.spring.CustomSpringExtension; -import org.junit.jupiter.api.extension.ExtendWith; -import org.springframework.boot.test.context.SpringBootTest; -import org.springframework.test.annotation.DirtiesContext; -import org.springframework.test.context.junit.jupiter.SpringExtension; - -@SpringBootTest(classes = com.hazelcast.spring.java.ExcludeByNameTest.UsingExcludeByName.class) -@DirtiesContext(classMode = DirtiesContext.ClassMode.AFTER_CLASS) -@ExtendWith({SpringExtension.class, CustomSpringExtension.class}) -class ExcludeByNameTest extends com.hazelcast.spring.java.ExcludeByNameTest { - -} diff --git a/hazelcast-spring-boot-autoconfiguration/hazelcast-spring-boot3/src/test/java/com/hazelcast/spring/boot3/ExcludeByTypeTest.java b/hazelcast-spring-boot-autoconfiguration/hazelcast-spring-boot3/src/test/java/com/hazelcast/spring/boot3/ExcludeByTypeTest.java deleted file mode 100644 index 98e45e9f16e39..0000000000000 --- a/hazelcast-spring-boot-autoconfiguration/hazelcast-spring-boot3/src/test/java/com/hazelcast/spring/boot3/ExcludeByTypeTest.java +++ /dev/null @@ -1,29 +0,0 @@ -/* - * Copyright (c) 2008-2026, Hazelcast, Inc. All Rights Reserved. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package com.hazelcast.spring.boot3; - -import com.hazelcast.spring.CustomSpringExtension; -import org.junit.jupiter.api.extension.ExtendWith; -import org.springframework.boot.test.context.SpringBootTest; -import org.springframework.test.annotation.DirtiesContext; -import org.springframework.test.context.junit.jupiter.SpringExtension; - -@SpringBootTest(classes = com.hazelcast.spring.java.ExcludeByTypeTest.UsingExcludeByType.class) -@DirtiesContext(classMode = DirtiesContext.ClassMode.AFTER_CLASS) -@ExtendWith({SpringExtension.class, CustomSpringExtension.class}) -class ExcludeByTypeTest extends com.hazelcast.spring.java.ExcludeByTypeTest { - -} diff --git a/hazelcast-spring-boot-autoconfiguration/hazelcast-spring-boot3/src/test/java/com/hazelcast/spring/boot3/FullContextTest.java b/hazelcast-spring-boot-autoconfiguration/hazelcast-spring-boot3/src/test/java/com/hazelcast/spring/boot3/FullContextTest.java deleted file mode 100644 index 2d7f2b99c62cd..0000000000000 --- a/hazelcast-spring-boot-autoconfiguration/hazelcast-spring-boot3/src/test/java/com/hazelcast/spring/boot3/FullContextTest.java +++ /dev/null @@ -1,42 +0,0 @@ -/* - * Copyright (c) 2008-2026, Hazelcast, Inc. All Rights Reserved. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package com.hazelcast.spring.boot3; - -import com.hazelcast.spring.CustomSpringExtension; -import com.hazelcast.spring.java.AppContextTestBase; -import org.junit.jupiter.api.Test; -import org.junit.jupiter.api.extension.ExtendWith; -import org.springframework.boot.test.context.SpringBootTest; -import org.springframework.test.annotation.DirtiesContext; -import org.springframework.test.context.junit.jupiter.SpringExtension; - -import static com.hazelcast.test.HazelcastTestSupport.assertEqualsEventually; -import static org.assertj.core.api.Assertions.assertThat; - -@SpringBootTest(classes = Spring3HazelcastConfiguration.class) -@DirtiesContext(classMode = DirtiesContext.ClassMode.AFTER_CLASS) -@ExtendWith({SpringExtension.class, CustomSpringExtension.class}) -public class FullContextTest extends AppContextTestBase { - - @Test - @Override - public void testMap() { - assertThat((Object) map1).isNotNull(); - map1.set("key1", "value1"); - assertEqualsEventually(() -> map1.get("key1"), "value1"); - } -} diff --git a/hazelcast-spring-boot-autoconfiguration/hazelcast-spring-boot3/src/test/java/com/hazelcast/spring/boot3/IncludeByNameTest.java b/hazelcast-spring-boot-autoconfiguration/hazelcast-spring-boot3/src/test/java/com/hazelcast/spring/boot3/IncludeByNameTest.java deleted file mode 100644 index 515e21a1817b5..0000000000000 --- a/hazelcast-spring-boot-autoconfiguration/hazelcast-spring-boot3/src/test/java/com/hazelcast/spring/boot3/IncludeByNameTest.java +++ /dev/null @@ -1,29 +0,0 @@ -/* - * Copyright (c) 2008-2026, Hazelcast, Inc. All Rights Reserved. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package com.hazelcast.spring.boot3; - -import com.hazelcast.spring.CustomSpringExtension; -import org.junit.jupiter.api.extension.ExtendWith; -import org.springframework.boot.test.context.SpringBootTest; -import org.springframework.test.annotation.DirtiesContext; -import org.springframework.test.context.junit.jupiter.SpringExtension; - -@SpringBootTest(classes = com.hazelcast.spring.java.IncludeByNameTest.UsingIncludeByName.class) -@DirtiesContext(classMode = DirtiesContext.ClassMode.AFTER_CLASS) -@ExtendWith({SpringExtension.class, CustomSpringExtension.class}) -class IncludeByNameTest extends com.hazelcast.spring.java.IncludeByNameTest { - -} diff --git a/hazelcast-spring-boot-autoconfiguration/hazelcast-spring-boot3/src/test/java/com/hazelcast/spring/boot3/IncludeByTypeTest.java b/hazelcast-spring-boot-autoconfiguration/hazelcast-spring-boot3/src/test/java/com/hazelcast/spring/boot3/IncludeByTypeTest.java deleted file mode 100644 index 682139ee5597c..0000000000000 --- a/hazelcast-spring-boot-autoconfiguration/hazelcast-spring-boot3/src/test/java/com/hazelcast/spring/boot3/IncludeByTypeTest.java +++ /dev/null @@ -1,29 +0,0 @@ -/* - * Copyright (c) 2008-2026, Hazelcast, Inc. All Rights Reserved. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package com.hazelcast.spring.boot3; - -import com.hazelcast.spring.CustomSpringExtension; -import org.junit.jupiter.api.extension.ExtendWith; -import org.springframework.boot.test.context.SpringBootTest; -import org.springframework.test.annotation.DirtiesContext; -import org.springframework.test.context.junit.jupiter.SpringExtension; - -@SpringBootTest(classes = com.hazelcast.spring.java.IncludeByTypeTest.UsingIncludeByType.class) -@DirtiesContext(classMode = DirtiesContext.ClassMode.AFTER_CLASS) -@ExtendWith({SpringExtension.class, CustomSpringExtension.class}) -class IncludeByTypeTest extends com.hazelcast.spring.java.IncludeByTypeTest { - -} diff --git a/hazelcast-spring-boot-autoconfiguration/hazelcast-spring-boot3/src/test/java/com/hazelcast/spring/boot3/NoMixedJUnitAnnotationsInOurTestSourcesTest.java b/hazelcast-spring-boot-autoconfiguration/hazelcast-spring-boot3/src/test/java/com/hazelcast/spring/boot3/NoMixedJUnitAnnotationsInOurTestSourcesTest.java deleted file mode 100644 index 9cb2821c32240..0000000000000 --- a/hazelcast-spring-boot-autoconfiguration/hazelcast-spring-boot3/src/test/java/com/hazelcast/spring/boot3/NoMixedJUnitAnnotationsInOurTestSourcesTest.java +++ /dev/null @@ -1,34 +0,0 @@ -/* - * Copyright (c) 2008-2026, Hazelcast, Inc. All Rights Reserved. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package com.hazelcast.spring.boot3; - -import com.hazelcast.test.archunit.ArchUnitRules; -import com.hazelcast.test.archunit.ArchUnitTestSupport; -import com.hazelcast.test.archunit.ModuleImportOptions; -import com.tngtech.archunit.core.domain.JavaClasses; -import org.junit.Test; - -public class NoMixedJUnitAnnotationsInOurTestSourcesTest extends ArchUnitTestSupport { - - @Test - public void noJUnitMixing() { - String basePackage = "com.hazelcast"; - JavaClasses classes = ModuleImportOptions.getCurrentModuleTestClasses(basePackage); - - ArchUnitRules.NO_JUNIT_MIXING.check(classes); - } -} diff --git a/hazelcast-spring-boot-autoconfiguration/hazelcast-spring-boot3/src/test/java/com/hazelcast/spring/boot3/Spring3HazelcastConfiguration.java b/hazelcast-spring-boot-autoconfiguration/hazelcast-spring-boot3/src/test/java/com/hazelcast/spring/boot3/Spring3HazelcastConfiguration.java deleted file mode 100644 index dc994a090f721..0000000000000 --- a/hazelcast-spring-boot-autoconfiguration/hazelcast-spring-boot3/src/test/java/com/hazelcast/spring/boot3/Spring3HazelcastConfiguration.java +++ /dev/null @@ -1,45 +0,0 @@ -/* - * Copyright (c) 2008-2026, Hazelcast, Inc. All Rights Reserved. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package com.hazelcast.spring.boot3; - -import com.hazelcast.core.HazelcastInstance; -import com.hazelcast.instance.impl.HazelcastInstanceFactory; -import com.hazelcast.spring.ConfigCreator; -import org.springframework.boot.autoconfigure.EnableAutoConfiguration; -import org.springframework.context.annotation.Bean; -import org.springframework.context.annotation.Configuration; -import org.springframework.context.support.PropertySourcesPlaceholderConfigurer; -import org.springframework.core.io.ClassPathResource; - -/** - * A Java-based equivalent of {@code com/hazelcast/spring/springaware/springAware-enabled-applicationContext-hazelcast.xml} - */ -@Configuration(proxyBeanMethods = false) -@EnableAutoConfiguration -public class Spring3HazelcastConfiguration { - - @Bean(destroyMethod = "shutdown") - public HazelcastInstance hazelcastInstance() { - return HazelcastInstanceFactory.newHazelcastInstance(ConfigCreator.createConfigWithStructures()); - } - - @Bean - public PropertySourcesPlaceholderConfigurer propertyPlaceholderConfigurer() { - var propertyPlaceholderConfigurer = new PropertySourcesPlaceholderConfigurer(); - propertyPlaceholderConfigurer.setLocation(new ClassPathResource("hazelcast-default.properties")); - return propertyPlaceholderConfigurer; - } -} diff --git a/hazelcast-spring-boot-autoconfiguration/hazelcast-spring-boot3/src/test/java/com/hazelcast/spring/boot3/TestsHaveRunnersTest.java b/hazelcast-spring-boot-autoconfiguration/hazelcast-spring-boot3/src/test/java/com/hazelcast/spring/boot3/TestsHaveRunnersTest.java deleted file mode 100644 index 722aaafd81c56..0000000000000 --- a/hazelcast-spring-boot-autoconfiguration/hazelcast-spring-boot3/src/test/java/com/hazelcast/spring/boot3/TestsHaveRunnersTest.java +++ /dev/null @@ -1,34 +0,0 @@ -/* - * Copyright (c) 2008-2026, Hazelcast, Inc. All Rights Reserved. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package com.hazelcast.spring.boot3; - -import com.hazelcast.test.archunit.ArchUnitRules; -import com.hazelcast.test.archunit.ArchUnitTestSupport; -import com.hazelcast.test.archunit.ModuleImportOptions; -import com.tngtech.archunit.core.domain.JavaClasses; -import org.junit.Test; - -public class TestsHaveRunnersTest extends ArchUnitTestSupport { - - @Test - public void testHaveRunners() { - String basePackage = "com.hazelcast"; - JavaClasses classes = ModuleImportOptions.getCurrentModuleTestClasses(basePackage); - - ArchUnitRules.TESTS_HAVE_RUNNNERS.check(classes); - } -} diff --git a/hazelcast-spring-boot-autoconfiguration/hazelcast-spring-boot3/src/test/resources/hazelcast-default.properties b/hazelcast-spring-boot-autoconfiguration/hazelcast-spring-boot3/src/test/resources/hazelcast-default.properties deleted file mode 100644 index 95c539849e10c..0000000000000 --- a/hazelcast-spring-boot-autoconfiguration/hazelcast-spring-boot3/src/test/resources/hazelcast-default.properties +++ /dev/null @@ -1,52 +0,0 @@ -# -# Copyright (c) 2008-2026, Hazelcast, Inc. All Rights Reserved. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# - -cluster.name=spring-cluster -cluster.password=spring-cluster-pass -cluster.port=5700 -cluster.members=127.0.0.1:5700, 127.0.0.1:5701 -boolean.false=false -boolean.true=true -backup.count=6 -native.memory.size=64 -testMap.hotRestart.enabled=true -testMap.hotRestart.fsync=true -testMap.journal.enabled=true -testMap.journal.capacity=123 -testMap.journal.ttl=321 -testMap.merkleTree.enabled=true -testMap.merkleTree.depth=20 -map.conf.cache.deserialized.values=ALWAYS -wan.queue.capacity=5000 -jet.cooperative.thread.count=2 -testCache.merkleTree.enabled=true -testCache.merkleTree.depth=20 -dummy.eviction.size=1983 -failure.detector.ttl=1 -query.cache.batch.size=12 -metrics.enabled=false -preloader.storeIntervalSeconds=42 -persistent.memory.mode=MOUNTED -numa.node.first=0 -native.memory.unit=GIGABYTES -network.auto-detection=false -test.factory.id=1 -dataconnection.name=my-data-connection -dataconnection.url=jdbc:mysql://dummy:3306 -kubernetes.service.name=MY-SERVICE-NAME -kubernetes.service.label=MY-SERVICE-LABEL-VALUE -cp.member.count=0 -cp.group.size=0 diff --git a/hazelcast-spring-boot-autoconfiguration/hazelcast-spring-boot3/src/test/resources/log4j2.xml b/hazelcast-spring-boot-autoconfiguration/hazelcast-spring-boot3/src/test/resources/log4j2.xml deleted file mode 100644 index 30f09d97f0875..0000000000000 --- a/hazelcast-spring-boot-autoconfiguration/hazelcast-spring-boot3/src/test/resources/log4j2.xml +++ /dev/null @@ -1,34 +0,0 @@ - - - - - - - - - - - - - - - - - - - - diff --git a/hazelcast-spring-boot-autoconfiguration/hazelcast-spring-boot4/pom.xml b/hazelcast-spring-boot-autoconfiguration/hazelcast-spring-boot4/pom.xml index 8c31550c13ff6..32e79e8b33a5e 100644 --- a/hazelcast-spring-boot-autoconfiguration/hazelcast-spring-boot4/pom.xml +++ b/hazelcast-spring-boot-autoconfiguration/hazelcast-spring-boot4/pom.xml @@ -47,7 +47,7 @@ org.springframework.boot spring-boot-dependencies - ${spring.boot4.version} + ${spring.boot.version} pom import diff --git a/hazelcast-spring-boot-autoconfiguration/pom.xml b/hazelcast-spring-boot-autoconfiguration/pom.xml index 3bdccc7f67c73..c54462065881f 100644 --- a/hazelcast-spring-boot-autoconfiguration/pom.xml +++ b/hazelcast-spring-boot-autoconfiguration/pom.xml @@ -41,7 +41,6 @@ - hazelcast-spring-boot3 hazelcast-spring-boot4 diff --git a/hazelcast-spring-tests/pom.xml b/hazelcast-spring-tests/pom.xml index 0d203418c13a7..87a3a2c978b71 100644 --- a/hazelcast-spring-tests/pom.xml +++ b/hazelcast-spring-tests/pom.xml @@ -146,30 +146,12 @@ spring-boot-starter-log4j2 ${spring.boot.version} + + org.springframework.boot + spring-boot-hazelcast + ${spring.boot.version} + test + - - - - spring-7 - - - - !tested.spring.override - - - - - org.springframework.boot - spring-boot-hazelcast - ${spring.boot4.version} - test - - - - - diff --git a/hazelcast-spring/pom.xml b/hazelcast-spring/pom.xml index 5e7002ad93d38..fd042804af0b4 100644 --- a/hazelcast-spring/pom.xml +++ b/hazelcast-spring/pom.xml @@ -117,11 +117,7 @@ org.springframework.boot spring-boot-dependencies - - ${spring.boot3.version} + ${spring.boot.version} pom import diff --git a/hazelcast/src/main/java/com/hazelcast/config/EndpointConfig.java b/hazelcast/src/main/java/com/hazelcast/config/EndpointConfig.java index 310d6cb012a47..e3f4ae1157abf 100644 --- a/hazelcast/src/main/java/com/hazelcast/config/EndpointConfig.java +++ b/hazelcast/src/main/java/com/hazelcast/config/EndpointConfig.java @@ -353,7 +353,7 @@ public EndpointConfig setProtocolType(ProtocolType protocolType) { /** * Keep-Alive idle time: the number of seconds of idle time before keep-alive initiates a probe. * This option is only applicable when {@link #setSocketKeepAlive(boolean) keep alive is true}. - * Requires a recent JDK 8, JDK 11 or greater version that includes the required + * Requires JDK 25 or later and the required * JDK support. * * @return the configured value of Keep-Alive idle time. @@ -370,7 +370,7 @@ public int getSocketKeepIdleSeconds() { * Valid values are 1 to 32767. *

* This option is only applicable when {@link #setSocketKeepAlive(boolean) keep alive is true}. - * Requires a recent JDK 8, JDK 11 or greater version that includes the required + * Requires JDK 25 or later and the required * JDK support. * * @since 5.3.0 @@ -388,7 +388,7 @@ public EndpointConfig setSocketKeepIdleSeconds(int socketKeepIdleSeconds) { /** * Keep-Alive interval: the number of seconds between keep-alive probes. * This option is only applicable when {@link #setSocketKeepAlive(boolean) keep alive is true}. - * Requires a recent JDK 8, JDK 11 or greater version that includes the required + * Requires JDK 25 or later and the required * JDK support. * * @return the configured value of Keep-Alive interval time. @@ -405,8 +405,8 @@ public int getSocketKeepIntervalSeconds() { * Set the number of seconds between keep-alive probes. Notice that this is the number of seconds between probes after the * initial {@link #setSocketKeepIdleSeconds(int) keep-alive idle time} has passed. Valid values are 1 to 32767. *

- * This option is only applicable when {@link #setSocketKeepAlive(boolean) keep alive is true}. Requires a recent JDK 8, JDK - * 11 or greater version that includes the required JDK support. + * This option is only applicable when {@link #setSocketKeepAlive(boolean) keep alive is true}. Requires JDK 25 or later and + * the required JDK support. * * @since 5.3.0 * @see JDK support. * * @return the configured value of Keep-Alive probe count. @@ -442,7 +442,7 @@ public int getSocketKeepCount() { * response is obtained from the other side. Valid values are 1 to 127. *

* This option is only applicable when {@link #setSocketKeepAlive(boolean) keep alive is true}. - * Requires a recent JDK 8, JDK 11 or greater version that includes the required + * Requires JDK 25 or later and the required * JDK support. * * @since 5.3.0 diff --git a/hazelcast/src/main/java/com/hazelcast/internal/nio/IOUtil.java b/hazelcast/src/main/java/com/hazelcast/internal/nio/IOUtil.java index 66efac3fa9a6a..01457d043c156 100644 --- a/hazelcast/src/main/java/com/hazelcast/internal/nio/IOUtil.java +++ b/hazelcast/src/main/java/com/hazelcast/internal/nio/IOUtil.java @@ -900,10 +900,8 @@ private static void setOptionIfNotDefault(NetworkChannel serverSocketChannel } public static boolean supportsKeepAliveOptions(NetworkChannel channel) { - // According to https://bugs.openjdk.org/browse/JDK-8194298 per-socket keep alive options - // are supported for linux & macos in OpenJDK-based Java distributions since JDK 8u272 or JDK >= 11. - // See: ExtendedOptionsImpl.c in - // https://github.com/AdoptOpenJDK/openjdk-jdk8u/commit/13a9d5b0c222b92812f0bc69ac96c8b7755a63a9 + // JDK 25 exposes the extended keep-alive constants, but individual channel providers can + // still omit them. Keep the runtime capability check instead of assuming OS support. if (JDK_NET_TCP_KEEPCOUNT == null || JDK_NET_TCP_KEEPIDLE == null || JDK_NET_TCP_KEEPINTERVAL == null) { diff --git a/hazelcast/src/main/java/com/hazelcast/internal/util/function/package-info.java b/hazelcast/src/main/java/com/hazelcast/internal/util/function/package-info.java index 7b0d1959485dc..cce0f7a7930d1 100644 --- a/hazelcast/src/main/java/com/hazelcast/internal/util/function/package-info.java +++ b/hazelcast/src/main/java/com/hazelcast/internal/util/function/package-info.java @@ -15,8 +15,7 @@ */ /** - * Backport of Java 8 functional interfaces which Agrona depends on. - * Serializable and exception-declaring variants of functional interfaces from - * {@code java.util.function}. + * Primitive, serializable, and exception-declaring callback interfaces that + * are not provided by {@code java.util.function}. */ package com.hazelcast.internal.util.function; diff --git a/hazelcast/src/main/java/com/hazelcast/spi/properties/ClusterProperty.java b/hazelcast/src/main/java/com/hazelcast/spi/properties/ClusterProperty.java index 910d91705e00c..ca0c6de7d2e88 100644 --- a/hazelcast/src/main/java/com/hazelcast/spi/properties/ClusterProperty.java +++ b/hazelcast/src/main/java/com/hazelcast/spi/properties/ClusterProperty.java @@ -215,7 +215,7 @@ public final class ClusterProperty { *

    *
  • This option is only applicable to member-side sockets when {@link #SOCKET_KEEP_ALIVE keep alive is true}.
  • *
  • When using {@link AdvancedNetworkConfig}, set the respective socket option in {@link EndpointConfig}.
  • - *
  • Requires a recent JDK 8, JDK 11 or greater version that includes the required + *
  • Requires JDK 25 or later and the required * JDK support.
  • *
* @@ -233,7 +233,7 @@ public final class ClusterProperty { *
    *
  • This option is only applicable to member-side sockets when {@link #SOCKET_KEEP_ALIVE keep alive is true}.
  • *
  • When using {@link AdvancedNetworkConfig}, set the respective socket option in {@link EndpointConfig}.
  • - *
  • Requires a recent JDK 8, JDK 11 or greater version that includes the required + *
  • Requires JDK 25 or later and the required * JDK support.
  • *
* @@ -253,7 +253,7 @@ public final class ClusterProperty { *
    *
  • This option is only applicable to member-side sockets when {@link #SOCKET_KEEP_ALIVE keep alive is true}.
  • *
  • When using {@link AdvancedNetworkConfig}, set the respective socket option in {@link EndpointConfig}.
  • - *
  • Requires a recent JDK 8, JDK 11 or greater version that includes the required + *
  • Requires JDK 25 or later and the required * JDK support.
  • *
* @since 5.3.0 diff --git a/hazelcast/src/test/resources/com/hazelcast/client/console/testjob-with-hz-bootstrap/pom.xml b/hazelcast/src/test/resources/com/hazelcast/client/console/testjob-with-hz-bootstrap/pom.xml index a587c92d03c03..b75a8f5ba35f2 100644 --- a/hazelcast/src/test/resources/com/hazelcast/client/console/testjob-with-hz-bootstrap/pom.xml +++ b/hazelcast/src/test/resources/com/hazelcast/client/console/testjob-with-hz-bootstrap/pom.xml @@ -10,7 +10,7 @@ UTF-8 - 8 + 25 diff --git a/mvnw b/mvnw index bd8896bf2217b..b4d4cb3f72b24 100755 --- a/mvnw +++ b/mvnw @@ -108,11 +108,12 @@ trim() { scriptDir="$(dirname "$0")" scriptName="$(basename "$0")" -# parse distributionUrl and optional distributionSha256Sum, requires .mvn/wrapper/maven-wrapper.properties +# parse distributionUrl and optional archive-specific SHA-256 sums, requires .mvn/wrapper/maven-wrapper.properties while IFS="=" read -r key value; do case "${key-}" in distributionUrl) distributionUrl=$(trim "${value-}") ;; distributionSha256Sum) distributionSha256Sum=$(trim "${value-}") ;; + distributionSha256SumTarGz) distributionSha256SumTarGz=$(trim "${value-}") ;; esac done <"$scriptDir/.mvn/wrapper/maven-wrapper.properties" [ -n "${distributionUrl-}" ] || die "cannot read distributionUrl property in $scriptDir/.mvn/wrapper/maven-wrapper.properties" @@ -179,6 +180,9 @@ verbose "Downloading to: $TMP_DOWNLOAD_DIR/$distributionUrlName" if ! command -v unzip >/dev/null; then distributionUrl="${distributionUrl%.zip}.tar.gz" distributionUrlName="${distributionUrl##*/}" + [ -z "${distributionSha256Sum-}" ] || [ -n "${distributionSha256SumTarGz-}" ] || \ + die "distributionSha256SumTarGz is required when Maven Wrapper falls back to tar.gz" + distributionSha256Sum="${distributionSha256SumTarGz-}" fi # verbose opt diff --git a/scripts/pasturestack-build-runtime b/scripts/pasturestack-build-runtime index 6b761d46803e6..31f7486f2a73e 100755 --- a/scripts/pasturestack-build-runtime +++ b/scripts/pasturestack-build-runtime @@ -13,7 +13,10 @@ if find . -name pom.xml -type f -exec grep -l '5.7.0' {} + | echo 'PASTURESTACK_PROJECT_VERSION_MISMATCH expected=5.7.3-pasturestack.2' >&2 exit 1 fi -grep -Fq '3.5.16' hazelcast-parent/pom.xml +grep -Fq '4.1.1' hazelcast-parent/pom.xml +grep -Fq 'distributionUrl=https://repo.maven.apache.org/maven2/org/apache/maven/apache-maven/3.9.16/apache-maven-3.9.16-bin.zip' .mvn/wrapper/maven-wrapper.properties +grep -Fq 'distributionSha256Sum=5af3b743dd8b876b5c45da33b676251e5f1687712644abb4ee519ca56e1d89ce' .mvn/wrapper/maven-wrapper.properties +grep -Fq 'distributionSha256SumTarGz=80ffca22aed9e8b9713a232f3394fd81d7f20322df75efdb2b047dbd3e3a23bb' .mvn/wrapper/maven-wrapper.properties grep -Fq '25' hazelcast-parent/pom.xml grep -Fq '5.7.3' hazelcast-parent/pom.xml grep -Fq 'VERSION = "${hazelcast.runtime.version}"' hazelcast/src/main/template/com/hazelcast/instance/GeneratedBuildProperties.java @@ -49,9 +52,7 @@ grep -Fq '7.${protobuf.version}36.0' hazelcast-parent/pom.xml grep -Fq '4.2.17.Final' hazelcast-parent/pom.xml grep -A2 -F 'lettuce-core' extensions/kafka-connect/pom.xml | grep -Fq '7.7.0.RELEASE' -grep -Fq '6.2.19' hazelcast-parent/pom.xml -grep -Fq '4.1.1' hazelcast-parent/pom.xml -grep -Fq '7.0.9' hazelcast-parent/pom.xml +grep -Fq '7.0.9' hazelcast-parent/pom.xml grep -Fq '2.2.9' hazelcast-parent/pom.xml grep -Fq '4.3.1' hazelcast-parent/pom.xml grep -Fq '42.7.13' hazelcast-parent/pom.xml @@ -79,8 +80,10 @@ grep -A2 -F 'amqp-client' hazelcast-parent/pom.xml | gr grep -A2 -F 'plexus-utils' hazelcast-parent/pom.xml | grep -Fq '4.1.0' grep -A2 -F 'logback-core' hazelcast-parent/pom.xml | grep -Fq '1.6.3' grep -A2 -F 'vertx-core' hazelcast-parent/pom.xml | grep -Fq '5.1.6' -if grep -Fq 'spring-5' hazelcast-parent/pom.xml hazelcast-spring-tests/pom.xml; then - echo 'PASTURESTACK_EOL_PROFILE_PRESENT profile=spring-5' >&2 +if grep -R -E -q 'spring\.boot3\.version|org\.springframework6\.version|spring-[1-6]|hazelcast-spring-boot3|tested\.spring\.override' \ + hazelcast-parent/pom.xml hazelcast-spring/pom.xml hazelcast-spring-tests/pom.xml \ + hazelcast-spring-boot-autoconfiguration; then + echo 'PASTURESTACK_EOL_SPRING_LINE_PRESENT expected=Spring_Boot_4_and_Spring_Framework_7_only' >&2 exit 1 fi if grep -R -E -q 'database\.history|database\.server\.name|\.(white|black)list' \ @@ -129,7 +132,7 @@ grep -A1 -F 'maven-install-plugin' hazelcast-parent/pom grep -A1 -F 'maven-dependency-plugin' hazelcast-parent/pom.xml | grep -Fq '3.11.0' grep -Fq 'false' pom.xml grep -Fq '${jdk.version}' hazelcast/src/test/resources/com/hazelcast/client/console/testjob-with-hz-bootstrap/pom.xml -grep -Fq '8' hazelcast/src/test/resources/com/hazelcast/client/console/testjob-with-hz-bootstrap/pom.xml +grep -Fq '25' hazelcast/src/test/resources/com/hazelcast/client/console/testjob-with-hz-bootstrap/pom.xml grep -Fq '-Xlint:-options' hazelcast/src/test/resources/com/hazelcast/client/console/testjob-with-hz-bootstrap/pom.xml grep -Fq '25' hazelcast/src/test/resources/com/hazelcast/client/console/testjob-with-hazelcast-codebase/pom.xml grep -Fq '25' hazelcast/src/test/resources/com/hazelcast/client/console/testjob-with-jet-bootstrap/pom.xml