Uploaded image for project: 'Red Hat Data Grid'
  1. Red Hat Data Grid
  2. JDG-517

ClientListener stops working after connection failure

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Done
    • Icon: Major Major
    • JDG 7.0.1
    • JDG 7.0.0 GAbacklog
    • HotRod Java client
    • None
    • DR2
    • Hide

      Standalone server and any Java client with a ClientListener wll be sufficient to reproduce.

      1. Put something to observe ClientCacheEntryModifiedEvent properly.
      2. Halt the connection by tcpkill, like sudo tcpkill -i lo host 127.0.0.1 and port 11222.
      3. Do some cache operations to reset the connection pool.
      4. Resume the tcpkill command.
      5. Put something. ClientCacheEntryModifiedEvent is expected but nothing happens actually.
      Show
      Standalone server and any Java client with a ClientListener wll be sufficient to reproduce. Put something to observe ClientCacheEntryModifiedEvent properly. Halt the connection by tcpkill, like sudo tcpkill -i lo host 127.0.0.1 and port 11222 . Do some cache operations to reset the connection pool. Resume the tcpkill command. Put something. ClientCacheEntryModifiedEvent is expected but nothing happens actually.

      After a connection failure to a JDG server, normal operations like get and put recovers to work as expected. But a ClientListener stops working. After registering the listener by cache.addClientListener(listener) again, it recovers to work.

      13:44:02,017 ERROR [org.infinispan.client.hotrod.event.ClientListenerNotifier] (Client-Listener-f021d770522e4595) ISPN004043: Unrecoverable error reading event from server /127.0.0.1:11222, exiting event reader thread: org.infinispan.client.hotrod.exceptions.TransportException:: java.io.IOException: Connection reset by peer
              at org.infinispan.client.hotrod.impl.transport.tcp.TcpTransport.readByte(TcpTransport.java:195) [infinispan-client-hotrod-8.3.0.Final-redhat-1.jar:8.3.0.Final-redhat-1]
              at org.infinispan.client.hotrod.impl.protocol.Codec20.readMagic(Codec20.java:305) [infinispan-client-hotrod-8.3.0.Final-redhat-1.jar:8.3.0.Final-redhat-1]
              at org.infinispan.client.hotrod.impl.protocol.Codec20.readEvent(Codec20.java:147) [infinispan-client-hotrod-8.3.0.Final-redhat-1.jar:8.3.0.Final-redhat-1]
              at org.infinispan.client.hotrod.event.ClientListenerNotifier$EventDispatcher.run(ClientListenerNotifier.java:262) [infinispan-client-hotrod-8.3.0.Final-redhat-1.jar:8.3.0.Final-redhat-1]
              at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) [rt.jar:1.8.0_101]
              at java.util.concurrent.FutureTask.run(FutureTask.java:266) [rt.jar:1.8.0_101]
              at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) [rt.jar:1.8.0_101]
              at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) [rt.jar:1.8.0_101]
              at org.infinispan.client.hotrod.event.ClientListenerNotifier.lambda$null$0(ClientListenerNotifier.java:78) [infinispan-client-hotrod-8.3.0.Final-redhat-1.jar:8.3.0.Final-redhat-1]
              at java.lang.Thread.run(Thread.java:745) [rt.jar:1.8.0_101]
      Caused by: java.io.IOException: Connection reset by peer
              at sun.nio.ch.FileDispatcherImpl.read0(Native Method) [rt.jar:1.8.0_101]
              at sun.nio.ch.SocketDispatcher.read(SocketDispatcher.java:39) [rt.jar:1.8.0_101]
              at sun.nio.ch.IOUtil.readIntoNativeBuffer(IOUtil.java:223) [rt.jar:1.8.0_101]
              at sun.nio.ch.IOUtil.read(IOUtil.java:197) [rt.jar:1.8.0_101]
              at sun.nio.ch.SocketChannelImpl.read(SocketChannelImpl.java:380) [rt.jar:1.8.0_101]
              at sun.nio.ch.SocketAdaptor$SocketInputStream.read(SocketAdaptor.java:206) [rt.jar:1.8.0_101]
              at sun.nio.ch.ChannelInputStream.read(ChannelInputStream.java:103) [rt.jar:1.8.0_101]
              at java.io.BufferedInputStream.fill(BufferedInputStream.java:246) [rt.jar:1.8.0_101]
              at java.io.BufferedInputStream.read(BufferedInputStream.java:265) [rt.jar:1.8.0_101]
              at org.infinispan.client.hotrod.impl.transport.tcp.TcpTransport.readByte(TcpTransport.java:190) [infinispan-client-hotrod-8.3.0.Final-redhat-1.jar:8.3.0.Final-redhat-1]
              ... 9 more
      

            rh-ee-galder Galder ZamarreƱo
            rhn-support-onagano Osamu Nagano
            Votes:
            1 Vote for this issue
            Watchers:
            7 Start watching this issue

              Created:
              Updated:
              Resolved: