lettuce icon indicating copy to clipboard operation
lettuce copied to clipboard

io.lettuce.core.protocol.RedisProtocolException: Invalid first byte: 57 (9) at buffer index 56910 decoding using RESP3

Open puneet1992 opened this issue 2 years ago • 5 comments

Getting the above error with lettuce 6.3.0.RELEASE. here is the complete stack trace.

Connection failed to Redis pubsub node RedisNode(host=antelope-rtm-load-cluster.2ouka2.clustercfg.use1.cache.amazonaws.com, port=6379, password=, isSSLEnabled=false) 
io.lettuce.core.protocol.RedisProtocolException: Invalid first byte: 57 (9) at buffer index 56910 decoding using RESP3
	at io.lettuce.core.protocol.RedisStateMachine.readReplyType(RedisStateMachine.java:612)
	at io.lettuce.core.protocol.RedisStateMachine.doDecode(RedisStateMachine.java:330)
	at io.lettuce.core.protocol.RedisStateMachine.decode(RedisStateMachine.java:300)
	at io.lettuce.core.protocol.CommandHandler.decode0(CommandHandler.java:813)
	at io.lettuce.core.protocol.CommandHandler.decode(CommandHandler.java:786)
	at io.lettuce.core.protocol.CommandHandler.decode(CommandHandler.java:630)
	at io.lettuce.core.pubsub.PubSubCommandHandler.decode(PubSubCommandHandler.java:112)
	at io.lettuce.core.protocol.CommandHandler.channelRead(CommandHandler.java:597)
	at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:379)
	at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:365)
	at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:357)
	at io.netty.channel.DefaultChannelPipeline$HeadContext.channelRead(DefaultChannelPipeline.java:1410)
	at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:379)
	at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:365)
	at io.netty.channel.DefaultChannelPipeline.fireChannelRead(DefaultChannelPipeline.java:919)
	at io.netty.channel.epoll.AbstractEpollStreamChannel$EpollStreamUnsafe.epollInReady(AbstractEpollStreamChannel.java:795)
	at io.netty.channel.epoll.EpollEventLoop.processReady(EpollEventLoop.java:475)
	at io.netty.channel.epoll.EpollEventLoop.run(EpollEventLoop.java:378)
	at io.netty.util.concurrent.SingleThreadEventExecutor$4.run(SingleThreadEventExecutor.java:989)
	at io.netty.util.internal.ThreadExecutorMap$2.run(ThreadExecutorMap.java:74)
	at io.netty.util.concurrent.FastThreadLocalRunnable.run(FastThreadLocalRunnable.java:30)
	at java.base/java.lang.Thread.run(Thread.java:832)

Environment Lettuce version(s): 6.3.0.RELEASE Redis version: Redis 7.1.0

puneet1992 avatar Jan 10 '24 05:01 puneet1992

@mp911de Is it possible for you to provide some inputs here?

puneet1992 avatar Jan 10 '24 05:01 puneet1992

Without context, a wire trace or a way to reproduce, I'm not able to diagnose what's going on.

mp911de avatar Jan 10 '24 08:01 mp911de

I am facing similar issue . Error message is the same as this https://github.com/redis/lettuce/issues/1796.

I am using several microservices. Each one validates requests through bearer token . Redis and Lettuce is used in User-Service , for saving and fetching renew token for a user . As , this issue is not regular, we get this once in a while, So even I don't know how to regenerate this issue. I am guessing this maybe because of high amount of requests .

Please let me know how to solve this

zulker01 avatar Jan 11 '24 05:01 zulker01

@mp911de We are using Redis pubsub (aws elasticate nodes with cluster mode disabled) for publishing/subscribing. now we are trying to move to the cluster mode enabled one to achieve default autoscaling provided by AWS. the cluster is going into a modifying state we are getting the above errors. currently, i'm using lettuce 6.3.0 RELEASE for this testing.

puneet1992 avatar Jan 11 '24 05:01 puneet1992

Please let me know how to solve this

https://github.com/lettuce-io/lettuce-core/issues/2585#issuecomment-1884374064

mp911de avatar Jan 11 '24 10:01 mp911de

If you would like us to look at this issue, please provide the requested information. If the information is not provided within the next 30 days this issue will be closed.

github-actions[bot] avatar Feb 18 '25 00:02 github-actions[bot]