Uploaded image for project: 'Infinispan'
  1. Infinispan
  2. ISPN-702

RankCalculatorListener registered to late

    Details

      Description

      Any call to HotRod Server v. 4.2.0.ALPHA3 ends with the exception:

      2010-10-14 17:39:36,953 ERROR [org.infinispan.server.core.AbstractProtocolDecoder$] (HotRodServerWorker-1-22) Exception reported
      org.infinispan.server.core.ServerException: java.lang.IllegalStateException: If clustered, Version prefix cannot be 0. Rank calculator probably not in use.
      at org.infinispan.server.core.AbstractProtocolDecoder.decode(AbstractProtocolDecoder.scala:53)
      at org.infinispan.server.core.transport.netty.DecoderAdapter.decode(DecoderAdapter.scala:18)
      at org.infinispan.server.core.transport.netty.DecoderAdapter.decode(DecoderAdapter.scala:14)
      at org.jboss.netty.handler.codec.replay.ReplayingDecoder.callDecode(ReplayingDecoder.java:471)
      at org.jboss.netty.handler.codec.replay.ReplayingDecoder.messageReceived(ReplayingDecoder.java:444)
      at org.jboss.netty.channel.Channels.fireMessageReceived(Channels.java:274)
      at org.jboss.netty.channel.Channels.fireMessageReceived(Channels.java:261)
      at org.jboss.netty.channel.socket.nio.NioWorker.read(NioWorker.java:350)
      at org.jboss.netty.channel.socket.nio.NioWorker.processSelectedKeys(NioWorker.java:281)
      at org.jboss.netty.channel.socket.nio.NioWorker.run(NioWorker.java:201)
      at org.jboss.netty.util.internal.IoWorkerRunnable.run(IoWorkerRunnable.java:46)
      at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
      at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)

      The reason is that RankCalculatorListener is registered to late - in org.infinispan.server.core.start() method, which is called at the end of overriding org.infinispan.server.hotrod.HotRodServer.start(), which in turn starts all the defined caches.
      Maybe there is a need for adding a new lifecycle method to ProtocolServer - create(). Like in JMX services.

        Gliffy Diagrams

          Attachments

            Issue Links

              Activity

                People

                • Assignee:
                  galder.zamarreno Galder ZamarreƱo
                  Reporter:
                  gerbszt Jacek Gerbszt
                • Votes:
                  0 Vote for this issue
                  Watchers:
                  0 Start watching this issue

                  Dates

                  • Created:
                    Updated:
                    Resolved: