[infinispan-dev] Weird ClassCastException ..

Sanne Grinovero sanne at infinispan.org
Tue Aug 5 10:02:45 EDT 2014


I've figured it out.
I'll not explain it yet, it's such a nice puzzler :-P
@Galder you were close: let me say JGroups is the only one not related.

On 5 August 2014 14:01, Galder Zamarreño <galder at redhat.com> wrote:
>
> On 05 Aug 2014, at 01:33, Sanne Grinovero <sanne at infinispan.org> wrote:
>
>> I'm (rarely) seeing this exception in one of my stress tests.. any
>> clue about what could be wrong?
>
> Hmmm, it smells like a concurrency issue, e.g. buffer mixup, in either jboss marshalling, jgroups or the externalizer layer in Infinispan.
>
>> I reported a similar one approx a year ago, in that case it was a
>> value type being unmarshalled as an instance of Class (was also never
>> resolved).
>
> ^ Do you have a JIRA for it?
>
> Please definitely create one for this new CCE.
>
> Cheers,
>
>>
>> 2014-08-05 00:22:29,521 WARN  [CommandAwareRpcDispatcher]
>> (OOB-1,main-NodeD-22196) ISPN000220: Problems un-marshalling remote
>> command from byte buffer
>> java.lang.ClassCastException: java.lang.String cannot be cast to
>> org.infinispan.metadata.Metadata
>> at org.infinispan.commands.write.PutKeyValueCommand.setParameters(PutKeyValueCommand.java:114)
>> at org.infinispan.commands.RemoteCommandsFactory.fromStream(RemoteCommandsFactory.java:138)
>> at org.infinispan.marshall.exts.ReplicableCommandExternalizer.readObject(ReplicableCommandExternalizer.java:85)
>> at org.infinispan.marshall.exts.ReplicableCommandExternalizer.readObject(ReplicableCommandExternalizer.java:1)
>> at org.infinispan.marshall.core.ExternalizerTable$ExternalizerAdapter.readObject(ExternalizerTable.java:409)
>> at org.infinispan.marshall.core.ExternalizerTable.readObject(ExternalizerTable.java:214)
>> at org.infinispan.marshall.core.JBossMarshaller$ExternalizerTableProxy.readObject(JBossMarshaller.java:148)
>> at org.jboss.marshalling.river.RiverUnmarshaller.doReadObject(RiverUnmarshaller.java:351)
>> at org.jboss.marshalling.river.RiverUnmarshaller.doReadObject(RiverUnmarshaller.java:209)
>> at org.jboss.marshalling.AbstractObjectInput.readObject(AbstractObjectInput.java:41)
>> at org.infinispan.marshall.exts.ReplicableCommandExternalizer.readParameters(ReplicableCommandExternalizer.java:101)
>> at org.infinispan.marshall.exts.CacheRpcCommandExternalizer.readObject(CacheRpcCommandExternalizer.java:153)
>> at org.infinispan.marshall.exts.CacheRpcCommandExternalizer.readObject(CacheRpcCommandExternalizer.java:1)
>> at org.infinispan.marshall.core.ExternalizerTable$ExternalizerAdapter.readObject(ExternalizerTable.java:409)
>> at org.infinispan.marshall.core.ExternalizerTable.readObject(ExternalizerTable.java:214)
>> at org.infinispan.marshall.core.JBossMarshaller$ExternalizerTableProxy.readObject(JBossMarshaller.java:148)
>> at org.jboss.marshalling.river.RiverUnmarshaller.doReadObject(RiverUnmarshaller.java:351)
>> at org.jboss.marshalling.river.RiverUnmarshaller.doReadObject(RiverUnmarshaller.java:209)
>> at org.jboss.marshalling.AbstractObjectInput.readObject(AbstractObjectInput.java:41)
>> at org.infinispan.commons.marshall.jboss.AbstractJBossMarshaller.objectFromObjectStream(AbstractJBossMarshaller.java:135)
>> at org.infinispan.marshall.core.VersionAwareMarshaller.objectFromByteBuffer(VersionAwareMarshaller.java:101)
>> at org.infinispan.commons.marshall.AbstractDelegatingMarshaller.objectFromByteBuffer(AbstractDelegatingMarshaller.java:80)
>> at org.infinispan.remoting.transport.jgroups.MarshallerAdapter.objectFromBuffer(MarshallerAdapter.java:28)
>> at org.infinispan.remoting.transport.jgroups.CommandAwareRpcDispatcher.handle(CommandAwareRpcDispatcher.java:204)
>> at org.jgroups.blocks.RequestCorrelator.handleRequest(RequestCorrelator.java:460)
>> at org.jgroups.blocks.RequestCorrelator.receiveMessage(RequestCorrelator.java:377)
>> at org.jgroups.blocks.RequestCorrelator.receive(RequestCorrelator.java:250)
>> at org.jgroups.blocks.MessageDispatcher$ProtocolAdapter.up(MessageDispatcher.java:674)
>> at org.jgroups.JChannel.up(JChannel.java:733)
>> at org.jgroups.stack.ProtocolStack.up(ProtocolStack.java:1030)
>> at org.jgroups.protocols.RSVP.up(RSVP.java:190)
>> at org.jgroups.protocols.FRAG2.up(FRAG2.java:165)
>> at org.jgroups.protocols.FlowControl.up(FlowControl.java:390)
>> at org.jgroups.protocols.tom.TOA.up(TOA.java:121)
>> at org.jgroups.protocols.pbcast.GMS.up(GMS.java:1041)
>> at org.jgroups.protocols.pbcast.STABLE.up(STABLE.java:234)
>> at org.jgroups.protocols.UNICAST3.deliverMessage(UNICAST3.java:1034)
>> at org.jgroups.protocols.UNICAST3.handleDataReceived(UNICAST3.java:752)
>> at org.jgroups.protocols.UNICAST3.up(UNICAST3.java:399)
>> at org.jgroups.protocols.pbcast.NAKACK2.up(NAKACK2.java:610)
>> at org.jgroups.protocols.FD_SOCK.up(FD_SOCK.java:297)
>> at org.jgroups.protocols.Discovery.up(Discovery.java:245)
>> at org.jgroups.protocols.TP.passMessageUp(TP.java:1551)
>> at org.jgroups.protocols.TP$MyHandler.run(TP.java:1770)
>> at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
>> at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
>> at java.lang.Thread.run(Thread.java:745)
>> _______________________________________________
>> infinispan-dev mailing list
>> infinispan-dev at lists.jboss.org
>> https://lists.jboss.org/mailman/listinfo/infinispan-dev
>
>
> --
> Galder Zamarreño
> galder at redhat.com
> twitter.com/galderz
>
>
> _______________________________________________
> infinispan-dev mailing list
> infinispan-dev at lists.jboss.org
> https://lists.jboss.org/mailman/listinfo/infinispan-dev



More information about the infinispan-dev mailing list