ClassCastException at cache.getWithMetadata(key) in HotRod client during JDG rolling upgrade

Solution Verified - Updated -

Issue

After configuring JDG rolling upgrade, the following ClassCastException occurred in HotRod client when executing every first cache.getWithMetadata(key) from new target cluster.

WARN: ISPN004005: Error received from the server:
java.lang.ClassCastException:
org.infinispan.container.entries.ReadCommittedEntry cannot be cast to
org.infinispan.container.entries.InternalCacheEntry
org.infinispan.client.hotrod.exceptions.HotRodClientException:Request
for message id[5] returned server error (status=0x85):
java.lang.ClassCastException:
org.infinispan.container.entries.ReadCommittedEntry cannot be cast to
org.infinispan.container.entries.InternalCacheEntry
    at org.infinispan.client.hotrod.impl.protocol.Codec20.checkForErrorsInResponseStatus(Codec20.java:336)
    at org.infinispan.client.hotrod.impl.protocol.Codec20.readPartialHeader(Codec20.java:126)
    at org.infinispan.client.hotrod.impl.protocol.Codec20.readHeader(Codec20.java:112)
    at org.infinispan.client.hotrod.impl.operations.HotRodOperation.readHeaderAndValidate(HotRodOperation.java:56)
    at org.infinispan.client.hotrod.impl.operations.AbstractKeyOperation.sendKeyOperation(AbstractKeyOperation.java:53)
    at org.infinispan.client.hotrod.impl.operations.GetWithMetadataOperation.executeOperation(GetWithMetadataOperation.java:35)
    at org.infinispan.client.hotrod.impl.operations.GetWithMetadataOperation.executeOperation(GetWithMetadataOperation.java:23)
    at org.infinispan.client.hotrod.impl.operations.RetryOnFailureOperation.execute(RetryOnFailureOperation.java:52)
    at org.infinispan.client.hotrod.impl.RemoteCacheImpl.getWithMetadata(RemoteCacheImpl.java:166)
    at com.redhat.jboss.support.HotRodClient.run(HotRodClient.java:43)
    at com.redhat.jboss.support.HotRodClient.main(HotRodClient.java:62)

Environment

  • Red Hat JBoss Data Grid (JDG)
    • 6.6

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase of over 48,000 articles and solutions.

Current Customers and Partners

Log in for full access

Log In