APM Server version: v8.3.0
APM Agent language and version: Java 1.33.0
Hi,
I followed the instruction to set up the self-attached APM agent: Programmatic API setup to self-attach | APM Java Agent Reference [1.x] | Elastic
I'm using the hosted solution trial for now.
I also use Spring as shown in the instruction. This is how my integration looks like.
Application.java
:
@SpringBootApplication
public class Application {
public static void main(String[] args) {
ElasticApmAttacher.attach();
....
}
....
It seems that the agent is starting up, but I can not see any traces besides some of the out of the box HTTP request tracces.
When I check the logs of the apm-agent I see the following error:
2022-07-27 15:17:30,088 [main] ERROR co.elastic.apm.agent.bci.IndyBootstrap - /tmp/elastic-apm-agent-4813494d137e1631bba301d5acab6e7b-86822b39e3d2d51b43d223be133a44ec.jar
java.nio.file.FileSystemNotFoundException: /tmp/elastic-apm-agent-4813494d137e1631bba301d5acab6e7b-86822b39e3d2d51b43d223be133a44ec.jar
at jdk.nio.zipfs.ZipFileSystem.<init>(ZipFileSystem.java:123) ~[jdk.zipfs:?]
at jdk.nio.zipfs.ZipFileSystemProvider.newFileSystem(ZipFileSystemProvider.java:109) ~[jdk.zipfs:?]
at java.nio.file.FileSystems.newFileSystem(FileSystems.java:337) ~[?:?]
at java.nio.file.FileSystems.newFileSystem(FileSystems.java:286) ~[?:?]
at co.elastic.apm.agent.util.PackageScanner.getClassNames(PackageScanner.java:61) ~[elastic-apm-agent-4813494d137e1631bba301d5acab6e7b-86822b39e3d2d51b43d223be133a44ec.jar:1.33.0]
at co.elastic.apm.agent.bci.IndyBootstrap.getClassNamesFromBundledPlugin(IndyBootstrap.java:440) ~[elastic-apm-agent-4813494d137e1631bba301d5acab6e7b-86822b39e3d2d51b43d223be133a44ec.jar:1.33.0]
at co.elastic.apm.agent.bci.IndyBootstrap.bootstrap(IndyBootstrap.java:399) [elastic-apm-agent-4813494d137e1631bba301d5acab6e7b-86822b39e3d2d51b43d223be133a44ec.jar:1.33.0]
at jdk.internal.reflect.GeneratedMethodAccessor10.invoke(Unknown Source) ~[?:?]
at jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:?]
at java.lang.reflect.Method.invoke(Method.java:566) ~[?:?]
at java.lang.IndyBootstrapDispatcher.bootstrap(IndyBootstrapDispatcher.java:60) [?:?]
at java.lang.invoke.BootstrapMethodInvoker.invoke(BootstrapMethodInvoker.java:138) [?:?]
at java.lang.invoke.CallSite.makeSite(CallSite.java:307) [?:?]
at java.lang.invoke.MethodHandleNatives.linkCallSiteImpl(MethodHandleNatives.java:258) [?:?]
at java.lang.invoke.MethodHandleNatives.linkCallSite(MethodHandleNatives.java:248) [?:?]
at org.springframework.boot.web.embedded.undertow.UndertowServletWebServerFactory$Initializer.onStartup(UndertowServletWebServerFactory.java:507) [spring-boot-2.7.2.jar:2.7.2]
at io.undertow.servlet.core.DeploymentManagerImpl$1.call(DeploymentManagerImpl.java:204) [undertow-servlet-2.2.18.Final.jar:2.2.18.Final]
at io.undertow.servlet.core.DeploymentManagerImpl$1.call(DeploymentManagerImpl.java:187) [undertow-servlet-2.2.18.Final.jar:2.2.18.Final]
at io.undertow.servlet.core.ServletRequestContextThreadSetupAction$1.call(ServletRequestContextThreadSetupAction.java:42) [undertow-servlet-2.2.18.Final.jar:2.2.18.Final]
at io.undertow.servlet.core.ContextClassLoaderSetupAction$1.call(ContextClassLoaderSetupAction.java:43) [undertow-servlet-2.2.18.Final.jar:2.2.18.Final]
at io.undertow.servlet.core.DeploymentManagerImpl.deploy(DeploymentManagerImpl.java:255) [undertow-servlet-2.2.18.Final.jar:2.2.18.Final]
at org.springframework.boot.web.embedded.undertow.UndertowServletWebServerFactory.createManager(UndertowServletWebServerFactory.java:330) [spring-boot-2.7.2.jar:2.7.2]
at org.springframework.boot.web.embedded.undertow.UndertowServletWebServerFactory.getWebServer(UndertowServletWebServerFactory.java:299) [spring-boot-2.7.2.jar:2.7.2]
at org.springframework.boot.web.servlet.context.ServletWebServerApplicationContext.createWebServer(ServletWebServerApplicationContext.java:184) [spring-boot-2.7.2.jar:2.7.2]
at org.springframework.boot.web.servlet.context.ServletWebServerApplicationContext.onRefresh(ServletWebServerApplicationContext.java:162) [spring-boot-2.7.2.jar:2.7.2]
at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:577) [spring-context-5.3.22.jar:5.3.22]
at org.springframework.boot.web.servlet.context.ServletWebServerApplicationContext.refresh(ServletWebServerApplicationContext.java:147) [spring-boot-2.7.2.jar:2.7.2]
at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:734) [spring-boot-2.7.2.jar:2.7.2]
at org.springframework.boot.SpringApplication.refreshContext(SpringApplication.java:408) [spring-boot-2.7.2.jar:2.7.2]
at org.springframework.boot.SpringApplication.run(SpringApplication.java:308) [spring-boot-2.7.2.jar:2.7.2]
at org.springframework.boot.SpringApplication.run(SpringApplication.java:1306) [spring-boot-2.7.2.jar:2.7.2]
at org.springframework.boot.SpringApplication.run(SpringApplication.java:1295) [spring-boot-2.7.2.jar:2.7.2]
at com.bitmovin.api.encodings.encoder.Application.main(Application.java:21) [classes/:?]