org.redisson.client.RedisException:处理命令时出现意外异常

问题描述

我使用 Radisson 作为分布式缓存,它正在由两个 aws ECS 实例更新。最终,我得到了这个例外。清除缓存后,它工作正常,一段时间后再次发生。我无法缩小问题的范围。从这里寻求帮助。

  1. 缓存对象被 Java 服务频繁更新和频繁检索。
  2. 问题最终会发生,这意味着某些对象正在正确缓存和检索,有时检索时会出现此错误

注意:通过网上搜索,我发现有一个编组问题,redisson 在 3.15.x 版本上修复了它。即使我更新了库,这个问题仍然存在。

org.redisson.client.RedisException: Unexpected exception while processing command
    at org.redisson.command.CommandAsyncService.convertException(CommandAsyncService.java:350) ~[redisson-3.13.1.jar:3.13.1]
    at org.redisson.command.CommandAsyncService.get(CommandAsyncService.java:147) ~[redisson-3.13.1.jar:3.13.1]
    at org.redisson.RedissonObject.get(RedissonObject.java:90) ~[redisson-3.13.1.jar:3.13.1]
    at org.redisson.RedissonMap.get(RedissonMap.java:267) ~[redisson-3.13.1.jar:3.13.1]
    at com.mycompany.app.location.locationupdate.cache.LocationSnapshotCache.getLocation(LocationSnapshotCache.java:60) ~[classes/:na]
    at com.mycompany.app.location.locationupdate.stationsnapshot.AbstractSnapshotService.getLatestLocationSnapshotWrapper(AbstractSnapshotService.java:60) ~[classes/:na]
    at com.mycompany.app.location.locationupdate.OrderUpdateUtils.updateLocationCache(OrderUpdateUtils.java:52) ~[classes/:na]
    at com.mycompany.app.location.kafka.impl.ProcessingEventConsumer.updateSnapshotCache(ProcessingEventConsumer.java:70) ~[classes/:na]
    at com.mycompany.app.location.kafka.impl.ProcessingCompletedEventConsumer.updateSnapshotCache(ProcessingCompletedEventConsumer.java:24) [classes/:na]
    at com.mycompany.app.location.kafka.impl.ProcessingCompletedEventConsumer.handleEvent(ProcessingCompletedEventConsumer.java:60) [classes/:na]
    at com.mycompany.app.location.kafka.impl.ProcessingCompletedEventConsumer.handleEvent(ProcessingCompletedEventConsumer.java:24) [classes/:na]
    at com.mycompany.app.location.kafka.impl.ProcessingCompletedEventConsumer$$FastClassBySpringcglib$$194f8c48.invoke(<generated>) [classes/:na]
    at org.springframework.cglib.proxy.MethodProxy.invoke(MethodProxy.java:218) [spring-core-5.2.9.RELEASE.jar:5.2.9.RELEASE]
    at org.springframework.aop.framework.cglibAopProxy$cglibMethodInvocation.invokeJoinpoint(cglibAopProxy.java:771) [spring-aop-5.2.9.RELEASE.jar:5.2.9.RELEASE]
    at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:163) [spring-aop-5.2.9.RELEASE.jar:5.2.9.RELEASE]
    at org.springframework.aop.framework.cglibAopProxy$cglibMethodInvocation.proceed(cglibAopProxy.java:749) [spring-aop-5.2.9.RELEASE.jar:5.2.9.RELEASE]
    at org.springframework.transaction.interceptor.TransactionAspectSupport.invokeWithinTransaction(TransactionAspectSupport.java:367) ~[spring-tx-5.2.9.RELEASE.jar:5.2.9.RELEASE]
    at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:118) ~[spring-tx-5.2.9.RELEASE.jar:5.2.9.RELEASE]
    at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:186) [spring-aop-5.2.9.RELEASE.jar:5.2.9.RELEASE]
    at org.springframework.aop.framework.cglibAopProxy$cglibMethodInvocation.proceed(cglibAopProxy.java:749) [spring-aop-5.2.9.RELEASE.jar:5.2.9.RELEASE]
    at org.springframework.retry.interceptor.RetryOperationsInterceptor$1.doWithRetry(RetryOperationsInterceptor.java:91) ~[spring-retry-1.2.5.RELEASE.jar:na]
    at org.springframework.retry.support.RetryTemplate.doExecute(RetryTemplate.java:287) ~[spring-retry-1.2.5.RELEASE.jar:na]
    at org.springframework.retry.support.RetryTemplate.execute(RetryTemplate.java:180) ~[spring-retry-1.2.5.RELEASE.jar:na]
    at org.springframework.retry.interceptor.RetryOperationsInterceptor.invoke(RetryOperationsInterceptor.java:115) ~[spring-retry-1.2.5.RELEASE.jar:na]
    at org.springframework.retry.annotation.AnnotationAwareRetryOperationsInterceptor.invoke(AnnotationAwareRetryOperationsInterceptor.java:153) ~[spring-retry-1.2.5.RELEASE.jar:na]
    at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:186) [spring-aop-5.2.9.RELEASE.jar:5.2.9.RELEASE]
    at org.springframework.aop.framework.cglibAopProxy$cglibMethodInvocation.proceed(cglibAopProxy.java:749) [spring-aop-5.2.9.RELEASE.jar:5.2.9.RELEASE]
    at org.springframework.aop.framework.cglibAopProxy$DynamicAdvisedInterceptor.intercept(cglibAopProxy.java:691) ~[spring-aop-5.2.9.RELEASE.jar:5.2.9.RELEASE]
    at com.mycompany.app.location.kafka.impl.ProcessingCompletedEventConsumer$$EnhancerBySpringcglib$$6c678b3e.handleEvent(<generated>) ~[classes/:na]
    at com.mycompany.app.location.config.kafka.KafkaEventStreamConfiguration.lambda$kStreamOrderForceCompleted$23(KafkaEventStreamConfiguration.java:332) ~[classes/:na]
    at org.apache.kafka.streams.kstream.internals.KStreamPeek$KStreamPeekProcessor.process(KStreamPeek.java:42) ~[kafka-streams-2.5.1.jar:na]
    at org.apache.kafka.streams.processor.internals.ProcessorNode.lambda$process$2(ProcessorNode.java:142) ~[kafka-streams-2.5.1.jar:na]
    at org.apache.kafka.streams.processor.internals.metrics.StreamsMetricsImpl.maybeMeasureLatency(StreamsMetricsImpl.java:806) ~[kafka-streams-2.5.1.jar:na]
    at org.apache.kafka.streams.processor.internals.ProcessorNode.process(ProcessorNode.java:142) ~[kafka-streams-2.5.1.jar:na]
    at org.apache.kafka.streams.processor.internals.ProcessorContextImpl.forward(ProcessorContextImpl.java:201) ~[kafka-streams-2.5.1.jar:na]
    at org.apache.kafka.streams.processor.internals.ProcessorContextImpl.forward(ProcessorContextImpl.java:180) ~[kafka-streams-2.5.1.jar:na]
    at org.apache.kafka.streams.processor.internals.ProcessorContextImpl.forward(ProcessorContextImpl.java:133) ~[kafka-streams-2.5.1.jar:na]
    at org.apache.kafka.streams.kstream.internals.KStreamFilter$KStreamFilterProcessor.process(KStreamFilter.java:43) ~[kafka-streams-2.5.1.jar:na]
    at org.apache.kafka.streams.processor.internals.ProcessorNode.lambda$process$2(ProcessorNode.java:142) ~[kafka-streams-2.5.1.jar:na]
    at org.apache.kafka.streams.processor.internals.metrics.StreamsMetricsImpl.maybeMeasureLatency(StreamsMetricsImpl.java:806) ~[kafka-streams-2.5.1.jar:na]
    at org.apache.kafka.streams.processor.internals.ProcessorNode.process(ProcessorNode.java:142) ~[kafka-streams-2.5.1.jar:na]
    at org.apache.kafka.streams.processor.internals.ProcessorContextImpl.forward(ProcessorContextImpl.java:201) ~[kafka-streams-2.5.1.jar:na]
    at org.apache.kafka.streams.processor.internals.ProcessorContextImpl.forward(ProcessorContextImpl.java:180) ~[kafka-streams-2.5.1.jar:na]
    at org.apache.kafka.streams.processor.internals.ProcessorContextImpl.forward(ProcessorContextImpl.java:133) ~[kafka-streams-2.5.1.jar:na]
    at org.apache.kafka.streams.processor.internals.sourceNode.process(SourceNode.java:104) ~[kafka-streams-2.5.1.jar:na]
    at org.apache.kafka.streams.processor.internals.StreamTask.lambda$process$3(StreamTask.java:383) ~[kafka-streams-2.5.1.jar:na]
    at org.apache.kafka.streams.processor.internals.metrics.StreamsMetricsImpl.maybeMeasureLatency(StreamsMetricsImpl.java:806) ~[kafka-streams-2.5.1.jar:na]
    at org.apache.kafka.streams.processor.internals.StreamTask.process(StreamTask.java:383) ~[kafka-streams-2.5.1.jar:na]
    at org.apache.kafka.streams.processor.internals.AssignedStreamsTasks.process(AssignedStreamsTasks.java:475) ~[kafka-streams-2.5.1.jar:na]
    at org.apache.kafka.streams.processor.internals.TaskManager.process(TaskManager.java:550) ~[kafka-streams-2.5.1.jar:na]
    at org.apache.kafka.streams.processor.internals.StreamThread.runOnce(StreamThread.java:802) ~[kafka-streams-2.5.1.jar:na]
    at org.apache.kafka.streams.processor.internals.StreamThread.runLoop(StreamThread.java:697) ~[kafka-streams-2.5.1.jar:na]
    at org.apache.kafka.streams.processor.internals.StreamThread.run(StreamThread.java:670) ~[kafka-streams-2.5.1.jar:na]
Caused by: java.io.OptionalDataException: null
    at org.jboss.marshalling.Marshalling.createOptionalDataException(Marshalling.java:366) ~[jboss-marshalling-2.0.9.Final.jar:2.0.9.Final]
    at org.jboss.marshalling.river.BlockUnmarshaller.readobject(BlockUnmarshaller.java:147) ~[jboss-marshalling-river-2.0.9.Final.jar:2.0.9.Final]
    at org.jboss.marshalling.river.BlockUnmarshaller.readobject(BlockUnmarshaller.java:135) ~[jboss-marshalling-river-2.0.9.Final.jar:2.0.9.Final]
    at org.jboss.marshalling.MarshallerObjectInputStream.readobjectOverride(MarshallerObjectInputStream.java:53) ~[jboss-marshalling-2.0.9.Final.jar:2.0.9.Final]
    at org.jboss.marshalling.river.RiverObjectInputStream.readobjectOverride(RiverObjectInputStream.java:307) ~[jboss-marshalling-river-2.0.9.Final.jar:2.0.9.Final]
    at java.io.ObjectInputStream.readobject(ObjectInputStream.java:425) ~[na:1.8.0_171]
    at java.util.HashMap.readobject(HashMap.java:1407) ~[na:1.8.0_171]
    at sun.reflect.GeneratedMethodAccessor153.invoke(UnkNown Source) ~[na:na]
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[na:1.8.0_171]
    at java.lang.reflect.Method.invoke(Method.java:498) ~[na:1.8.0_171]
    at org.jboss.marshalling.reflect.JDKSpecific$SerMethods.callReadobject(JDKSpecific.java:186) ~[jboss-marshalling-2.0.9.Final.jar:2.0.9.Final]
    at org.jboss.marshalling.reflect.SerializableClass.callReadobject(SerializableClass.java:214) ~[jboss-marshalling-2.0.9.Final.jar:2.0.9.Final]
    at org.jboss.marshalling.river.RiverUnmarshaller.doInitSerializable(RiverUnmarshaller.java:1757) ~[jboss-marshalling-river-2.0.9.Final.jar:2.0.9.Final]
    at org.jboss.marshalling.river.RiverUnmarshaller.doInitSerializable(RiverUnmarshaller.java:1726) ~[jboss-marshalling-river-2.0.9.Final.jar:2.0.9.Final]
    at org.jboss.marshalling.river.RiverUnmarshaller.doReadNewObject(RiverUnmarshaller.java:1406) ~[jboss-marshalling-river-2.0.9.Final.jar:2.0.9.Final]
    at org.jboss.marshalling.river.RiverUnmarshaller.doReadobject(RiverUnmarshaller.java:283) ~[jboss-marshalling-river-2.0.9.Final.jar:2.0.9.Final]
    at org.jboss.marshalling.river.RiverUnmarshaller.doReadobject(RiverUnmarshaller.java:231) ~[jboss-marshalling-river-2.0.9.Final.jar:2.0.9.Final]
    at org.jboss.marshalling.river.RiverUnmarshaller.readFields(RiverUnmarshaller.java:1864) ~[jboss-marshalling-river-2.0.9.Final.jar:2.0.9.Final]
    at org.jboss.marshalling.river.RiverUnmarshaller.doInitSerializable(RiverUnmarshaller.java:1778) ~[jboss-marshalling-river-2.0.9.Final.jar:2.0.9.Final]
    at org.jboss.marshalling.river.RiverUnmarshaller.doInitSerializable(RiverUnmarshaller.java:1726) ~[jboss-marshalling-river-2.0.9.Final.jar:2.0.9.Final]
    at org.jboss.marshalling.river.RiverUnmarshaller.doReadNewObject(RiverUnmarshaller.java:1406) ~[jboss-marshalling-river-2.0.9.Final.jar:2.0.9.Final]
    at org.jboss.marshalling.river.RiverUnmarshaller.doReadobject(RiverUnmarshaller.java:283) ~[jboss-marshalling-river-2.0.9.Final.jar:2.0.9.Final]
    at org.jboss.marshalling.river.RiverUnmarshaller.doReadobject(RiverUnmarshaller.java:216) ~[jboss-marshalling-river-2.0.9.Final.jar:2.0.9.Final]
    at org.jboss.marshalling.AbstractObjectInput.readobject(AbstractObjectInput.java:41) ~[jboss-marshalling-2.0.9.Final.jar:2.0.9.Final]
    at org.redisson.codec.MarshallingCodec$3.decode(MarshallingCodec.java:157) ~[redisson-3.13.1.jar:3.13.1]
    at org.redisson.client.handler.CommandDecoder.decode(CommandDecoder.java:375) ~[redisson-3.13.1.jar:3.13.1]
    at org.redisson.client.handler.CommandDecoder.decodeCommand(CommandDecoder.java:196) ~[redisson-3.13.1.jar:3.13.1]
    at org.redisson.client.handler.CommandDecoder.decode(CommandDecoder.java:134) ~[redisson-3.13.1.jar:3.13.1]
    at org.redisson.client.handler.CommandDecoder.decode(CommandDecoder.java:104) ~[redisson-3.13.1.jar:3.13.1]
    at io.netty.handler.codec.BytetoMessageDecoder.decodeRemovalReentryProtection(BytetoMessageDecoder.java:501) ~[netty-codec-4.1.52.Final.jar:4.1.52.Final]
    at io.netty.handler.codec.ReplayingDecoder.callDecode(ReplayingDecoder.java:366) ~[netty-codec-4.1.52.Final.jar:4.1.52.Final]
    at io.netty.handler.codec.BytetoMessageDecoder.channelRead(BytetoMessageDecoder.java:276) ~[netty-codec-4.1.52.Final.jar:4.1.52.Final]
    at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:379) ~[netty-transport-4.1.52.Final.jar:4.1.52.Final]
    at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:365) ~[netty-transport-4.1.52.Final.jar:4.1.52.Final]
    at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:357) ~[netty-transport-4.1.52.Final.jar:4.1.52.Final]
    at io.netty.channel.DefaultChannelPipeline$HeadContext.channelRead(DefaultChannelPipeline.java:1410) ~[netty-transport-4.1.52.Final.jar:4.1.52.Final]
    at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:379) ~[netty-transport-4.1.52.Final.jar:4.1.52.Final]
    at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:365) ~[netty-transport-4.1.52.Final.jar:4.1.52.Final]
    at io.netty.channel.DefaultChannelPipeline.fireChannelRead(DefaultChannelPipeline.java:919) ~[netty-transport-4.1.52.Final.jar:4.1.52.Final]
    at io.netty.channel.nio.AbstractNioByteChannel$NioByteUnsafe.read(AbstractNioByteChannel.java:166) ~[netty-transport-4.1.52.Final.jar:4.1.52.Final]
    at io.netty.channel.nio.NioEventLoop.processSelectedKey(NioEventLoop.java:714) ~[netty-transport-4.1.52.Final.jar:4.1.52.Final]
    at io.netty.channel.nio.NioEventLoop.processSelectedKeysOptimized(NioEventLoop.java:650) ~[netty-transport-4.1.52.Final.jar:4.1.52.Final]
    at io.netty.channel.nio.NioEventLoop.processSelectedKeys(NioEventLoop.java:576) ~[netty-transport-4.1.52.Final.jar:4.1.52.Final]
    at io.netty.channel.nio.NioEventLoop.run(NioEventLoop.java:493) ~[netty-transport-4.1.52.Final.jar:4.1.52.Final]
    at io.netty.util.concurrent.SingleThreadEventExecutor$4.run(SingleThreadEventExecutor.java:989) ~[netty-common-4.1.52.Final.jar:4.1.52.Final]
    at io.netty.util.internal.ThreadExecutorMap$2.run(ThreadExecutorMap.java:74) ~[netty-common-4.1.52.Final.jar:4.1.52.Final]
    at io.netty.util.concurrent.FastThreadLocalRunnable.run(FastThreadLocalRunnable.java:30) ~[netty-common-4.1.52.Final.jar:4.1.52.Final]
    at java.lang.Thread.run(Thread.java:748) ~[na:1.8.0_171]
Caused by: org.jboss.marshalling.Traceinformation: null
"2021-07-01 23:31:11 [StreamThread-1] INFO  c.g.k.d.k.i.ProcessingCompletedEventConsumer.handleEvent - [ ] [727984609591943168] Start: ProcessingCompletedEventConsumer,order removed from location,order Id: 60506491de06423dab695678,kitchenId: 727984609591943168"
"2021-07-01 23:31:11 [sson-netty-2-9] ERROR o.r.c.h.ErrorsLoggingHandler.exceptionCaught - [ ] [] Exception occured. Channel: [id: 0xc2ef16e0,L:/10.8.93.154:39340 - R:grubcenter-prod-redis-cluster.mzv6sx.ng.0001.euw2.cache.amazonaws.com/10.8.72.100:6379]"
io.netty.handler.codec.DecoderException: java.io.OptionalDataException
    at io.netty.handler.codec.ReplayingDecoder.callDecode(ReplayingDecoder.java:421) ~[netty-codec-4.1.52.Final.jar:4.1.52.Final]
    at io.netty.handler.codec.BytetoMessageDecoder.channelRead(BytetoMessageDecoder.java:276) ~[netty-codec-4.1.52.Final.jar:4.1.52.Final]
    at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:379) [netty-transport-4.1.52.Final.jar:4.1.52.Final]
    at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:365) [netty-transport-4.1.52.Final.jar:4.1.52.Final]
    at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:357) [netty-transport-4.1.52.Final.jar:4.1.52.Final]
    at io.netty.channel.DefaultChannelPipeline$HeadContext.channelRead(DefaultChannelPipeline.java:1410) [netty-transport-4.1.52.Final.jar:4.1.52.Final]
    at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:379) [netty-transport-4.1.52.Final.jar:4.1.52.Final]
    at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:365) [netty-transport-4.1.52.Final.jar:4.1.52.Final]
    at io.netty.channel.DefaultChannelPipeline.fireChannelRead(DefaultChannelPipeline.java:919) [netty-transport-4.1.52.Final.jar:4.1.52.Final]
    at io.netty.channel.nio.AbstractNioByteChannel$NioByteUnsafe.read(AbstractNioByteChannel.java:166) [netty-transport-4.1.52.Final.jar:4.1.52.Final]
    at io.netty.channel.nio.NioEventLoop.processSelectedKey(NioEventLoop.java:714) [netty-transport-4.1.52.Final.jar:4.1.52.Final]
    at io.netty.channel.nio.NioEventLoop.processSelectedKeysOptimized(NioEventLoop.java:650) [netty-transport-4.1.52.Final.jar:4.1.52.Final]
    at io.netty.channel.nio.NioEventLoop.processSelectedKeys(NioEventLoop.java:576) [netty-transport-4.1.52.Final.jar:4.1.52.Final]
    at io.netty.channel.nio.NioEventLoop.run(NioEventLoop.java:493) [netty-transport-4.1.52.Final.jar:4.1.52.Final]
    at io.netty.util.concurrent.SingleThreadEventExecutor$4.run(SingleThreadEventExecutor.java:989) [netty-common-4.1.52.Final.jar:4.1.52.Final]
    at io.netty.util.internal.ThreadExecutorMap$2.run(ThreadExecutorMap.java:74) [netty-common-4.1.52.Final.jar:4.1.52.Final]
    at io.netty.util.concurrent.FastThreadLocalRunnable.run(FastThreadLocalRunnable.java:30) [netty-common-4.1.52.Final.jar:4.1.52.Final]
    at java.lang.Thread.run(Thread.java:748) [na:1.8.0_171]
Caused by: java.io.OptionalDataException: null
    at org.jboss.marshalling.Marshalling.createOptionalDataException(Marshalling.java:366) ~[jboss-marshalling-2.0.9.Final.jar:2.0.9.Final]
    at org.jboss.marshalling.river.BlockUnmarshaller.readobject(BlockUnmarshaller.java:147) ~[jboss-marshalling-river-2.0.9.Final.jar:2.0.9.Final]
    at org.jboss.marshalling.river.BlockUnmarshaller.readobject(BlockUnmarshaller.java:135) ~[jboss-marshalling-river-2.0.9.Final.jar:2.0.9.Final]
    at org.jboss.marshalling.MarshallerObjectInputStream.readobjectOverride(MarshallerObjectInputStream.java:53) ~[jboss-marshalling-2.0.9.Final.jar:2.0.9.Final]
    at org.jboss.marshalling.river.RiverObjectInputStream.readobjectOverride(RiverObjectInputStream.java:307) ~[jboss-marshalling-river-2.0.9.Final.jar:2.0.9.Final]
    at java.io.ObjectInputStream.readobject(ObjectInputStream.java:425) ~[na:1.8.0_171]
    at java.util.HashMap.readobject(HashMap.java:1407) ~[na:1.8.0_171]
    at sun.reflect.GeneratedMethodAccessor153.invoke(UnkNown Source) ~[na:na]
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[na:1.8.0_171]
    at java.lang.reflect.Method.invoke(Method.java:498) ~[na:1.8.0_171]
    at org.jboss.marshalling.reflect.JDKSpecific$SerMethods.callReadobject(JDKSpecific.java:186) ~[jboss-marshalling-2.0.9.Final.jar:2.0.9.Final]
    at org.jboss.marshalling.reflect.SerializableClass.callReadobject(SerializableClass.java:214) ~[jboss-marshalling-2.0.9.Final.jar:2.0.9.Final]
    at org.jboss.marshalling.river.RiverUnmarshaller.doInitSerializable(RiverUnmarshaller.java:1757) ~[jboss-marshalling-river-2.0.9.Final.jar:2.0.9.Final]
    at org.jboss.marshalling.river.RiverUnmarshaller.doInitSerializable(RiverUnmarshaller.java:1726) ~[jboss-marshalling-river-2.0.9.Final.jar:2.0.9.Final]
    at org.jboss.marshalling.river.RiverUnmarshaller.doReadNewObject(RiverUnmarshaller.java:1406) ~[jboss-marshalling-river-2.0.9.Final.jar:2.0.9.Final]
    at org.jboss.marshalling.river.RiverUnmarshaller.doReadobject(RiverUnmarshaller.java:283) ~[jboss-marshalling-river-2.0.9.Final.jar:2.0.9.Final]
    at org.jboss.marshalling.river.RiverUnmarshaller.doReadobject(RiverUnmarshaller.java:231) ~[jboss-marshalling-river-2.0.9.Final.jar:2.0.9.Final]
    at org.jboss.marshalling.river.RiverUnmarshaller.readFields(RiverUnmarshaller.java:1864) ~[jboss-marshalling-river-2.0.9.Final.jar:2.0.9.Final]
    at org.jboss.marshalling.river.RiverUnmarshaller.doInitSerializable(RiverUnmarshaller.java:1778) ~[jboss-marshalling-river-2.0.9.Final.jar:2.0.9.Final]
    at org.jboss.marshalling.river.RiverUnmarshaller.doInitSerializable(RiverUnmarshaller.java:1726) ~[jboss-marshalling-river-2.0.9.Final.jar:2.0.9.Final]
    at org.jboss.marshalling.river.RiverUnmarshaller.doReadNewObject(RiverUnmarshaller.java:1406) ~[jboss-marshalling-river-2.0.9.Final.jar:2.0.9.Final]
    at org.jboss.marshalling.river.RiverUnmarshaller.doReadobject(RiverUnmarshaller.java:283) ~[jboss-marshalling-river-2.0.9.Final.jar:2.0.9.Final]
    at org.jboss.marshalling.river.RiverUnmarshaller.doReadobject(RiverUnmarshaller.java:216) ~[jboss-marshalling-river-2.0.9.Final.jar:2.0.9.Final]
    at org.jboss.marshalling.AbstractObjectInput.readobject(AbstractObjectInput.java:41) ~[jboss-marshalling-2.0.9.Final.jar:2.0.9.Final]
    at org.redisson.codec.MarshallingCodec$3.decode(MarshallingCodec.java:157) ~[redisson-3.13.1.jar:3.13.1]
    at org.redisson.client.handler.CommandDecoder.decode(CommandDecoder.java:375) ~[redisson-3.13.1.jar:3.13.1]
    at org.redisson.client.handler.CommandDecoder.decodeCommand(CommandDecoder.java:196) ~[redisson-3.13.1.jar:3.13.1]
    at org.redisson.client.handler.CommandDecoder.decode(CommandDecoder.java:134) ~[redisson-3.13.1.jar:3.13.1]
    at org.redisson.client.handler.CommandDecoder.decode(CommandDecoder.java:104) ~[redisson-3.13.1.jar:3.13.1]
    at io.netty.handler.codec.BytetoMessageDecoder.decodeRemovalReentryProtection(BytetoMessageDecoder.java:501) ~[netty-codec-4.1.52.Final.jar:4.1.52.Final]
    at io.netty.handler.codec.ReplayingDecoder.callDecode(ReplayingDecoder.java:366) ~[netty-codec-4.1.52.Final.jar:4.1.52.Final]
    ... 17 common frames omitted
Caused by: org.jboss.marshalling.Traceinformation: null
"2021-07-01 23:31:11 [sson-netty-2-9] ERROR o.r.c.h.CommandDecoder.decodeCommand - [ ] [] Unable to decode data. channel: [id: 0xc2ef16e0,L:/10.8.93.154:39340 - R:grubcenter-prod-redis-cluster.mzv6sx.ng.0001.euw2.cache.amazonaws.com/10.8.72.100:6379],reply: ReplayingDecoderByteBuf(ridx=37456,widx=37456),command: (HGET),params: [disPATCHER_LOCATION_SNAPSHOTS_MAP,PooledUnsafeDirectByteBuf(ridx: 0,widx: 27,cap: 256)]"
java.io.OptionalDataException: null
    at org.jboss.marshalling.Marshalling.createOptionalDataException(Marshalling.java:366) ~[jboss-marshalling-2.0.9.Final.jar:2.0.9.Final]
    at org.jboss.marshalling.river.BlockUnmarshaller.readobject(BlockUnmarshaller.java:147) ~[jboss-marshalling-river-2.0.9.Final.jar:2.0.9.Final]
    at org.jboss.marshalling.river.BlockUnmarshaller.readobject(BlockUnmarshaller.java:135) ~[jboss-marshalling-river-2.0.9.Final.jar:2.0.9.Final]
    at org.jboss.marshalling.MarshallerObjectInputStream.readobjectOverride(MarshallerObjectInputStream.java:53) ~[jboss-marshalling-2.0.9.Final.jar:2.0.9.Final]
    at org.jboss.marshalling.river.RiverObjectInputStream.readobjectOverride(RiverObjectInputStream.java:307) ~[jboss-marshalling-river-2.0.9.Final.jar:2.0.9.Final]
    at java.io.ObjectInputStream.readobject(ObjectInputStream.java:425) ~[na:1.8.0_171]
    at java.util.HashMap.readobject(HashMap.java:1407) ~[na:1.8.0_171]
    at sun.reflect.GeneratedMethodAccessor153.invoke(UnkNown Source) ~[na:na]
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[na:1.8.0_171]
    at java.lang.reflect.Method.invoke(Method.java:498) ~[na:1.8.0_171]
    at org.jboss.marshalling.reflect.JDKSpecific$SerMethods.callReadobject(JDKSpecific.java:186) ~[jboss-marshalling-2.0.9.Final.jar:2.0.9.Final]
    at org.jboss.marshalling.reflect.SerializableClass.callReadobject(SerializableClass.java:214) ~[jboss-marshalling-2.0.9.Final.jar:2.0.9.Final]
    at org.jboss.marshalling.river.RiverUnmarshaller.doInitSerializable(RiverUnmarshaller.java:1757) ~[jboss-marshalling-river-2.0.9.Final.jar:2.0.9.Final]
    at org.jboss.marshalling.river.RiverUnmarshaller.doInitSerializable(RiverUnmarshaller.java:1726) ~[jboss-marshalling-river-2.0.9.Final.jar:2.0.9.Final]
    at org.jboss.marshalling.river.RiverUnmarshaller.doReadNewObject(RiverUnmarshaller.java:1406) ~[jboss-marshalling-river-2.0.9.Final.jar:2.0.9.Final]
    at org.jboss.marshalling.river.RiverUnmarshaller.doReadobject(RiverUnmarshaller.java:283) ~[jboss-marshalling-river-2.0.9.Final.jar:2.0.9.Final]
    at org.jboss.marshalling.river.RiverUnmarshaller.doReadobject(RiverUnmarshaller.java:231) ~[jboss-marshalling-river-2.0.9.Final.jar:2.0.9.Final]
    at org.jboss.marshalling.river.RiverUnmarshaller.readFields(RiverUnmarshaller.java:1864) ~[jboss-marshalling-river-2.0.9.Final.jar:2.0.9.Final]
    at org.jboss.marshalling.river.RiverUnmarshaller.doInitSerializable(RiverUnmarshaller.java:1778) ~[jboss-marshalling-river-2.0.9.Final.jar:2.0.9.Final]
    at org.jboss.marshalling.river.RiverUnmarshaller.doInitSerializable(RiverUnmarshaller.java:1726) ~[jboss-marshalling-river-2.0.9.Final.jar:2.0.9.Final]
    at org.jboss.marshalling.river.RiverUnmarshaller.doReadNewObject(RiverUnmarshaller.java:1406) ~[jboss-marshalling-river-2.0.9.Final.jar:2.0.9.Final]
    at org.jboss.marshalling.river.RiverUnmarshaller.doReadobject(RiverUnmarshaller.java:283) ~[jboss-marshalling-river-2.0.9.Final.jar:2.0.9.Final]
    at org.jboss.marshalling.river.RiverUnmarshaller.doReadobject(RiverUnmarshaller.java:216) ~[jboss-marshalling-river-2.0.9.Final.jar:2.0.9.Final]
    at org.jboss.marshalling.AbstractObjectInput.readobject(AbstractObjectInput.java:41) ~[jboss-marshalling-2.0.9.Final.jar:2.0.9.Final]
    at org.redisson.codec.MarshallingCodec$3.decode(MarshallingCodec.java:157) ~[redisson-3.13.1.jar:3.13.1]
    at org.redisson.client.handler.CommandDecoder.decode(CommandDecoder.java:375) [redisson-3.13.1.jar:3.13.1]
    at org.redisson.client.handler.CommandDecoder.decodeCommand(CommandDecoder.java:196) [redisson-3.13.1.jar:3.13.1]
    at org.redisson.client.handler.CommandDecoder.decode(CommandDecoder.java:134) [redisson-3.13.1.jar:3.13.1]
    at org.redisson.client.handler.CommandDecoder.decode(CommandDecoder.java:104) [redisson-3.13.1.jar:3.13.1]
    at io.netty.handler.codec.BytetoMessageDecoder.decodeRemovalReentryProtection(BytetoMessageDecoder.java:501) [netty-codec-4.1.52.Final.jar:4.1.52.Final]
    at io.netty.handler.codec.ReplayingDecoder.callDecode(ReplayingDecoder.java:366) [netty-codec-4.1.52.Final.jar:4.1.52.Final]
    at io.netty.handler.codec.BytetoMessageDecoder.channelRead(BytetoMessageDecoder.java:276) [netty-codec-4.1.52.Final.jar:4.1.52.Final]
    at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:379) [netty-transport-4.1.52.Final.jar:4.1.52.Final]
    at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:365) [netty-transport-4.1.52.Final.jar:4.1.52.Final]
    at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:357) [netty-transport-4.1.52.Final.jar:4.1.52.Final]
    at io.netty.channel.DefaultChannelPipeline$HeadContext.channelRead(DefaultChannelPipeline.java:1410) [netty-transport-4.1.52.Final.jar:4.1.52.Final]
    at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:379) [netty-transport-4.1.52.Final.jar:4.1.52.Final]
    at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:365) [netty-transport-4.1.52.Final.jar:4.1.52.Final]
    at io.netty.channel.DefaultChannelPipeline.fireChannelRead(DefaultChannelPipeline.java:919) [netty-transport-4.1.52.Final.jar:4.1.52.Final]
    at io.netty.channel.nio.AbstractNioByteChannel$NioByteUnsafe.read(AbstractNioByteChannel.java:166) [netty-transport-4.1.52.Final.jar:4.1.52.Final]
    at io.netty.channel.nio.NioEventLoop.processSelectedKey(NioEventLoop.java:714) [netty-transport-4.1.52.Final.jar:4.1.52.Final]
    at io.netty.channel.nio.NioEventLoop.processSelectedKeysOptimized(NioEventLoop.java:650) [netty-transport-4.1.52.Final.jar:4.1.52.Final]
    at io.netty.channel.nio.NioEventLoop.processSelectedKeys(NioEventLoop.java:576) [netty-transport-4.1.52.Final.jar:4.1.52.Final]
    at io.netty.channel.nio.NioEventLoop.run(NioEventLoop.java:493) [netty-transport-4.1.52.Final.jar:4.1.52.Final]
    at io.netty.util.concurrent.SingleThreadEventExecutor$4.run(SingleThreadEventExecutor.java:989) [netty-common-4.1.52.Final.jar:4.1.52.Final]
    at io.netty.util.internal.ThreadExecutorMap$2.run(ThreadExecutorMap.java:74) [netty-common-4.1.52.Final.jar:4.1.52.Final]
    at io.netty.util.concurrent.FastThreadLocalRunnable.run(FastThreadLocalRunnable.java:30) [netty-common-4.1.52.Final.jar:4.1.52.Final]
    at java.lang.Thread.run(Thread.java:748) [na:1.8.0_171]
Caused by: org.jboss.marshalling.Traceinformation: null

解决方法

这是一个已知问题 https://developer.jboss.org/thread/280519

私有字段的类型没有实现 Serializable 接口。