I'm having this same problem on Tomcat 6. Here's the stack trace:
javax.servlet.ServletException:
org/apache/struts2/util/ObjectFactoryDestroyable
at
org.apache.catalina.security.SecurityUtil.execute(SecurityUtil.java:294)
at
org.apache.catalina.security.SecurityUtil.doAsPrivilege(SecurityUtil.jav
a:218)
at
org.apache.catalina.security.SecurityUtil.doAsPrivilege(SecurityUtil.jav
a:178)
at
org.apache.catalina.core.ApplicationFilterConfig.release(ApplicationFilt
erConfig.java:326)
at
org.apache.catalina.core.StandardContext.filterStop(StandardContext.java
:3744)
at
org.apache.catalina.core.StandardContext.stop(StandardContext.java:4513)
at
org.apache.catalina.core.ContainerBase.removeChild(ContainerBase.java:92
4)
at
org.apache.catalina.startup.HostConfig.checkResources(HostConfig.java:10
46)
at
org.apache.catalina.startup.HostConfig.check(HostConfig.java:1214)
at
org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:29
3)
at
org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSu
pport.java:117)
at
org.apache.catalina.core.ContainerBase.backgroundProcess(ContainerBase.j
ava:1337)
at
org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.proc
essChildren(ContainerBase.java:1601)
at
org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.proc
essChildren(ContainerBase.java:1610)
at
org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.run(
ContainerBase.java:1590)
at java.lang.Thread.run(Thread.java:619)
Caused by: java.lang.NoClassDefFoundError:
org/apache/struts2/util/ObjectFactoryDestroyable
at
org.apache.struts2.dispatcher.Dispatcher.cleanup(Dispatcher.java:254)
at
org.apache.struts2.dispatcher.FilterDispatcher.destroy(FilterDispatcher.
java:233)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.jav
a:39)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessor
Impl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at
org.apache.catalina.security.SecurityUtil$1.run(SecurityUtil.java:244)
at java.security.AccessController.doPrivileged(Native Method)
at javax.security.auth.Subject.doAsPrivileged(Subject.java:517)
at
org.apache.catalina.security.SecurityUtil.execute(SecurityUtil.java:276)
... 15 more
Caused by: java.lang.ClassNotFoundException:
org.apache.struts2.util.ObjectFactoryDestroyable
at
org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader
.java:1387)
at
org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader
.java:1233)
at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:320)
... 25 more
I checked the exploded WAR, and it includes
WEB-INF/lib/struts2-core-2.1.6.jar
Any ideas? This is immediately after I deploy the WAR, using the Web
Application Manager (or by manually copying the WAR into the webapps/
directory).
> -----Original Message-----
> From: Daniele Del Gaudio [mailto:[email protected]]
> Sent: Wednesday, May 20, 2009 9:01 AM
> To: [email protected]
> Subject: struts2 on jboss java.lang.NoClassDefFoundError:
> org/apache/struts2/util/ObjectFactoryDestroyable
>
> Hello, can someone help me?
>
> When I undeploy or redeploy my web application based on
> struts2 on jboss
> 4.2.2 I have this error:
>
> 13:35:57,788 INFO [TomcatDeployer] undeploy,
> ctxPath=/PianificazioneWeb, warUrl=.../deploy/PianificazioneWeb.war/
> 13:35:57,788 ERROR [BaseModelMBean] Exception invoking method destroy
> java.lang.NoClassDefFoundError:
> org/apache/struts2/util/ObjectFactoryDestroyable
> at
> org.apache.struts2.dispatcher.Dispatcher.cleanup(Dispatcher.java:257)
> at
> org.apache.struts2.dispatcher.FilterDispatcher.destroy(FilterD
> ispatcher.java:221)
> at
> org.apache.catalina.core.ApplicationFilterConfig.release(Appli
> cationFilterConfig.java:332)
> at
> org.apache.catalina.core.StandardContext.filterStop(StandardCo
> ntext.java:3757)
> at
> org.apache.catalina.core.StandardContext.stop(StandardContext.
> java:4517)
> at
> org.apache.catalina.core.ContainerBase.destroy(ContainerBase.j
> ava:1163)
> at
> org.apache.catalina.core.StandardContext.destroy(StandardConte
> xt.java:4617)
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
> at
> sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
> at java.lang.reflect.Method.invoke(Unknown Source)
> at ...
>
>
> My web.xml is
>
> <?xml version="1.0" encoding="UTF-8"?>
>
> <web-app version="2.4" xmlns="http://java.sun.com/xml/ns/j2ee"
> xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
> xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee
> http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd">
> <display-name>PianificazioneWeb</display-name>
> <context-param>
> <param-name>tilesDefinitions</param-name>
> <param-value>/WEB-INF/tiles.xml</param-value>
> </context-param>
>
> <filter>
> <filter-name>struts2</filter-name>
>
> <filter-class>org.apache.struts2.dispatcher.FilterDispatcher</
> filter-class>
> </filter>
>
>
> <filter-mapping>
> <filter-name>struts2</filter-name>
> <url-pattern>/*</url-pattern>
> </filter-mapping>
>
>
> <listener>
>
> <listener-class>org.apache.struts2.tiles.StrutsTilesListener</
> listener-class>
> </listener>
>
> <welcome-file-list>
> <welcome-file>index.jsp</welcome-file>
> </welcome-file-list>
>
> <ejb-local-ref>
>
> <ejb-ref-name>serv/ServPianificazioneContrattiBeanLocal</ejb-ref-name>
> <ejb-ref-type>Session</ejb-ref-type>
> <local-home></local-home>
>
> <local>pianificazioneEjb.services.ServPianificazioneContratti</local>
> </ejb-local-ref>
> <ejb-local-ref>
>
> <ejb-ref-name>serv/ServPianificazioneOpportunitaBeanLocal</ejb
> -ref-name>
> <ejb-ref-type>Session</ejb-ref-type>
> <local-home></local-home>
>
> <local>pianificazioneEjb.services.ServPianificazioneOpportunit
> a</local>
> </ejb-local-ref>
> <ejb-local-ref>
>
> <ejb-ref-name>serv/ServPianificazioneProgettiBeanLocal</ejb-ref-name>
> <ejb-ref-type>Session</ejb-ref-type>
> <local-home></local-home>
>
> <local>pianificazioneEjb.services.ServPianificazioneProgetti</local>
> </ejb-local-ref>
> </web-app>
>
> My jboss-web.xml is
>
> <?xml version="1.0" encoding="UTF-8"?>
> <!--
> * Copyright 2008, Javid Jamae and Peter Johnson
> *
> * Licensed under the Apache License, Version 2.0 (the
> "License"); you
> may not
> * use this file except in compliance with the License. You
> may obtain
> a copy
> * of the License at
> *
> * http://www.apache.org/licenses/LICENSE-2.0
> *
> * Unless required by applicable law or agreed to in
> writing, software
> * distributed under the License is distributed on an "AS
> IS" BASIS,
> WITHOUT
> * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
> See the
> * License for the specific language governing permissions
> and limitations
> * under the License.
> -->
> <jboss-web>
> <loader-repository>
> pianificazioneWeb:loader=LoaderPianificazioneWeb
> <loader-repository-config>
> java2ParentDelegation=false
> </loader-repository-config>
> </loader-repository>
> <ejb-local-ref>
>
> <ejb-ref-name>serv/ServPianificazioneContrattiBeanLocal</ejb-ref-name>
>
> <local-jndi-name>Accoglienza/ServPianificazioneContrattiBean/l
> ocal</local-jndi-name>
> </ejb-local-ref>
> <ejb-local-ref>
>
> <ejb-ref-name>serv/ServPianificazioneOpportunitaBeanLocal</ejb
> -ref-name>
>
> <local-jndi-name>Accoglienza/ServPianificazioneOpportunitaBean
> /local</local-jndi-name>
> </ejb-local-ref>
> <ejb-local-ref>
>
> <ejb-ref-name>serv/ServPianificazioneProgettiBeanLocal</ejb-ref-name>
>
> <local-jndi-name>Accoglienza/ServPianificazioneProgettiBean/lo
> cal</local-jndi-name>
> </ejb-local-ref>
> </jboss-web>
>
> and my struts.xml is
>
> <?xml version="1.0" encoding="UTF-8" ?>
> <!DOCTYPE struts PUBLIC
> "-//Apache Software Foundation//DTD Struts Configuration 2.0//EN"
> "http://struts.apache.org/dtds/struts-2.0.dtd">
>
> <struts>
>
> <constant name="struts.enable.DynamicMethodInvocation"
> value="true" />
> <!-- etichette e messaggi dell'intera applicazione sono in
> MessageResources.properties -->
> <constant name="struts.custom.i18n.resources"
> value="MessageResources" />
> <constant name="struts.ui.theme" value="css_xhtml" />
> <!-- devMode, i18n.reload,nocache a true solo in ambiente di
> sviluppo -->
> <constant name="struts.devMode" value="true" />
> <constant name="struts.i18n.reload" value="true" />
> <constant name="struts.xslt.nocache" value="true" />
> <constant name="struts.configuration.xml.reload" value="true" />
>
>
>
>
> <!-- <include file="struts-default.xml"/> -->
>
> <package name="action" extends="tiles-default">
>
> <!-- le righe sotto sovrascrivono la def di result-type
> scritta uguale nel file struts-plugin.xml
> in struts2-tiles-plugin-2.0.9.jar ma senza il
> default="true" -->
>
>
> <global-results>
> <result name="error">/chapterEight/Error.jsp</result>
> </global-results>
>
> <global-exception-mappings>
> <exception-mapping exception="java.lang.Exception"
> result="error"/>
> </global-exception-mappings>
>
> <action name="PianificazioneContratto"
> class="pianificazioneWeb.action.PianificazioneContratto">
> <interceptor-ref name="defaultStack">
> <param
> name="params.excludeParams">idOpportunita,idProgetto</param>
> </interceptor-ref>
> <result type="tiles" name="input"
> >tiles.PianificazioneContratto</result>
> <result type="tiles" name="error"
> >tiles.PianificazioneContratto</result>
> <result type="tiles" name="success"
> >tiles.PianificazioneContratto</result>
> <!-- <interceptor-ref name="basicStack"/> -->
> </action>
>
> <action name="DatiContratto"
> class="pianificazioneWeb.action.DatiContratto">
> <result type="tiles" >tiles.Contratto</result>
> <!-- <interceptor-ref name="basicStack"/> -->
> </action>
>
> <action name="Opportunita"
> class="pianificazioneWeb.action.DatiOpportunita">
> <result type="tiles" >tiles.Opportunita</result>
> <!-- <interceptor-ref name="basicStack"/> -->
> </action>
>
> <action name="Progetto"
> class="pianificazioneWeb.action.DatiProgetto">
> <interceptor-ref name="defaultStack">
> <param
> name="params.excludeParams">idOpportunita,idProgetto</param>
> </interceptor-ref>
> <result type="tiles" >tiles.Progetto</result>
> <!-- <interceptor-ref name="basicStack"/> -->
> </action>
>
> <action name="InsPianificContratto"
> class="pianificazioneWeb.action.InsPianificContratto">
> <result type="tiles" >tiles.InsPianificContratto</result>
> </action>
>
> <action name="SalvaInsPianificContratto"
> class="pianificazioneWeb.action.InsPianificContratto">
> <result type="redirect"
> >/action/PianificazioneContratto.action</result>
> </action>
>
> <action name="InsPianificPM"
> class="pianificazioneWeb.action.InsPianificPM">
> <result type="tiles" >tiles.InsPianificPM</result>
> </action>
>
> </package>
> </struts>
>
>
> Thanks,
> daniele
>
>
> __________ Information from ESET NOD32 Antivirus, version of
> virus signature database 4090 (20090520) __________
>
> The message was checked by ESET NOD32 Antivirus.
>
> http://www.eset.com
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [email protected]
> For additional commands, e-mail: [email protected]
>
>
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]