You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@skywalking.apache.org by "zhaidw (via GitHub)" <gi...@apache.org> on 2023/02/13 10:01:15 UTC
[GitHub] [skywalking] zhaidw opened a new issue, #10386: [Feature] request skywalking-agent support for servlet5.0+ for springboot3 projects
zhaidw opened a new issue, #10386:
URL: https://github.com/apache/skywalking/issues/10386
### Search before asking
- [X] I had searched in the [issues](https://github.com/apache/skywalking/issues?q=is%3Aissue) and found no similar feature requirement.
### Description
When use skywalking-agent for springboot3 project , it is base servlet 5.0, package javax.servlet. has removed to jakarta.servlet , so the agent runs with many NoSuchMethodError, please consider to support.
### Use case
skywalking-agent/logs/skywalking-api.log :
`
InstMethodsInter : class[class org.springframework.web.servlet.mvc.method.annotation.ServletInvocableHandlerMethod] after method[getBean] intercept failure
java.lang.NoSuchMethodError: 'javax.servlet.http.HttpServletRequest org.springframework.web.context.request.ServletRequestAttributes.getRequest()'
at org.apache.skywalking.apm.plugin.spring.mvc.v5.GetBeanInterceptor.afterMethod(GetBeanInterceptor.java:51)
at org.apache.skywalking.apm.agent.core.plugin.interceptor.enhance.InstMethodsInter.intercept(InstMethodsInter.java:97)
at org.springframework.web.method.HandlerMethod.getBean(HandlerMethod.java)
at org.springframework.web.method.support.InvocableHandlerMethod.doInvoke(InvocableHandlerMethod.java:207)
at org.springframework.web.method.support.InvocableHandlerMethod.invokeForRequest(InvocableHandlerMethod.java:152)
at org.springframework.web.servlet.mvc.method.annotation.ServletInvocableHandlerMethod.invokeAndHandle(ServletInvocableHandlerMethod.java:117)
at org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter.invokeHandlerMethod(RequestMappingHandlerAdapter.java:884)
at org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter.handleInternal(RequestMappingHandlerAdapter.java:797)
at org.springframework.web.servlet.mvc.method.AbstractHandlerMethodAdapter.handle(AbstractHandlerMethodAdapter.java:87)
at org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:1080)
at org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:973)
at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:1010)
at org.springframework.web.servlet.FrameworkServlet.doPost(FrameworkServlet.java:913)
**at jakarta.servlet.http.HttpServlet.service(HttpServlet.java:520)**
at org.springframework.web.servlet.FrameworkServlet.service(FrameworkServlet.java:884)
at jakarta.servlet.http.HttpServlet.service(HttpServlet.java:587)
at org.eclipse.jetty.servlet.ServletHolder.handle(ServletHolder.java:764)
at org.eclipse.jetty.servlet.ServletHandler$ChainEnd.doFilter(ServletHandler.java:1665)
`
### Related issues
_No response_
### Are you willing to submit a PR?
- [ ] Yes I am willing to submit a PR!
### Code of Conduct
- [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@skywalking.apache.org.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [skywalking] wu-sheng commented on issue #10386: [Feature] request skywalking-agent support for servlet5.0+ for springboot3 projects
Posted by "wu-sheng (via GitHub)" <gi...@apache.org>.
wu-sheng commented on issue #10386:
URL: https://github.com/apache/skywalking/issues/10386#issuecomment-1427671916
It is supported and will be in next release.
But noticet we don't respond for feature request. As a community, features exist when someone contributed.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@skywalking.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [skywalking] zhaidw commented on issue #10386: [Feature] request skywalking-agent support for servlet5.0+ for springboot3 projects
Posted by "zhaidw (via GitHub)" <gi...@apache.org>.
zhaidw commented on issue #10386:
URL: https://github.com/apache/skywalking/issues/10386#issuecomment-1624514743
It seems java agent 8.16.0 still not support servlet5.0+
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@skywalking.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [skywalking] lujiajing1126 commented on issue #10386: [Feature] request skywalking-agent support for servlet5.0+ for springboot3 projects
Posted by "lujiajing1126 (via GitHub)" <gi...@apache.org>.
lujiajing1126 commented on issue #10386:
URL: https://github.com/apache/skywalking/issues/10386#issuecomment-1624519849
> It seems java agent 8.16.0 still not support servlet5.0+
I am not sure what you meant. But have you enabled Spring MVC 6.x plugins located in the optional plugins?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@skywalking.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [skywalking] wu-sheng closed issue #10386: [Feature] request skywalking-agent support for servlet5.0+ for springboot3 projects
Posted by "wu-sheng (via GitHub)" <gi...@apache.org>.
wu-sheng closed issue #10386: [Feature] request skywalking-agent support for servlet5.0+ for springboot3 projects
URL: https://github.com/apache/skywalking/issues/10386
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@skywalking.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [skywalking] zhaidw commented on issue #10386: [Feature] request skywalking-agent support for servlet5.0+ for springboot3 projects
Posted by "zhaidw (via GitHub)" <gi...@apache.org>.
zhaidw commented on issue #10386:
URL: https://github.com/apache/skywalking/issues/10386#issuecomment-1624639033
Thanks, I want use agent to support springboot3.0 with spring6.x and servlet5.0+
I had read doc:
https://skywalking.apache.org/docs/skywalking-java/v8.16.0/en/setup/service-agent/java-agent/optional-plugins/
cp optional-plugins/apm-springmvc-annotation-6.x-plugin-8.16.0.jar plugins/
cp optional-plugins/apm-mybatis-3.x-plugin-8.16.0.jar plugins/
cp optional-plugins/apm-jackson-2.x-plugin-8.16.0.jar plugins/
cp optional-plugins/apm-spring-tx-plugin-8.16.0.jar plugins/
cp optional-plugins/jakarta.servlet-api-5.0.0.jar plugins/
I copied these plugins, now dashboard now received data and can show charts data.
In agents logs, the following error shoud I just ignored ?
Caused by: java.lang.NoClassDefFoundError: javax/servlet/http/HttpServletRequest
at java.base/java.lang.Class.forName0(Native Method)
at java.base/java.lang.Class.forName(Class.java:467)
at org.apache.skywalking.apm.agent.core.plugin.loader.InterceptorInstanceLoader.load(InterceptorInstanceLoader.java:71)
at org.apache.skywalking.apm.agent.core.plugin.interceptor.enhance.InstMethodsInter.<init>(InstMethodsInter.java:52)
... 49 more
Caused by: java.lang.ClassNotFoundException: Can't find javax.servlet.http.HttpServletRequest
at org.apache.skywalking.apm.agent.core.plugin.loader.AgentClassLoader.findClass(AgentClassLoader.java:117)
at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:587)
at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:520)
... 53 more
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@skywalking.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org