[jboss-jira] [JBoss JIRA] Updated: (JBCACHE-1212) ClassNotFoundException when connecting to exisiting cache

Manik Surtani (JIRA) jira-events at lists.jboss.org
Fri Nov 9 13:06:10 EST 2007


     [ http://jira.jboss.com/jira/browse/JBCACHE-1212?page=all ]

Manik Surtani updated JBCACHE-1212:
-----------------------------------

    Comment: was deleted

> ClassNotFoundException when connecting to exisiting cache
> ---------------------------------------------------------
>
>                 Key: JBCACHE-1212
>                 URL: http://jira.jboss.com/jira/browse/JBCACHE-1212
>             Project: JBoss Cache
>          Issue Type: Bug
>      Security Level: Public(Everyone can see) 
>    Affects Versions: 2.0.0.GA
>         Environment: Java 1.6.0_02; dependencies according to POM, except JGroups 2.5.0GA; Win XP SP2 fully patched
>            Reporter: Carl Shelbourne
>         Assigned To: Manik Surtani
>             Fix For: 2.1.0.GA
>
>
> When running internal tests for our application we spotted the following exceptions.
> The method within our code, _remove() provides a simple check before removing from the cache:
> ...
> protected void _remove( final Fqn fqn ) throws CacheException
>     {
>         if ( getTreeCache().getRoot().hasChild( fqn ) )
>         {
>             getTreeCache().removeNode( fqn );
>             getFqnList().remove( fqn );
>         }
>     }
> ...
> All the code appears to work ok, with the exception of when a we try to connect to an existing cache, from observations, once the cache is started we seem to get this exception. It is difficult to establish the exact cause, but it seems that a remove has been called before all the classes are instantiated??? Not sure, sorry.
> Exception in thread "Thread-166" java.lang.RuntimeException: java.lang.ClassNotFoundException: [Ljava.lang.StackTraceElement;
> 	at org.jboss.cache.CacheImpl.invokeMethod(CacheImpl.java:3951)
> 	at org.jboss.cache.CacheImpl.remove(CacheImpl.java:1637)
> 	at org.jboss.cache.CacheImpl.removeNode(CacheImpl.java:4376)
> 	at uk.org.netvu.common.edp.db.cache.CachedDBTable._remove(CachedDBTable.java:235)
> 	at uk.org.netvu.common.edp.db.cache.MutableAlarmTable.remove(MutableAlarmTable.java:52)
> 	at uk.org.netvu.edp2.db.helpers.Edp2DbAlarmActionHelper.removeSessionFromCache(Edp2DbAlarmActionHelper.java:75)
> 	at uk.org.netvu.edp2.db.Edp2DbManager$RemoveAlarmSessionFromCacheTask$1.run(Edp2DbManager.java:1835)
> Caused by: java.lang.ClassNotFoundException: [Ljava.lang.StackTraceElement;
> 	at java.net.URLClassLoader$1.run(URLClassLoader.java:200)
> 	at java.security.AccessController.doPrivileged(Native Method)
> 	at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
> 	at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
> 	at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:276)
> 	at java.lang.ClassLoader.loadClass(ClassLoader.java:251)
> 	at org.jboss.util.stream.MarshalledValueInputStream.resolveClass(MarshalledValueInputStream.java:58)
> 	at java.io.ObjectInputStream.readNonProxyDesc(ObjectInputStream.java:1575)
> 	at java.io.ObjectInputStream.readClassDesc(ObjectInputStream.java:1496)
> 	at java.io.ObjectInputStream.readArray(ObjectInputStream.java:1624)
> 	at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1323)
> 	at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:1945)
> 	at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1869)
> 	at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1753)
> 	at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1329)
> 	at java.io.ObjectInputStream.readObject(ObjectInputStream.java:351)
> 	at org.jboss.cache.marshall.CacheMarshaller200.unmarshallObject(CacheMarshaller200.java:537)
> 	at org.jboss.cache.marshall.CacheMarshaller200.objectFromObjectStreamRegionBased(CacheMarshaller200.java:191)
> 	at org.jboss.cache.marshall.CacheMarshaller200.objectFromObjectStream(CacheMarshaller200.java:142)
> 	at org.jboss.cache.marshall.VersionAwareMarshaller.objectFromByteBuffer(VersionAwareMarshaller.java:154)
> 	at org.jgroups.blocks.RequestCorrelator.receiveMessage(RequestCorrelator.java:544)
> 	at org.jgroups.blocks.RequestCorrelator.receive(RequestCorrelator.java:365)
> 	at org.jgroups.blocks.MessageDispatcher$ProtocolAdapter.up(MessageDispatcher.java:736)
> 	at org.jgroups.JChannel.up(JChannel.java:1063)
> 	at org.jgroups.stack.ProtocolStack.up(ProtocolStack.java:325)
> 	at org.jgroups.protocols.pbcast.FLUSH.up(FLUSH.java:406)
> 	at org.jgroups.protocols.pbcast.STREAMING_STATE_TRANSFER.up(STREAMING_STATE_TRANSFER.java:255)
> 	at org.jgroups.protocols.FRAG2.up(FRAG2.java:197)
> 	at org.jgroups.protocols.pbcast.GMS.up(GMS.java:722)
> 	at org.jgroups.protocols.pbcast.STABLE.up(STABLE.java:234)
> 	at org.jgroups.protocols.UNICAST.handleDataReceived(UNICAST.java:569)
> 	at org.jgroups.protocols.UNICAST.up(UNICAST.java:246)
> 	at org.jgroups.protocols.pbcast.NAKACK.up(NAKACK.java:596)
> 	at org.jgroups.protocols.VERIFY_SUSPECT.up(VERIFY_SUSPECT.java:167)
> 	at org.jgroups.protocols.FD.up(FD.java:322)
> 	at org.jgroups.protocols.FD_SOCK.up(FD_SOCK.java:298)
> 	at org.jgroups.protocols.MERGE2.up(MERGE2.java:145)
> 	at org.jgroups.protocols.Discovery.up(Discovery.java:220)
> 	at org.jgroups.protocols.TP$IncomingPacket.handleMyMessage(TP.java:1486)
> 	at org.jgroups.protocols.TP$IncomingPacket.run(TP.java:1440)
> 	at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:885)
> 	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:907)
> 	at java.lang.Thread.run(Thread.java:619)
> Exception in thread "Thread-167" java.lang.RuntimeException: java.lang.ClassNotFoundException: [Ljava.lang.StackTraceElement;
> 	at org.jboss.cache.CacheImpl.invokeMethod(CacheImpl.java:3951)
> 	at org.jboss.cache.CacheImpl.remove(CacheImpl.java:1637)
> 	at org.jboss.cache.CacheImpl.removeNode(CacheImpl.java:4376)
> 	at uk.org.netvu.common.edp.db.cache.CachedDBTable._remove(CachedDBTable.java:235)
> 	at uk.org.netvu.common.edp.db.cache.MutableAlarmTable.remove(MutableAlarmTable.java:52)
> 	at uk.org.netvu.edp2.db.helpers.Edp2DbAlarmActionHelper.removeSessionFromCache(Edp2DbAlarmActionHelper.java:75)
> 	at uk.org.netvu.edp2.db.Edp2DbManager$RemoveAlarmSessionFromCacheTask$1.run(Edp2DbManager.java:1835)
> Exception in thread "Thread-168" Caused by: java.lang.ClassNotFoundException: [Ljava.lang.StackTraceElement;
> 	at java.net.URLClassLoader$1.run(URLClassLoader.java:200)
> 	at java.security.AccessController.doPrivileged(Native Method)
> 	at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
> 	at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
> 	at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:276)
> 	at java.lang.ClassLoader.loadClass(ClassLoader.java:251)
> 	at org.jboss.util.stream.MarshalledValueInputStream.resolveClass(MarshalledValueInputStream.java:58)
> 	at java.io.ObjectInputStream.readNonProxyDesc(ObjectInputStream.java:1575)
> 	at java.io.ObjectInputStream.readClassDesc(ObjectInputStream.java:1496)
> 	at java.io.ObjectInputStream.readArray(ObjectInputStream.java:1624)
> 	at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1323)
> 	at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:1945)
> 	at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1869)
> 	at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1753)
> 	at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1329)
> 	at java.io.ObjectInputStream.readObject(ObjectInputStream.java:351)
> 	at org.jboss.cache.marshall.CacheMarshaller200.unmarshallObject(CacheMarshaller200.java:537)
> 	at org.jboss.cache.marshall.CacheMarshaller200.objectFromObjectStreamRegionBased(CacheMarshaller200.java:191)
> 	at org.jboss.cache.marshall.CacheMarshaller200.objectFromObjectStream(CacheMarshaller200.java:142)
> 	at org.jboss.cache.marshall.VersionAwareMarshaller.objectFromByteBuffer(VersionAwareMarshaller.java:154)
> 	at org.jgroups.blocks.RequestCorrelator.receiveMessage(RequestCorrelator.java:544)
> 	at org.jgroups.blocks.RequestCorrelator.receive(RequestCorrelator.java:365)
> 	at org.jgroups.blocks.MessageDispatcher$ProtocolAdapter.up(MessageDispatcher.java:736)
> 	at org.jgroups.JChannel.up(JChannel.java:1063)
> 	at org.jgroups.stack.ProtocolStack.up(ProtocolStack.java:325)
> 	at org.jgroups.protocols.pbcast.FLUSH.up(FLUSH.java:406)
> 	at org.jgroups.protocols.pbcast.STREAMING_STATE_TRANSFER.up(STREAMING_STATE_TRANSFER.java:255)
> 	at org.jgroups.protocols.FRAG2.up(FRAG2.java:197)
> 	at org.jgroups.protocols.pbcast.GMS.up(GMS.java:722)
> 	at org.jgroups.protocols.pbcast.STABLE.up(STABLE.java:234)
> 	at org.jgroups.protocols.UNICAST.handleDataReceived(UNICAST.java:569)
> 	at org.jgroups.protocols.UNICAST.up(UNICAST.java:246)
> 	at org.jgroups.protocols.pbcast.NAKACK.up(NAKACK.java:596)
> 	at org.jgroups.protocols.VERIFY_SUSPECT.up(VERIFY_SUSPECT.java:167)
> 	at org.jgroups.protocols.FD.up(FD.java:322)
> 	at org.jgroups.protocols.FD_SOCK.up(FD_SOCK.java:298)
> 	at org.jgroups.protocols.MERGE2.up(MERGE2.java:145)
> 	at org.jgroups.protocols.Discovery.up(Discovery.java:220)
> 	at org.jgroups.protocols.TP$IncomingPacket.handleMyMessage(TP.java:1486)
> 	at org.jgroups.protocols.TP$IncomingPacket.run(TP.java:1440)
> 	at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:885)
> 	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:907)
> 	at java.lang.Thread.run(Thread.java:619)
> java.lang.RuntimeException: java.lang.ClassNotFoundException: [Ljava.lang.StackTraceElement;
> 	at org.jboss.cache.CacheImpl.invokeMethod(CacheImpl.java:3951)
> 	at org.jboss.cache.CacheImpl.remove(CacheImpl.java:1637)
> 	at org.jboss.cache.CacheImpl.removeNode(CacheImpl.java:4376)
> 	at uk.org.netvu.common.edp.db.cache.CachedDBTable._remove(CachedDBTable.java:235)
> 	at uk.org.netvu.common.edp.db.cache.MutableAlarmTable.remove(MutableAlarmTable.java:52)
> 	at uk.org.netvu.edp2.db.helpers.Edp2DbAlarmActionHelper.removeSessionFromCache(Edp2DbAlarmActionHelper.java:75)
> 	at uk.org.netvu.edp2.db.Edp2DbManager$RemoveAlarmSessionFromCacheTask$1.run(Edp2DbManager.java:1835)
> Caused by: java.lang.ClassNotFoundException: [Ljava.lang.StackTraceElement;
> 	at java.net.URLClassLoader$1.run(URLClassLoader.java:200)
> 	at java.security.AccessController.doPrivileged(Native Method)
> 	at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
> 	at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
> 	at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:276)
> 	at java.lang.ClassLoader.loadClass(ClassLoader.java:251)
> 	at org.jboss.util.stream.MarshalledValueInputStream.resolveClass(MarshalledValueInputStream.java:58)
> 	at java.io.ObjectInputStream.readNonProxyDesc(ObjectInputStream.java:1575)
> 	at java.io.ObjectInputStream.readClassDesc(ObjectInputStream.java:1496)
> 	at java.io.ObjectInputStream.readArray(ObjectInputStream.java:1624)
> 	at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1323)
> 	at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:1945)
> 	at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1869)
> 	at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1753)
> 	at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1329)
> 	at java.io.ObjectInputStream.readObject(ObjectInputStream.java:351)
> 	at org.jboss.cache.marshall.CacheMarshaller200.unmarshallObject(CacheMarshaller200.java:537)
> 	at org.jboss.cache.marshall.CacheMarshaller200.objectFromObjectStreamRegionBased(CacheMarshaller200.java:191)
> 	at org.jboss.cache.marshall.CacheMarshaller200.objectFromObjectStream(CacheMarshaller200.java:142)
> 	at org.jboss.cache.marshall.VersionAwareMarshaller.objectFromByteBuffer(VersionAwareMarshaller.java:154)
> 	at org.jgroups.blocks.RequestCorrelator.receiveMessage(RequestCorrelator.java:544)
> 	at org.jgroups.blocks.RequestCorrelator.receive(RequestCorrelator.java:365)
> 	at org.jgroups.blocks.MessageDispatcher$ProtocolAdapter.up(MessageDispatcher.java:736)
> 	at org.jgroups.JChannel.up(JChannel.java:1063)
> 	at org.jgroups.stack.ProtocolStack.up(ProtocolStack.java:325)
> 	at org.jgroups.protocols.pbcast.FLUSH.up(FLUSH.java:406)
> 	at org.jgroups.protocols.pbcast.STREAMING_STATE_TRANSFER.up(STREAMING_STATE_TRANSFER.java:255)
> 	at org.jgroups.protocols.FRAG2.up(FRAG2.java:197)
> 	at org.jgroups.protocols.pbcast.GMS.up(GMS.java:722)
> 	at org.jgroups.protocols.pbcast.STABLE.up(STABLE.java:234)
> 	at org.jgroups.protocols.UNICAST.handleDataReceived(UNICAST.java:569)
> 	at org.jgroups.protocols.UNICAST.up(UNICAST.java:246)
> 	at org.jgroups.protocols.pbcast.NAKACK.up(NAKACK.java:596)
> 	at org.jgroups.protocols.VERIFY_SUSPECT.up(VERIFY_SUSPECT.java:167)
> 	at org.jgroups.protocols.FD.up(FD.java:322)
> 	at org.jgroups.protocols.FD_SOCK.up(FD_SOCK.java:298)
> 	at org.jgroups.protocols.MERGE2.up(MERGE2.java:145)
> 	at org.jgroups.protocols.Discovery.up(Discovery.java:220)
> 	at org.jgroups.protocols.TP$IncomingPacket.handleMyMessage(TP.java:1486)
> 	at org.jgroups.protocols.TP$IncomingPacket.run(TP.java:1440)
> 	at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:885)
> 	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:907)
> 	at java.lang.Thread.run(Thread.java:619)

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.jboss.com/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        



More information about the jboss-jira mailing list