java.lang.NoSuchMethodError

There are no available Samebug tips for this exception. Do you have an idea how to solve this issue? A short tip would help users who saw this issue last week.

  • In the latest Jason-lib-1.0 the constructor private JSONObject( String string) was substituted by the constructor private JSONObject( String string, String[] excludes, boolean ignoreDefaultExcludes ) This constructor is called in the "initEvent" method o f AjaxInterceptor class, so when a jason parameter was passed, the AjaxInterceptor return this error java.lang.NoSuchMethodError: net.sf.json.JSONObject.<init>(Ljava/lang/String;)V at org.springmodules.xt.ajax.AjaxInterceptor.initEvent(AjaxInterceptor.java:395) at org.springmodules.xt.ajax.AjaxInterceptor.preHandle(AjaxInterceptor.java:126) at org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:810) at org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:755) at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:396) at org.springframework.web.servlet.FrameworkServlet.doGet(FrameworkServlet.java:350) at javax.servlet.http.HttpServlet.service(HttpServlet.java:689) at javax.servlet.http.HttpServlet.service(HttpServlet.java:802) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107) at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148) at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:869) at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:664) at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527) at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80) at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684) at java.lang.Thread.run(Thread.java:595) The old 0.9 version of jeson-lib work fine (so, it can be used while this bug isn't fixed)
    via by Rinaldo Cavalieri,
  • In the latest Jason-lib-1.0 the constructor private JSONObject( String string) was substituted by the constructor private JSONObject( String string, String[] excludes, boolean ignoreDefaultExcludes ) This constructor is called in the "initEvent" method o f AjaxInterceptor class, so when a jason parameter was passed, the AjaxInterceptor return this error java.lang.NoSuchMethodError: net.sf.json.JSONObject.<init>(Ljava/lang/String;)V at org.springmodules.xt.ajax.AjaxInterceptor.initEvent(AjaxInterceptor.java:395) at org.springmodules.xt.ajax.AjaxInterceptor.preHandle(AjaxInterceptor.java:126) at org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:810) at org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:755) at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:396) at org.springframework.web.servlet.FrameworkServlet.doGet(FrameworkServlet.java:350) at javax.servlet.http.HttpServlet.service(HttpServlet.java:689) at javax.servlet.http.HttpServlet.service(HttpServlet.java:802) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107) at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148) at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:869) at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:664) at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527) at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80) at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684) at java.lang.Thread.run(Thread.java:595) The old 0.9 version of jeson-lib work fine (so, it can be used while this bug isn't fixed)
    via by Rinaldo Cavalieri,
  • From 2.0 version of json lib the static method public JSONObject getJSONObject(String key) used in private void initEvent(AjaxEvent event, HttpServletRequest request) on the class org.springmodules.xt.ajax.AjaxInterceptor was deprecated and removed in the next version..so, it's impossible to use the latest json-lib version (2.2) with Spring Modules Xt that return java.lang.NoSuchMethodError: net.sf.json.JSONObject.fromString(Ljava/lang/String;)Lnet/sf/json/JSONObject; at org.springmodules.xt.ajax.AjaxInterceptor.initEvent(AjaxInterceptor.java:432) at org.springmodules.xt.ajax.AjaxInterceptor.preHandle(AjaxInterceptor.java:139) at org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:865) at org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:809) at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:571) at org.springframework.web.servlet.FrameworkServlet.doGet(FrameworkServlet.java:501) at javax.servlet.http.HttpServlet.service(HttpServlet.java:690) at javax.servlet.http.HttpServlet.service(HttpServlet.java:803) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:175) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109) at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:286) at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:844) at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:583) at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447) at java.lang.Thread.run(Thread.java:619)
    via by Rinaldo Cavalieri,
  • From 2.0 version of json lib the static method public JSONObject getJSONObject(String key) used in private void initEvent(AjaxEvent event, HttpServletRequest request) on the class org.springmodules.xt.ajax.AjaxInterceptor was deprecated and removed in the next version..so, it's impossible to use the latest json-lib version (2.2) with Spring Modules Xt that return java.lang.NoSuchMethodError: net.sf.json.JSONObject.fromString(Ljava/lang/String;)Lnet/sf/json/JSONObject; at org.springmodules.xt.ajax.AjaxInterceptor.initEvent(AjaxInterceptor.java:432) at org.springmodules.xt.ajax.AjaxInterceptor.preHandle(AjaxInterceptor.java:139) at org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:865) at org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:809) at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:571) at org.springframework.web.servlet.FrameworkServlet.doGet(FrameworkServlet.java:501) at javax.servlet.http.HttpServlet.service(HttpServlet.java:690) at javax.servlet.http.HttpServlet.service(HttpServlet.java:803) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:175) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109) at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:286) at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:844) at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:583) at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447) at java.lang.Thread.run(Thread.java:619)
    via by Rinaldo Cavalieri,
    • java.lang.NoSuchMethodError: net.sf.json.JSONObject.<init>(Ljava/lang/String;)V at org.springmodules.xt.ajax.AjaxInterceptor.initEvent(AjaxInterceptor.java:395) at org.springmodules.xt.ajax.AjaxInterceptor.preHandle(AjaxInterceptor.java:126) at org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:810) at org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:755) at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:396) at org.springframework.web.servlet.FrameworkServlet.doGet(FrameworkServlet.java:350) at javax.servlet.http.HttpServlet.service(HttpServlet.java:689) at javax.servlet.http.HttpServlet.service(HttpServlet.java:802) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107) at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148) at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:869) at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:664) at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527) at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80) at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684) at java.lang.Thread.run(Thread.java:595)
    No Bugmate found.