Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -329,7 +329,7 @@ static Path findAgentJar(String installDir) throws IOException, UserException {

try (var apmStream = Files.list(apmModule)) {
final List<Path> paths = apmStream.filter(
path -> path.getFileName().toString().matches("elastic-apm-agent-\\d+\\.\\d+\\.\\d+\\.jar")
path -> path.getFileName().toString().matches("elastic-apm-agent-java8-\\d+\\.\\d+\\.\\d+\\.jar")
).toList();

if (paths.size() > 1) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -142,7 +142,7 @@ private Path makeFakeAgentJar() throws IOException {
Path tempFile = createTempFile();
Path apmPathDir = tempFile.getParent().resolve("modules").resolve("apm");
Files.createDirectories(apmPathDir);
Path apmAgentFile = apmPathDir.resolve("elastic-apm-agent-0.0.0.jar");
Path apmAgentFile = apmPathDir.resolve("elastic-apm-agent-java8-0.0.0.jar");
Files.move(tempFile, apmAgentFile);

return tempFile.getParent();
Expand Down
5 changes: 5 additions & 0 deletions docs/changelog/132651.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
pr: 132651
summary: Use java8 variant of apm-agent
area: Infra/Core
type: upgrade
issues: []
6 changes: 3 additions & 3 deletions gradle/verification-metadata.xml
Original file line number Diff line number Diff line change
Expand Up @@ -70,9 +70,9 @@
<sha256 value="10fe288fd7a2cdaf5175332b73529f9abf8fd54dcfff317d6967c0c35ffb133b" origin="Generated by Gradle"/>
</artifact>
</component>
<component group="co.elastic.apm" name="elastic-apm-agent" version="1.52.2">
<artifact name="elastic-apm-agent-1.52.2.jar">
<sha256 value="dee18355a06f66a425bd597d6447ccbe7e8b7a3c0667adb7b30da173e31044e0" origin="Generated by Gradle"/>
<component group="co.elastic.apm" name="elastic-apm-agent-java8" version="1.55.0">
<artifact name="elastic-apm-agent-java8-1.55.0.jar">
<sha256 value="a4f3ae98e180dd5138cc8c719889366fe7d3afcecdb618da6db0b144a1717ac8" origin="Generated by Gradle"/>
</artifact>
</component>
<component group="co.elastic.logging" name="ecs-logging-core" version="1.2.0">
Expand Down
2 changes: 1 addition & 1 deletion modules/apm/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ dependencies {
implementation "io.opentelemetry:opentelemetry-api:${otelVersion}"
implementation "io.opentelemetry:opentelemetry-context:${otelVersion}"
implementation "io.opentelemetry:opentelemetry-semconv:${otelSemconvVersion}"
runtimeOnly "co.elastic.apm:elastic-apm-agent:1.52.2"
runtimeOnly "co.elastic.apm:elastic-apm-agent-java8:1.55.0"

javaRestTestImplementation project(':modules:apm')
javaRestTestImplementation project(':test:framework')
Expand Down
2 changes: 1 addition & 1 deletion server/src/main/java/org/elasticsearch/node/Node.java
Original file line number Diff line number Diff line change
Expand Up @@ -219,7 +219,7 @@ public static void deleteTemporaryApmConfig(JvmInfo jvmInfo, BiConsumer<Exceptio
"\\" + File.separator,
".*modules",
"apm",
"elastic-apm-agent-\\d+\\.\\d+\\.\\d+\\.jar"
"elastic-apm-agent-java8-\\d+\\.\\d+\\.\\d+\\.jar"
);
if (parts[0].matches(APM_AGENT_CONFIG_FILE_REGEX)) {
if (parts.length == 2 && parts[1].startsWith("c=")) {
Expand Down