2012-07-18 90 views
0

我遇到了問題(「GWT模塊'SmartWPS'可能需要(重新編譯)」)網址。我通過運行maven-clean-install生成了war文件。我在/ webapp文件夾中放置了相同的war文件。「GWT模塊在部署到Tomcat中時可能需要(重新編譯)」,並且使用maven生成戰爭

我開發了使用GWT作爲依賴注入和服務器端作爲Spring依賴注入的客戶端GIN的應用程序。當我運行maven-clean-install時,war文件正在成功生成。將戰爭的文件,然後我看到在Tomcat logs文件夾下面的錯誤/ webapp的文件夾,

2012年7月18日下午8時43分02秒org.apache.catalina.core.ApplicationContext 後登錄重度:StandardWrapper.Throwable org.springframework.beans.factory.BeanCreationException:在ServletContext的 資源[/WEB-INF/spring/spring-servlet.xml]錯誤 創建名稱爲豆 'urlMapping中' 定義爲:豆 的初始化失敗;嵌套的例外是 org.springframework.beans.factory.BeanCreationException:錯誤 創建名稱爲豆 'empDetailsController' 在 ServletContext的資源定義[/WEB-INF/spring/spring-servlet.xml]:無法創建 內部bean 「 com.infor.ion.boddesk.ui.sample.server.EmployeeDetailsS​​erviceImpl#ca56214' 類型 [com.infor.ion.boddesk.ui.sample.server.EmployeeDetailsS​​erviceImpl] while設置bean屬性'remoteService';嵌套的例外是 org.springframework.beans.factory.BeanCreationException:錯誤 創建與ServletContext的資源 定義的名稱 'com.infor.ion.boddesk.ui.sample.server.EmployeeDetailsS​​erviceImpl#ca56214' 豆[/ WEB- INF/spring/spring-servlet.xml]:bean的實例化失敗; 嵌套的異常是 org.springframework.beans.BeanInstantiationException:無法 實例化bean類 [com.infor.ion.boddesk.ui.sample.server.EmployeeDetailsS​​erviceImpl]: 構造拋出異常;嵌套的異常是 com.sun.jersey.api.client.ClientHandlerException: java.net.ConnectException:連接超時:連接在 org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:527) 在 org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:456) 在 org.springframework.beans.factory.support.AbstractBeanFactory $ 1.getObject(AbstractBeanFactory.java:291) 在 org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:222) at org.spr ingframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:288) 在 org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:190) 在 org.springframework.beans。 factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:580) 在 org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:895) 在 org.springframework.context.support.AbstractApplicationContext.refresh( AbstractApplicationContext.java:425) at org.springframework.web.servlet。FrameworkServlet.createWebApplicationContext(FrameworkServlet.java:442) 在 org.springframework.web.servlet.FrameworkServlet.createWebApplicationContext(FrameworkServlet.java:458) 在 org.springframework.web.servlet.FrameworkServlet.initWebApplicationContext(FrameworkServlet.java: 339) 在 org.springframework.web.servlet.FrameworkServlet.initServletBean(FrameworkServlet.java:306) 在 org.springframework.web.servlet.HttpServletBean.init(HttpServletBean.java:127)

我的spring-servlet.xml文件就像下面粘貼的那樣,

http://www.springframework.org/schema/beans/spring-beans-2.5.xsd「>

<!-- The application context definition for the DispatcherServlet --> 

<!-- Maps the request through to a concrete controller instance --> 
<bean id="urlMapping" class="org.springframework.web.servlet.handler.SimpleUrlHandlerMapping"> 
    <property name="mappings"> 
     <value> 
     <!-- /**/SampleApp.rpc=sampleAppController --> 
     /**/empDetails.rpc=empDetailsController 
     </value> 
    </property> 
</bean> 

<!-- GwtRpcController wraps our service in order to decode the incoming --> 
<!-- request then delegates processing of the call to the POJO service --> 
<!-- and then encodes the return value forwarding the response. --> <!--<bean id="sampleAppController" class="com.infor.ion.boddesk.server.GwtRpcController"> 
    <property name="remoteService"> 
     <bean class="com.infor.ion.boddesk.server.sampleapp.SampleAppService" /> 
    </property> 
</bean> -->  <bean id="empDetailsController" class="com.infor.ion.boddesk.ui.sample.server.GwtRpcController"> 
    <property name="remoteService"> 
     <bean class="com.infor.ion.boddesk.ui.sample.server.EmployeeDetailsServiceImpl" 

/>

當與使maven iam面臨着所有這些問題,使用build.xml,它只是成功,甚至在jetty服務器內運行成功。

感謝, 薩里薩

+0

[GWT模塊可能需要重新編譯REDUX](http://stackoverflow.com/questions/5719118/gwt-module-may-need-to-be-recompiled-redux) – 2012-07-18 18:44:31

回答

0

清理臨時文件(運行>%TEMP%) 清理項目(在你的IDE) 清理瀏覽器的緩存。(使用的CCleaner) 再次編譯該項目。