You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Spring framework version 6 (used by Spring Boot 3) changed the servlet API, moving away from javax.servlet and started using jakarta.servlet. This causes the Kamon instrumentation to fail at startup with the following exception (Kamon version 2.6.1):
Error => org.springframework.web.servlet.DispatcherServlet with message Cannot assign jakarta.servlet.http.HttpServletRequest request to interface javax.servlet.http.HttpServletRequest. Class loader: jdk.internal.loader.ClassLoaders$AppClassLoader@293a5bf6: java.lang.IllegalStateException: Cannot assign jakarta.servlet.http.HttpServletRequest request to interface javax.servlet.http.HttpServletRequest
at kanela.agent.libs.net.bytebuddy.asm.Advice$OffsetMapping$ForArgument.resolve(Advice.java:1581)
at kanela.agent.libs.net.bytebuddy.asm.Advice$OffsetMapping$ForArgument$Unresolved.resolve(Advice.java:1689)
at kanela.agent.libs.net.bytebuddy.asm.Advice$Dispatcher$Inlining$Resolved$ForMethodEnter.doApply(Advice.java:8684)
at kanela.agent.libs.net.bytebuddy.asm.Advice$Dispatcher$Inlining$Resolved$ForMethodEnter.apply(Advice.java:8642)
at kanela.agent.libs.net.bytebuddy.asm.Advice$Dispatcher$Inlining$Resolved$AdviceMethodInliner.visitMethod(Advice.java:8332)
This would be trivial to fix (just change the package name), but then it would break existing apps. Maybe there's a way to detect which version of the servlet API is installed and configure the instrumentation accordingly?
The text was updated successfully, but these errors were encountered:
Yes we can do this, the instrumentation advice to configure with a new package name can just be added alongside. I don't think there's anything that makes this a hard problem given that.
Spring framework version 6 (used by Spring Boot 3) changed the servlet API, moving away from
javax.servlet
and started usingjakarta.servlet
. This causes the Kamon instrumentation to fail at startup with the following exception (Kamon version 2.6.1):This would be trivial to fix (just change the package name), but then it would break existing apps. Maybe there's a way to detect which version of the servlet API is installed and configure the instrumentation accordingly?
The text was updated successfully, but these errors were encountered: