调用方法老出错!!

07-10-24 JdonStudy
banq 老师:

TestService userService = (TestService) WebAppUtil.getService("testService",request);

就单独运行这个不调用userService 方法日志结果如下:

2007-10-24 16:21:52,714 [http-8080-Processor24] DEBUG com.jdon.controller.service.WebServiceFactory - <==============================>start: JdonFramework core entrance

2007-10-24 16:21:52,714 [http-8080-Processor24] DEBUG com.jdon.controller.service.WebServiceFactory - <===============>Looking up new service='testService'

2007-10-24 16:21:52,714 [http-8080-Processor24] DEBUG com.jdon.bussinessproxy.config.TargetMetaDefXmlLoader - [JdonFramework]metaDefs size:2

2007-10-24 16:21:52,714 [http-8080-Processor24] DEBUG com.jdon.controller.service.WebServiceFactory - [JdonFramework] service=testService found, and now return the service instance

2007-10-24 16:21:52,724 [http-8080-Processor24] DEBUG com.jdon.security.web.HttpRequestUserSetup - [JdonFramework] setArrtibute:REMOTE_ADDRESS=127.0.0.1

2007-10-24 16:21:52,724 [http-8080-Processor24] DEBUG com.jdon.container.access.ServiceAccessorImp - [JdonFramework] enter getService: proxyInstanceFactoryVisitable in action

2007-10-24 16:21:52,724 [http-8080-Processor24] DEBUG com.jdon.container.visitor.HttpSessionProxyVisitor - [JdonFramework] get the optimized instance for the key com.jdon.framework.test.service.TestServicePOJOImpproxyInstanceFactoryVisitable

2007-10-24 16:21:52,724 [http-8080-Processor24] DEBUG com.jdon.controller.service.WebServiceFactory - <===============>found service='testService' instance and return it successfully!

2007-10-24 16:21:52,724 [http-8080-Processor24] DEBUG com.jdon.controller.service.WebServiceFactory - <==============================>over

JdonStudy
2007-10-24 16:48
当调用userService 内方法时:

2007-10-24 16:21:52,754 [http-8080-Processor24] ERROR org.apache.catalina.core.ContainerBase.[Catalina].[localhost].[/JdonTest].[jsp] - Servlet.service() for servlet jsp threw exception

java.lang.reflect.UndeclaredThrowableException

at $Proxy0.toString(Unknown Source)

at com.jdon.framework.test.web.UserListAction.doPost(UserListAction.java:65)

at com.jdon.framework.test.web.UserListAction.doGet(UserListAction.java:40)

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.ApplicationDispatcher.invoke(ApplicationDispatcher.java:672)

at org.apache.catalina.core.ApplicationDispatcher.processRequest(ApplicationDispatcher.java:463)

at org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationDispatcher.java:398)

at org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDispatcher.java:301)

at org.apache.jasper.runtime.PageContextImpl.doForward(PageContextImpl.java:688)

at org.apache.jasper.runtime.PageContextImpl.forward(PageContextImpl.java:658)

at org.apache.jsp.index_jsp._jspService(index_jsp.java:43)

at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:97)

at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)

at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:334)

at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:314)

at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:264)

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 com.jdon.util.SetCharacterEncodingFilter.doFilter(SetCharacterEncodingFilter.java:92)

at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)

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)

Caused by: java.lang.Throwable: java.lang.Throwable: java.lang.NoClassDefFoundError: org/apache/commons/collections/CursorableLinkedList

at com.jdon.bussinessproxy.dyncproxy.DynamicProxyWeaving.invoke(DynamicProxyWeaving.java:68)

... 37 more

Caused by: java.lang.Throwable: java.lang.NoClassDefFoundError: org/apache/commons/collections/CursorableLinkedList

at com.jdon.aop.AopClient.invoke(AopClient.java:100)

at ......

banq
2007-10-25 11:45
如果出错,找出出错原因,你的日志中显示:

Caused by: java.lang.Throwable: java.lang.Throwable: java.lang.NoClassDefFoundError: org/apache/commons/collections/CursorableLinkedList

NoClassDefFoundError中文意思是没有发现类org/apache/commons/collections/CursorableLinkedList

你google搜索一下这个类在哪个包,下载这个jar包放入你的运行环境。

这是struts的commons-collections.jar包

[该贴被banq于2007-10-27 17:53修改过]

猜你喜欢