"java.io.NotSerializableException: NonSerializedComplexType" Error Thrown When Putting Non-Serializable Data On Multi-Node Replicated Cache (Doc ID 1102750.1)

Last updated on NOVEMBER 03, 2016

Applies to:

Oracle Coherence - Version 3.4.0 and later
Information in this document applies to any platform.

Symptoms

Using a replicated cache with only one cluster member, the cache put works fine and no exception message is thrown. Subsequent get calls return the appropriate values. But when a second member joins the cluster, the original cache service crashes and all data in the cache is lost, including any serializable values that might have been added.

An exception message like the following is thrown:

2010-04-19 14:14:15.968/6.859 Oracle Coherence GE 3.5.1/461 <Error> (thread=ReplicatedCache, member=1):
(Wrapped) java.io.NotSerializableException: NonSerializedComplexType
at com.tangosol.util.ExternalizableHelper.toBinary(ExternalizableHelper.java:210)
at com.tangosol.coherence.component.util.CacheHandler.populateUpdateMessage(CacheHandler.CDB:69)
at com.tangosol.coherence.component.util.daemon.queueProcessor.service.grid.ReplicatedCache.onCacheUpdateRequest(ReplicatedCache.CDB:32)
at com.tangosol.coherence.component.util.daemon.queueProcessor.service.grid.ReplicatedCache$CacheUpdateRequest.onReceived(ReplicatedCache.CDB:5)
at com.tangosol.coherence.component.util.daemon.queueProcessor.service.Grid.onMessage(Grid.CDB:9)
at com.tangosol.coherence.component.util.daemon.queueProcessor.service.Grid.onNotify(Grid.CDB:136)
at com.tangosol.coherence.component.util.daemon.queueProcessor.service.grid.ReplicatedCache.onNotify(ReplicatedCache.CDB:3)
at com.tangosol.coherence.component.util.Daemon.run(Daemon.CDB:42)
at java.lang.Thread.run(Thread.java:619)
Caused by: java.io.NotSerializableException: NonSerializedComplexType
at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1156)
at java.io.ObjectOutputStream.writeObject(ObjectOutputStream.java:326)
at com.tangosol.util.ExternalizableHelper.writeSerializable(ExternalizableHelper.java:2181)
at com.tangosol.util.ExternalizableHelper.writeObjectInternal(ExternalizableHelper.java:2629)
at com.tangosol.util.ExternalizableHelper.serializeInternal(ExternalizableHelper.java:2529)
at com.tangosol.util.ExternalizableHelper.toBinary(ExternalizableHelper.java:206)
... 8 more

Cause

Sign In with your My Oracle Support account

Don't have a My Oracle Support account? Click to get started

My Oracle Support provides customers with access to over a
Million Knowledge Articles and hundreds of Community platforms