[
https://issues.apache.org/jira/browse/CAMEL-15615?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17210810#comment-17210810
]
Andrea Cosentino commented on CAMEL-15615:
------------------------------------------
This turns out to be related to the encoding of the cache. It's important to
define the encoding on the cache configuration, otherwise we'll need this
Warning. We need to add some documentation about this. So I'll leave this open.
> Camel-Infinispan: Cannot consume events
> ----------------------------------------
>
> Key: CAMEL-15615
> URL: https://issues.apache.org/jira/browse/CAMEL-15615
> Project: Camel
> Issue Type: Bug
> Components: camel-infinispan
> Reporter: Andrea Cosentino
> Assignee: Andrea Cosentino
> Priority: Major
> Fix For: 3.6.0
>
>
> If you try to run a simple route like this one:
> {code:java}
> from("infinispan://mycache?hosts=localhost&sync=false&eventTypes=CACHE_ENTRY_CREATED")
>
> from("infinispan://mycache?hosts=localhost&sync=false&eventTypes=CACHE_ENTRY_CREATED")
> .log("Header ${header.CamelInfinispanEventType}");
> {code}
> This will fail with the following WARN
> {code:java}
> 2020-10-01 20:39:06,042 [-async-pool-1-2] WARN HeaderDecoder
> - ISPN004039: Unable to complete reading event from server
> 127.0.0.1/127.0.0.1:112222020-10-01 20:39:06,042 [-async-pool-1-2] WARN
> HeaderDecoder - ISPN004039: Unable to complete reading event
> from server
> 127.0.0.1/127.0.0.1:11222org.infinispan.client.hotrod.exceptions.HotRodClientException:
> ISPN004034: Unable to unmarshall bytes 636F6170 at
> org.infinispan.client.hotrod.marshall.MarshallerUtil.bytes2obj(MarshallerUtil.java:72)
> ~[infinispan-client-hotrod-11.0.3.Final.jar:11.0.3.Final] at
> org.infinispan.client.hotrod.DataFormat.keyToObj(DataFormat.java:103)
> ~[infinispan-client-hotrod-11.0.3.Final.jar:11.0.3.Final] at
> org.infinispan.client.hotrod.impl.protocol.Codec21.readCacheEvent(Codec21.java:78)
> ~[infinispan-client-hotrod-11.0.3.Final.jar:11.0.3.Final] at
> org.infinispan.client.hotrod.impl.transport.netty.HeaderDecoder.decode(HeaderDecoder.java:156)
> [infinispan-client-hotrod-11.0.3.Final.jar:11.0.3.Final] at
> org.infinispan.client.hotrod.impl.transport.netty.HintedReplayingDecoder.callDecode(HintedReplayingDecoder.java:94)
> [infinispan-client-hotrod-11.0.3.Final.jar:11.0.3.Final] at
> io.netty.handler.codec.ByteToMessageDecoder.channelRead(ByteToMessageDecoder.java:276)
> [netty-codec-4.1.51.Final.jar:4.1.51.Final] at
> io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:379)
> [netty-transport-4.1.51.Final.jar:4.1.51.Final] at
> io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:365)
> [netty-transport-4.1.51.Final.jar:4.1.51.Final] at
> io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:357)
> [netty-transport-4.1.51.Final.jar:4.1.51.Final] at
> io.netty.handler.timeout.IdleStateHandler.channelRead(IdleStateHandler.java:286)
> [netty-handler-4.1.51.Final.jar:4.1.51.Final] at
> io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:379)
> [netty-transport-4.1.51.Final.jar:4.1.51.Final] at
> io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:365)
> [netty-transport-4.1.51.Final.jar:4.1.51.Final] at
> io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:357)
> [netty-transport-4.1.51.Final.jar:4.1.51.Final] at
> io.netty.channel.DefaultChannelPipeline$HeadContext.channelRead(DefaultChannelPipeline.java:1410)
> [netty-transport-4.1.51.Final.jar:4.1.51.Final] at
> io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:379)
> [netty-transport-4.1.51.Final.jar:4.1.51.Final] at
> io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:365)
> [netty-transport-4.1.51.Final.jar:4.1.51.Final] at
> io.netty.channel.DefaultChannelPipeline.fireChannelRead(DefaultChannelPipeline.java:919)
> [netty-transport-4.1.51.Final.jar:4.1.51.Final] at
> io.netty.channel.epoll.AbstractEpollStreamChannel$EpollStreamUnsafe.epollInReady(AbstractEpollStreamChannel.java:792)
> [netty-transport-native-epoll-4.1.51.Final-linux-x86_64.jar:4.1.51.Final] at
> io.netty.channel.epoll.EpollEventLoop.processReady(EpollEventLoop.java:475)
> [netty-transport-native-epoll-4.1.51.Final-linux-x86_64.jar:4.1.51.Final] at
> io.netty.channel.epoll.EpollEventLoop.run(EpollEventLoop.java:378)
> [netty-transport-native-epoll-4.1.51.Final-linux-x86_64.jar:4.1.51.Final] at
> io.netty.util.concurrent.SingleThreadEventExecutor$4.run(SingleThreadEventExecutor.java:989)
> [netty-common-4.1.51.Final.jar:4.1.51.Final] at
> io.netty.util.internal.ThreadExecutorMap$2.run(ThreadExecutorMap.java:74)
> [netty-common-4.1.51.Final.jar:4.1.51.Final] at
> java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
> [?:1.8.0_252] at
> java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
> [?:1.8.0_252] at java.lang.Thread.run(Thread.java:748) [?:1.8.0_252]Caused
> by: java.lang.IllegalStateException: Unexpected tag : 99 (Field number : 12,
> Wire type : 3) at
> org.infinispan.protostream.WrappedMessage.readMessage(WrappedMessage.java:364)
> ~[protostream-4.3.3.Final.jar:?] at
> org.infinispan.protostream.ProtobufUtil.fromWrappedByteArray(ProtobufUtil.java:161)
> ~[protostream-4.3.3.Final.jar:?] at
> org.infinispan.commons.marshall.ProtoStreamMarshaller.objectFromByteBuffer(ProtoStreamMarshaller.java:45)
> ~[infinispan-commons-11.0.3.Final.jar:11.0.3.Final] at
> org.infinispan.commons.marshall.AbstractMarshaller.objectFromByteBuffer(AbstractMarshaller.java:82)
> ~[infinispan-commons-11.0.3.Final.jar:11.0.3.Final] at
> org.infinispan.client.hotrod.marshall.MarshallerUtil.bytes2obj(MarshallerUtil.java:56)
> ~[infinispan-client-hotrod-11.0.3.Final.jar:11.0.3.Final] ... 24 more
> {code}
--
This message was sent by Atlassian Jira
(v8.3.4#803005)