4 Replies Latest reply on Jun 12, 2007 6:55 AM by timfox

    ClassCastException when using RoundRobinRouterFactory

    hbentel

      Hi

      I've got JBM 1.2.0.sp1 running in JBoss AS 4.2.0.CR2
      I've setup a 2-node cluster and all the JBM examples runs fine, including the cluster ones.

      Now I'm trying to set up round robin routing using the instructions at
      http://labs.jboss.com/file-access/default/members/jbossmessaging/freezone/docs/userguide-1.2.0.GA/html/c_configuration.html#clusterrouter

      But when the server starts up I get a ClassCastException (stacktrace below)
      The only configuration I changed to enable round robin was setting the ClusterRouterFactory attribute for the ClusteredPostOfficeService, per the instructions.

      I'm guess I'm missing some configuration.

      hope someone can help



      -------------------------------------------------------
      GMS: address is 127.0.0.1:33066
      -------------------------------------------------------
      18:16:14,409 INFO [DefaultClusteredPostOffice] ClusteredPostOffice[0:Clustered JMS:127.0.0.1:33066] got new view [127.0.0.1:33066|0] [127.0.0.1:33066]
      18:16:14,432 INFO [STDOUT]
      -------------------------------------------------------
      GMS: address is 127.0.0.1:33068
      -------------------------------------------------------
      18:16:16,515 ERROR [ExceptionUtil] org.jboss.messaging.core.plugin.ClusteredPostOfficeService@ddc581 startService
      java.lang.ClassCastException: org.jboss.messaging.core.local.PagingFilteredQueue
      at org.jboss.messaging.core.plugin.postoffice.cluster.RoundRobinRouter.add(RoundRobinRouter.java:167)
      at org.jboss.messaging.core.plugin.postoffice.cluster.RoundRobinRouter.add(RoundRobinRouter.java:121)
      at org.jboss.messaging.core.plugin.postoffice.cluster.DefaultClusteredPostOffice.addToConditionMap(DefaultClusteredPostOffice.java:1493)
      at org.jboss.messaging.core.plugin.postoffice.DefaultPostOffice.addBinding(DefaultPostOffice.java:765)
      at org.jboss.messaging.core.plugin.postoffice.DefaultPostOffice.loadBindings(DefaultPostOffice.java:619)
      at org.jboss.messaging.core.plugin.postoffice.cluster.DefaultClusteredPostOffice.loadBindings(DefaultClusteredPostOffice.java:1551)
      at org.jboss.messaging.core.plugin.postoffice.DefaultPostOffice.start(DefaultPostOffice.java:141)
      at org.jboss.messaging.core.plugin.postoffice.cluster.DefaultClusteredPostOffice.start(DefaultClusteredPostOffice.java:322)
      at org.jboss.messaging.core.plugin.ClusteredPostOfficeService.startService(ClusteredPostOfficeService.java:446)
      ..
      ..
      ..