ibatis-user-java mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Steve Wooten" <woot...@hughes.net>
Subject NoClassDefFoundError Resources
Date Wed, 09 May 2007 18:52:32 GMT
I am attempting to use ibatis in a Session bean with JBoss.  

I have a helper class that load the ibatis config with the following code

            try {

                  ibatisConfigReader = com.ibatis.common.resources.Resources

                              .getResourceAsReader("SqlMapConfig.xml");

                  ibatisSqlMap = SqlMapClientBuilder

                              .buildSqlMapClient(ibatisConfigReader);

            } catch (Exception ex) {

                  log.fatal("Exception reading ibatis config file", ex);

            }

 

If I run this with my IDE (Eclipse) it works fine. 

I have all the ibatis jar file deploying with my ear so I know the file
"com/ibatis/common/resources/Resources exist."

My application is able to find all other classes deployed in other jar files
however once it is deployed on the server I get the following error:

java.lang.NoClassDefFoundError: com/ibatis/common/resources/Resources

 

Please Help!

 

Stack trace is below

java.lang.NoClassDefFoundError: com/ibatis/common/resources/Resources

      at com.nc4.athena.QueryHelper.init(QueryHelper.java:42)

      at com.nc4.athena.QueryHelper.<init>(QueryHelper.java:58)

      at
com.nc4.athena.dao.PartyRelationTypeDAO.<init>(PartyRelationTypeDAO.java:51)

      at
com.nc4.athena.dao.PartyRelationTypeDAO.getInstance(PartyRelationTypeDAO.jav
a:61)

      at
com.nc4.athena.session.TypeTableManagerEJB.getPartyRelationTypeList(TypeTabl
eManagerEJB.java:892)

      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

      at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39
)

      at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl
.java:25)

      at java.lang.reflect.Method.invoke(Method.java:585)

      at org.jboss.invocation.Invocation.performCall(Invocation.java:359)

      at
org.jboss.ejb.StatelessSessionContainer$ContainerInterceptor.invoke(Stateles
sSessionContainer.java:237)

      at
org.jboss.resource.connectionmanager.CachedConnectionInterceptor.invoke(Cach
edConnectionInterceptor.java:158)

      at
org.jboss.ejb.plugins.StatelessSessionInstanceInterceptor.invoke(StatelessSe
ssionInstanceInterceptor.java:169)

      at
org.jboss.ejb.plugins.CallValidationInterceptor.invoke(CallValidationInterce
ptor.java:63)

      at
org.jboss.ejb.plugins.AbstractTxInterceptor.invokeNext(AbstractTxInterceptor
.java:121)

      at
org.jboss.ejb.plugins.TxInterceptorCMT.runWithTransactions(TxInterceptorCMT.
java:378)

      at
org.jboss.ejb.plugins.TxInterceptorCMT.invoke(TxInterceptorCMT.java:181)

      at
org.jboss.ejb.plugins.SecurityInterceptor.invoke(SecurityInterceptor.java:16
8)

      at
org.jboss.ejb.plugins.LogInterceptor.invoke(LogInterceptor.java:205)

      at
org.jboss.ejb.plugins.ProxyFactoryFinderInterceptor.invoke(ProxyFactoryFinde
rInterceptor.java:136)

      at
org.jboss.ejb.SessionContainer.internalInvoke(SessionContainer.java:648)

      at org.jboss.ejb.Container.invoke(Container.java:954)

      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

      at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39
)

      at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl
.java:25)

      at java.lang.reflect.Method.invoke(Method.java:585)

      at
org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java
:155)

      at org.jboss.mx.server.Invocation.dispatch(Invocation.java:94)

      at org.jboss.mx.server.Invocation.invoke(Invocation.java:86)

      at
org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:26
4)

      at
org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:659)

      at
org.jboss.invocation.local.LocalInvoker$MBeanServerAction.invoke(LocalInvoke
r.java:169)

      at
org.jboss.invocation.local.LocalInvoker.invoke(LocalInvoker.java:118)

      at
org.jboss.invocation.InvokerInterceptor.invokeLocal(InvokerInterceptor.java:
209)

      at
org.jboss.invocation.InvokerInterceptor.invoke(InvokerInterceptor.java:195)

      at
org.jboss.proxy.TransactionInterceptor.invoke(TransactionInterceptor.java:61
)

      at
org.jboss.proxy.SecurityInterceptor.invoke(SecurityInterceptor.java:70)

      at
org.jboss.proxy.ejb.StatelessSessionInterceptor.invoke(StatelessSessionInter
ceptor.java:112)

      at org.jboss.proxy.ClientContainer.invoke(ClientContainer.java:100)

      at $Proxy148.getPartyRelationTypeList(Unknown Source)

      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

      at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39
)

      at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl
.java:25)

      at java.lang.reflect.Method.invoke(Method.java:585)

      at
com.nc4.athena.session.TypeTableManagerDynamicBusinessDelegate.invoke(TypeTa
bleManagerDynamicBusinessDelegate.java:77)

      at $Proxy155.getPartyRelationTypeList(Unknown Source)

      at
com.nc4.athena.action.PartyRelationTypeAction.list(PartyRelationTypeAction.j
ava:48)

      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

      at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39
)

      at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl
.java:25)

      at java.lang.reflect.Method.invoke(Method.java:585)

      at
com.opensymphony.xwork2.DefaultActionInvocation.invokeAction(DefaultActionIn
vocation.java:399)

      at
com.opensymphony.xwork2.DefaultActionInvocation.invokeActionOnly(DefaultActi
onInvocation.java:262)

      at
com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocati
on.java:224)

      at
com.opensymphony.xwork2.interceptor.ConversionErrorInterceptor.intercept(Con
versionErrorInterceptor.java:123)

      at
com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionI
nvocation.java:219)

      at
com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionI
nvocation.java:218)

      at
com.opensymphony.xwork2.util.profiling.UtilTimerStack.profile(UtilTimerStack
.java:455)

      at
com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocati
on.java:216)

      at
com.opensymphony.xwork2.interceptor.ParametersInterceptor.intercept(Paramete
rsInterceptor.java:161)

      at
com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionI
nvocation.java:219)

      at
com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionI
nvocation.java:218)

      at
com.opensymphony.xwork2.util.profiling.UtilTimerStack.profile(UtilTimerStack
.java:455)

      at
com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocati
on.java:216)

      at
org.apache.struts2.interceptor.CheckboxInterceptor.intercept(CheckboxInterce
ptor.java:83)

      at
com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionI
nvocation.java:219)

      at
com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionI
nvocation.java:218)

      at
com.opensymphony.xwork2.util.profiling.UtilTimerStack.profile(UtilTimerStack
.java:455)

      at
com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocati
on.java:216)

      at
com.opensymphony.xwork2.interceptor.PrepareInterceptor.intercept(PrepareInte
rceptor.java:115)

      at
com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionI
nvocation.java:219)

      at
com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionI
nvocation.java:218)

      at
com.opensymphony.xwork2.util.profiling.UtilTimerStack.profile(UtilTimerStack
.java:455)

      at
com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocati
on.java:216)

      at
org.apache.struts2.interceptor.ServletConfigInterceptor.intercept(ServletCon
figInterceptor.java:170)

      at
com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionI
nvocation.java:219)

      at
com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionI
nvocation.java:218)

      at
com.opensymphony.xwork2.util.profiling.UtilTimerStack.profile(UtilTimerStack
.java:455)

      at
com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocati
on.java:216)

      at
com.opensymphony.xwork2.interceptor.ExceptionMappingInterceptor.intercept(Ex
ceptionMappingInterceptor.java:176)

      at
com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionI
nvocation.java:219)

      at
com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActionI
nvocation.java:218)

      at
com.opensymphony.xwork2.util.profiling.UtilTimerStack.profile(UtilTimerStack
.java:455)

      at
com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocati
on.java:216)

      at
org.apache.struts2.impl.StrutsActionProxy.execute(StrutsActionProxy.java:50)

      at
org.apache.struts2.dispatcher.Dispatcher.serviceAction(Dispatcher.java:507)

      at
org.apache.struts2.dispatcher.FilterDispatcher.doFilter(FilterDispatcher.jav
a:421)

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

      at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterCh
ain.java:173)

      at
org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.ja
va:96)

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

      at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterCh
ain.java:173)

      at
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.ja
va:213)

      at
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.ja
va:178)

      at
org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssoci
ationValve.java:175)

      at
org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:
74)

      at
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126
)

      at
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105
)

      at
org.jboss.web.tomcat.tc5.jca.CachedConnectionValve.invoke(CachedConnectionVa
lve.java:156)

      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.processC
onnection(Http11BaseProtocol.java:664)

      at
org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.jav
a:527)

      at
org.apache.tomcat.util.net.MasterSlaveWorkerThread.run(MasterSlaveWorkerThre
ad.java:112)

      at java.lang.Thread.run(Thread.java:595)

 

 


Mime
View raw message