diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 63213a11f3..4c53347db9 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -308,7 +308,9 @@ jobs: distribution: 'temurin' - version: 21 distribution: 'temurin' - - version: 23 + - version: 24 + distribution: 'temurin' + - version: '25-ea' distribution: 'temurin' steps: - uses: actions/checkout@v4 diff --git a/apm-agent-core/src/test/java/co/elastic/apm/agent/util/JdkVersionTest.java b/apm-agent-core/src/test/java/co/elastic/apm/agent/util/JdkVersionTest.java index 32ff667b51..50273003a3 100644 --- a/apm-agent-core/src/test/java/co/elastic/apm/agent/util/JdkVersionTest.java +++ b/apm-agent-core/src/test/java/co/elastic/apm/agent/util/JdkVersionTest.java @@ -33,7 +33,6 @@ public class JdkVersionTest { private static List releaseSchedule() { // from https://www.oracle.com/java/technologies/java-se-support-roadmap.html return List.of( - Arguments.of(24, LocalDate.parse("2025-04-01")), Arguments.of(25, LocalDate.parse("2025-10-01")), Arguments.of(26, LocalDate.parse("2026-04-01")) ); diff --git a/apm-agent-plugins/apm-awslambda-plugin/src/test/java/co/elastic/apm/agent/awslambda/AbstractLambdaTest.java b/apm-agent-plugins/apm-awslambda-plugin/src/test/java/co/elastic/apm/agent/awslambda/AbstractLambdaTest.java index 7ba58a8206..c85302e72e 100644 --- a/apm-agent-plugins/apm-awslambda-plugin/src/test/java/co/elastic/apm/agent/awslambda/AbstractLambdaTest.java +++ b/apm-agent-plugins/apm-awslambda-plugin/src/test/java/co/elastic/apm/agent/awslambda/AbstractLambdaTest.java @@ -149,7 +149,9 @@ protected boolean supportsContextPropagation() { return true; } + static synchronized void initAllButInstrumentation() { + ElasticApmAgent.reset(); // reset the AbstractInstrumentationTest beforeAll initialization config = SpyConfiguration.createSpyConfig(); serverlessConfiguration = config.getConfig(ServerlessConfigurationImpl.class); doReturn(true).when(serverlessConfiguration).runsOnAwsLambda(); diff --git a/apm-agent-plugins/apm-profiling-plugin/src/test/java/co/elastic/apm/agent/profiler/CallTreeSpanifyTest.java b/apm-agent-plugins/apm-profiling-plugin/src/test/java/co/elastic/apm/agent/profiler/CallTreeSpanifyTest.java index 6fe80f177d..a2ddc43b38 100644 --- a/apm-agent-plugins/apm-profiling-plugin/src/test/java/co/elastic/apm/agent/profiler/CallTreeSpanifyTest.java +++ b/apm-agent-plugins/apm-profiling-plugin/src/test/java/co/elastic/apm/agent/profiler/CallTreeSpanifyTest.java @@ -30,7 +30,9 @@ import org.junit.jupiter.api.AfterEach; import org.junit.jupiter.api.BeforeEach; import org.junit.jupiter.api.Test; +import org.junit.jupiter.api.condition.DisabledForJreRange; import org.junit.jupiter.api.condition.DisabledOnOs; +import org.junit.jupiter.api.condition.JRE; import org.junit.jupiter.api.condition.OS; import org.stagemonitor.configuration.ConfigurationRegistry; @@ -67,6 +69,7 @@ void tearDown() throws IOException { @Test @DisabledOnOs(OS.WINDOWS) @DisabledOnAppleSilicon + @DisabledForJreRange(min = JRE.JAVA_24) void testSpanification() throws Exception { CallTree.Root callTree = CallTreeTest.getCallTree(tracer, new String[]{ " dd ", diff --git a/apm-agent-plugins/apm-profiling-plugin/src/test/java/co/elastic/apm/agent/profiler/CallTreeTest.java b/apm-agent-plugins/apm-profiling-plugin/src/test/java/co/elastic/apm/agent/profiler/CallTreeTest.java index 99040fba40..c67e3f553d 100644 --- a/apm-agent-plugins/apm-profiling-plugin/src/test/java/co/elastic/apm/agent/profiler/CallTreeTest.java +++ b/apm-agent-plugins/apm-profiling-plugin/src/test/java/co/elastic/apm/agent/profiler/CallTreeTest.java @@ -21,20 +21,25 @@ import co.elastic.apm.agent.MockReporter; import co.elastic.apm.agent.MockTracer; import co.elastic.apm.agent.configuration.SpyConfiguration; -import co.elastic.apm.agent.impl.transaction.*; -import co.elastic.apm.agent.tracer.configuration.TimeDuration; import co.elastic.apm.agent.impl.ElasticApmTracer; import co.elastic.apm.agent.impl.sampling.ConstantSampler; +import co.elastic.apm.agent.impl.transaction.AbstractSpanImpl; import co.elastic.apm.agent.impl.transaction.SpanImpl; +import co.elastic.apm.agent.impl.transaction.StackFrame; +import co.elastic.apm.agent.impl.transaction.TraceContextImpl; +import co.elastic.apm.agent.impl.transaction.TransactionImpl; import co.elastic.apm.agent.objectpool.NoopObjectPool; import co.elastic.apm.agent.objectpool.ObservableObjectPool; import co.elastic.apm.agent.objectpool.impl.ListBasedObjectPool; import co.elastic.apm.agent.testutils.DisabledOnAppleSilicon; +import co.elastic.apm.agent.tracer.configuration.TimeDuration; import org.junit.jupiter.api.AfterEach; import org.junit.jupiter.api.BeforeEach; import org.junit.jupiter.api.Disabled; import org.junit.jupiter.api.Test; +import org.junit.jupiter.api.condition.DisabledForJreRange; import org.junit.jupiter.api.condition.DisabledOnOs; +import org.junit.jupiter.api.condition.JRE; import org.junit.jupiter.api.condition.OS; import org.stagemonitor.configuration.ConfigurationRegistry; @@ -57,6 +62,7 @@ @DisabledOnOs(OS.WINDOWS) @DisabledOnAppleSilicon +@DisabledForJreRange(min = JRE.JAVA_24) class CallTreeTest { private MockReporter reporter; diff --git a/apm-agent-plugins/apm-profiling-plugin/src/test/java/co/elastic/apm/agent/profiler/SamplingProfilerQueueTest.java b/apm-agent-plugins/apm-profiling-plugin/src/test/java/co/elastic/apm/agent/profiler/SamplingProfilerQueueTest.java index 1a68e2d2a0..2c27e12e6e 100644 --- a/apm-agent-plugins/apm-profiling-plugin/src/test/java/co/elastic/apm/agent/profiler/SamplingProfilerQueueTest.java +++ b/apm-agent-plugins/apm-profiling-plugin/src/test/java/co/elastic/apm/agent/profiler/SamplingProfilerQueueTest.java @@ -24,7 +24,9 @@ import co.elastic.apm.agent.objectpool.ObjectPoolFactoryImpl; import co.elastic.apm.agent.testutils.DisabledOnAppleSilicon; import org.junit.jupiter.api.Test; +import org.junit.jupiter.api.condition.DisabledForJreRange; import org.junit.jupiter.api.condition.DisabledOnOs; +import org.junit.jupiter.api.condition.JRE; import org.junit.jupiter.api.condition.OS; import static org.assertj.core.api.Assertions.assertThat; @@ -35,6 +37,7 @@ public class SamplingProfilerQueueTest { @Test @DisabledOnOs(OS.WINDOWS) @DisabledOnAppleSilicon + @DisabledForJreRange(min = JRE.JAVA_24) void testFillQueue() throws Exception { System.out.println(System.getProperty("os.name")); diff --git a/apm-agent-plugins/apm-profiling-plugin/src/test/java/co/elastic/apm/agent/profiler/SamplingProfilerTest.java b/apm-agent-plugins/apm-profiling-plugin/src/test/java/co/elastic/apm/agent/profiler/SamplingProfilerTest.java index de7e720185..fd2de1c555 100644 --- a/apm-agent-plugins/apm-profiling-plugin/src/test/java/co/elastic/apm/agent/profiler/SamplingProfilerTest.java +++ b/apm-agent-plugins/apm-profiling-plugin/src/test/java/co/elastic/apm/agent/profiler/SamplingProfilerTest.java @@ -56,6 +56,7 @@ // async-profiler doesn't work on Windows @DisabledOnOs(OS.WINDOWS) @DisabledOnAppleSilicon +@DisabledForJreRange(min = JRE.JAVA_24) class SamplingProfilerTest { private MockReporter reporter; diff --git a/docs/reference/config-profiling.md b/docs/reference/config-profiling.md index 2ce94f80ed..0dbeca1aaa 100644 --- a/docs/reference/config-profiling.md +++ b/docs/reference/config-profiling.md @@ -63,7 +63,7 @@ The inferred spans are created after a profiling session has ended. This means t Only platform threads are supported. Virtual threads are not supported and will not be profiled. ::::{note} -This feature is not available on Windows and on OpenJ9 +This feature is not available on Windows and on OpenJ9. In addition only Java 7 to Java 23 are supported. :::: diff --git a/integration-tests/spring-boot-1-5/pom.xml b/integration-tests/spring-boot-1-5/pom.xml index 65da27408b..a04f68b12c 100644 --- a/integration-tests/spring-boot-1-5/pom.xml +++ b/integration-tests/spring-boot-1-5/pom.xml @@ -76,4 +76,16 @@ + + + + org.apache.maven.plugins + maven-failsafe-plugin + + --add-opens java.base/java.lang=ALL-UNNAMED + + + + + diff --git a/pom.xml b/pom.xml index 569b22c4c2..5349627dcc 100644 --- a/pom.xml +++ b/pom.xml @@ -116,7 +116,7 @@ 2.2.0 1.4.196 - 5.9.1 + 5.12.2 4.13.2 4.12.0 @@ -476,6 +476,19 @@ + org.jacoco jacoco-maven-plugin @@ -596,7 +609,7 @@ org.jacoco jacoco-maven-plugin - 0.8.8 + 0.8.13 org.codehaus.mojo