8

我将 Gxt2.2.3 和 Gwt2.2.0 与 maven 一起使用,当我尝试通过 jetty 服务器以托管模式运行应用程序时,我得到以下错误跟踪如下。


org.springframework.beans.factory.BeanDefinitionStoreException: Unexpected exception     parsing XML document from class path resource [spring/spring-security.xml];     nested exception is java.lang.NoSuchMethodError:     org.springframework.beans.factory.xml.BeanDefinitionParserDelegate.getLocalName(Lorg/w3c/dom/Node;)Ljava/lang/String;
            [INFO]  at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.doLoadBeanDefinitions(XmlBeanDefinitionReader.java:420)
            [ERROR] log4j:ERROR Error occured while sending e-mail notification.
            [ERROR] javax.mail.NoSuchProviderException: smtp
            [ERROR]     at javax.mail.Session.getService(Session.java:794)
            [ERROR]     at javax.mail.Session.getTransport(Session.java:716)
            [ERROR]     at javax.mail.Session.getTransport(Session.java:656)
            [ERROR]     at javax.mail.Session.getTransport(Session.java:636)
            [ERROR]     at javax.mail.Session.getTransport(Session.java:693)
            [ERROR]     at javax.mail.Transport.send0(Transport.java:188)
            [ERROR]     at javax.mail.Transport.send(Transport.java:120)
            [ERROR]     at org.apache.log4j.net.SMTPAppender.sendBuffer(Unknown Source)
            [ERROR]     at org.apache.log4j.net.SMTPAppender.append(Unknown Source)
            [ERROR]     at org.apache.log4j.AppenderSkeleton.doAppend(AppenderSkeleton.java:230)
            [ERROR]     at org.apache.log4j.helpers.AppenderAttachableImpl.appendLoopOnAppenders(AppenderAttachableImpl.java:65)
            [ERROR]     at org.apache.log4j.Category.callAppenders(Category.java:203)
            [ERROR]     at org.apache.log4j.Category.forcedLog(Category.java:388)
            [ERROR]     at org.apache.log4j.Category.log(Category.java:853)
            [ERROR]     at org.apache.commons.logging.impl.Log4JLogger.error(Log4JLogger.java:257)
            [ERROR]     at org.springframework.web.context.ContextLoader.initWebApplicationContext(ContextLoader.java:215)
            [INFO]  at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.loadBeanDefinitions(XmlBeanDefinitionReader.java:342)
            [INFO]  at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.loadBeanDefinitions(XmlBeanDefinitionReader.java:310)
            [INFO] [ERROR]  at org.springframework.web.context.ContextLoaderListener.contextInitialized(ContextLoaderListener.java:45)
                at org.springframework.beans.factory.support.AbstractBeanDefinitionReader.loadBeanDefinitions(AbstractBeanDefinitionReader.java:143)
            [ERROR] [INFO]  at org.springframework.beans.factory.support.AbstractBeanDefinitionReader.loadBeanDefinitions(AbstractBeanDefinitionReader.java:178)
                at org.mortbay.jetty.handler.ContextHandler.startContext(ContextHandler.java:543)
            [INFO]  at org.springframework.beans.factory.support.AbstractBeanDefinitionReader.loadBeanDefinitions(AbstractBeanDefinitionReader.java:149)
            [INFO]  at org.springframework.web.context.support.XmlWebApplicationContext.loadBeanDefinitions(XmlWebApplicationContext.java:124)
            [ERROR]     at org.mortbay.jetty.servlet.Context.startContext(Context.java:136)
            [INFO]  at org.springframework.web.context.support.XmlWebApplicationContext.loadBeanDefinitions(XmlWebApplicationContext.java:92)
            [ERROR]     at org.mortbay.jetty.webapp.WebAppContext.startContext(WebAppContext.java:1220)
            [INFO]  at org.springframework.context.support.AbstractRefreshableApplicationContext.refreshBeanFactory(AbstractRefreshableApplicationContext.java:123)
            [INFO]  at org.springframework.context.support.AbstractApplicationContext.obtainFreshBeanFactory(AbstractApplicationContext.java:422)
            [INFO]  at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:352)
            [INFO]  at org.springframework.web.context.ContextLoader.createWebApplicationContext(ContextLoader.java:255)
            [INFO]  at org.springframework.web.context.ContextLoader.initWebApplicationContext(ContextLoader.java:199)
            [INFO]  at org.springframework.web.context.ContextLoaderListener.contextInitialized(ContextLoaderListener.java:45)
            [INFO]  at org.mortbay.jetty.handler.ContextHandler.startContext(ContextHandler.java:543)
            [INFO]  at org.mortbay.jetty.servlet.Context.startContext(Context.java:136)
            [INFO]  at org.mortbay.jetty.webapp.WebAppContext.startContext(WebAppContext.java:1220)
            [INFO]  at org.mortbay.jetty.handler.ContextHandler.doStart(ContextHandler.java:513)
            [INFO]  at org.mortbay.jetty.webapp.WebAppContext.doStart(WebAppContext.java:448)
            [INFO]  at com.google.gwt.dev.shell.jetty.JettyLauncher$WebAppContextWithReload.doStart(JettyLauncher.java:461)
            [INFO]  at org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:39)
            [INFO]  at org.mortbay.jetty.handler.HandlerWrapper.doStart(HandlerWrapper.java:130)
            [INFO]  at org.mortbay.jetty.handler.RequestLogHandler.doStart(RequestLogHandler.java:115)
            [INFO]  at org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:39)
            [INFO]  at org.mortbay.jetty.handler.HandlerWrapper.doStart(HandlerWrapper.java:130)
            [INFO]  at org.mortbay.jetty.Server.doStart(Server.java:222)
            [INFO]  at org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:39)
            [INFO]  at com.google.gwt.dev.shell.jetty.JettyLauncher.start(JettyLauncher.java:565)
            [INFO]  at com.google.gwt.dev.DevMode.doStartUpServer(DevMode.java:494)
            [INFO]  at com.google.gwt.dev.DevModeBase.startUp(DevModeBase.java:1058)
            [INFO]  at com.google.gwt.dev.DevModeBase.run(DevModeBase.java:800)
            [INFO]  at com.google.gwt.dev.DevMode.main(DevMode.java:304)
            [INFO] Caused by: java.lang.NoSuchMethodError: org.springframework.beans.factory.xml.BeanDefinitionParserDelegate.getLocalName(Lorg/w3c/dom/Node;)Ljava/lang/String;
            [INFO]  at org.springframework.security.config.SecurityNamespaceHandler.parse(SecurityNamespaceHandler.java:45)
            [INFO]  at org.springframework.beans.factory.xml.BeanDefinitionParserDelegate.parseCustomElement(BeanDefinitionParserDelegate.java:1297)
            [INFO]  at org.springframework.beans.factory.xml.BeanDefinitionParserDelegate.parseCustomElement(BeanDefinitionParserDelegate.java:1287)
            [ERROR] [INFO]  at org.springframework.beans.factory.xml.DefaultBeanDefinitionDocumentReader.parseBeanDefinitions(DefaultBeanDefinitionDocumentReader.java:135)
                at org.mortbay.jetty.handler.ContextHandler.doStart(ContextHandler.java:513)
            [INFO]  at org.springframework.beans.factory.xml.DefaultBeanDefinitionDocumentReader.registerBeanDefinitions(DefaultBeanDefinitionDocumentReader.java:92)
            [INFO]  at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.registerBeanDefinitions(XmlBeanDefinitionReader.java:507)
            [INFO]  at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.doLoadBeanDefinitions(XmlBeanDefinitionReader.java:398)
            [INFO]  ... 31 more
            [ERROR]     at org.mortbay.jetty.webapp.WebAppContext.doStart(WebAppContext.java:448)
            [ERROR]     at com.google.gwt.dev.shell.jetty.JettyLauncher$WebAppContextWithReload.doStart(JettyLauncher.java:461)
            [ERROR]     at org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:39)
            [ERROR]     at org.mortbay.jetty.handler.HandlerWrapper.doStart(HandlerWrapper.java:130)
            [ERROR]     at org.mortbay.jetty.handler.RequestLogHandler.doStart(RequestLogHandler.java:115)
            [ERROR]     at org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:39)
            [ERROR]     at org.mortbay.jetty.handler.HandlerWrapper.doStart(HandlerWrapper.java:130)
            [ERROR]     at org.mortbay.jetty.Server.doStart(Server.java:222)
            [ERROR]     at org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:39)
            [ERROR]     at com.google.gwt.dev.shell.jetty.JettyLauncher.start(JettyLauncher.java:565)
            [ERROR]     at com.google.gwt.dev.DevMode.doStartUpServer(DevMode.java:494)
            [ERROR]     at com.google.gwt.dev.DevModeBase.startUp(DevModeBase.java:1058)
            [ERROR]     at com.google.gwt.dev.DevModeBase.run(DevModeBase.java:800)
            [ERROR]     at com.google.gwt.dev.DevMode.main(DevMode.java:304)




似乎有一些 jar 冲突,但我无法找到它。

4

1 回答 1

9

问题出在这里,您可能将 spring2.x.jar 用于 spring-security3.x.jar。我们知道 spring-security3.x 需要 spring3.x 及更高版本。它不支持spring2.x。检查项目的类路径,并确保 spring-security3.x 版本没有 spring2.x。当我通过以下链接遇到相同问题时,我找到了解决方案。希望此链接对您有所帮助。

于 2012-08-29T13:59:05.347 回答