This week's book giveaway is in the Agile and Other Processes forum.
We're giving away four copies of The Little Book of Impediments (e-book only) and have Tom Perry on-line!
See this thread for details.
Win a copy of The Little Book of Impediments (e-book only) this week in the Agile and Other Processes forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

IncompatibleClassChangeError

 
Prabu Bala
Greenhorn
Posts: 23
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi All,
I have created a hiberante application. while starting the server itself i try to read the hibernate config file and create the session factory.But when i start the server i'm getting java.lang.IncompatibleClassChangeError exception.In my project am using the following jars.

antlr-2.7.6.jar
antlr-2.7.6RC1.jar
asm.jar
asm-attrs-1.5.3.jar
backport-util-concurrent-3.0.jar
cglib-2.1.3.jar
cglib-nodep-2.1_3.jar
commons-collections-3.1.jar
commons-lang-2.3.jar
commons-logging-1.1.jar
dom4j-1.6.1.jar
ehcache-1.3.0.jar
hibernate-3.2.5.ga.jar
jsr107cache-1.0.jar
jta-1.0.1B.jar
log4j-1.2.14.jar
spring-2.0.8.jar
spring-hibernate3.jar
xalan.jar
xercesImpl-2.8.0.jar
xml-apis.jar

Here i have attached the logs also please find it, because of the IncompatibleClassChangeError i'm not able to create the sessionfactory.It was working fine at WAS6 in AIX but now its not working in WAS6 in Linux. Please let me know what could be the reason for the exception.Think the problem is with jars but am not able to find it.


E CNTR0020E: EJB threw an unexpected (non-declared) exception during invocation of method "getULDContentTypes" on bean "BeanId(units#UNITSEJB.jar#LoadRefDataService, null)". Exception data: java.lang.IncompatibleClassChangeError
at org.dom4j.tree.AbstractElement.setAttributes(AbstractElement.java:505)
at org.dom4j.io.SAXContentHandler.addAttributes(SAXContentHandler.java:916)
at org.dom4j.io.SAXContentHandler.startElement(SAXContentHandler.java:249)
at org.apache.xerces.parsers.AbstractSAXParser.startElement(Unknown Source)
at org.apache.xerces.impl.dtd.XMLDTDValidator.startElement(Unknown Source)
at org.apache.xerces.impl.XMLNSDocumentScannerImpl.scanStartElement(Unknown Source)
at org.apache.xerces.impl.XMLNSDocumentScannerImpl$NSContentDispatcher.scanRootElementHook(Unknown Source)
at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl$FragmentContentDispatcher.dispatch(Unknown Source)
at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown Source)
at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
at org.apache.xerces.parsers.XMLParser.parse(Unknown Source)
at org.apache.xerces.parsers.AbstractSAXParser.parse(Unknown Source)
at org.apache.xerces.jaxp.SAXParserImpl$JAXPSAXParser.parse(Unknown Source)
at org.dom4j.io.SAXReader.read(SAXReader.java:465)
at org.hibernate.cfg.Configuration.doConfigure(Configuration.java:1484)
at org.hibernate.cfg.Configuration.configure(Configuration.java:1428)
at com.klm.cargo.generic.util.HibernateSession.getSessionFactory(HibernateSession.java:171)
at com.klm.cargo.generic.util.HibernateSession.createSession(HibernateSession.java:58)
at com.klm.cargo.units.dao.AbstractDAO.createSession(AbstractDAO.java:40)
at com.klm.cargo.units.dao.AbstractDAO.createSession(AbstractDAO.java:65)
at com.klm.cargo.units.dao.ReferenceDataDAO.getULDContentTypes(ReferenceDataDAO.java:215)
at com.klm.cargo.units.services.domain.RefData.getULDContentTypes(RefData.java:74)
at com.klm.cargo.units.services.ejbImpl.LoadRefDataServiceBean.getULDContentTypes(LoadRefDataServiceBean.java:204)
at com.klm.cargo.units.services.ejbComponent.EJSRemoteStatelessLoadRefDataService_811cedbf.getULDContentTypes(EJSRemoteStatelessLoadRefDataService_811cedbf.java:130)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:79)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:618)
at com.ibm.rmi.util.ProxyUtil$4.run(ProxyUtil.java:727)
at java.security.AccessController.doPrivileged(AccessController.java:246)
at com.ibm.rmi.util.ProxyUtil.invokeWithClassLoaders(ProxyUtil.java:725)
at com.ibm.CORBA.iiop.ClientDelegate.invoke(ClientDelegate.java:1155)
at $Proxy2.getULDContentTypes(Unknown Source)
at com.klm.cargo.units.services.ejbComponent._LoadRefDataService_Stub.getULDContentTypes(_LoadRefDataService_Stub.java:347)
at com.klm.cargo.units.common.serviceDelegator.RefDataServiceDelegator.getULDContentTypes(RefDataServiceDelegator.java:203)
at com.klm.cargo.generic.util.LoadContentTypeList.execute(LoadContentTypeList.java:36)
at org.quartz.core.JobRunShell.run(JobRunShell.java:195)
at org.quartz.simpl.SimpleThreadPool$WorkerThread.run(SimpleThreadPool.java:520)



Thanks in advance
Prabu
 
Cameron Wallace McKenzie
author and cow tipper
Saloon Keeper
Posts: 4968
1
Hibernate Spring Tomcat Server
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Which server are you using?

Sounds like it might be a ClassLoader problem. Is that possible? Sometimes setting a classloader for a web module or ear to PARENT_FIRST can solve these problems.

public class IncompatibleClassChangeError
extends LinkageError

Thrown when an incompatible class change has occurred to some class definition. The definition of some class, on which the currently executing method depends, has since changed.



JavaDoc for IncompatibleClassChangeError

No chance that rebooting the server or JVM might fix this problem, is there?

-Cameron McKenzie
 
Prabu Bala
Greenhorn
Posts: 23
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi McKenzie,

Thank you very much for your reply. I'm using WebSphere 6.1 in Linux environment. Ya i tried with class loader option PARENT_FIRST but still am facing the same problem. I'm using Java 1.5 and j2ee 1.4 version.
How can i reboot the JVM? Please let me know the causes for the exception and also the way to solve the problem.

Thanks,
Prabu
 
Cameron Wallace McKenzie
author and cow tipper
Saloon Keeper
Posts: 4968
1
Hibernate Spring Tomcat Server
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Rebooting the JVM is as simple, or as hard, as just stopping the server and starting it up again. The server is, essentially, just a JVM with all sorts of great IBM code running on it.

Maybe the admins will move this post to the WebSphere forum? I'm not sure if this is a Hibernate specific problem or not? What do you think?

-Cameron McKenzie
 
Prabu Bala
Greenhorn
Posts: 23
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I don't think the problem is because of WebSphere.I hope its because of soem version problem between the jars. I tried to find it but i was not able to check it. Ok i will check it with WebSphere admin also meanwhile if anyone of you come to know the reason please reply for this.

Thanks,
Prabu
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic