1 Reply Latest reply on Jan 16, 2007 8:43 PM by Brian Stansberry

    Ditributed Queue using ClusteredPostOfficeService

    Srikanth varanasi Newbie

      When i run my client on one of the instances in a cluster which posts more than 1000 messages, the instance where i am running the client going fine in processing them and the other instances in the cluster throw me up the stack trace as below:

      Can somebody advise where i am going wrong or where i need to make changes in config files.

      2007-01-15 17:30:49,311 ERROR [org.jboss.messaging.core.plugin.postoffice.cluster.DefaultClusteredPostOffice] Caught Exception in Receiver
      java.lang.IllegalStateException: Received stats from node with id that matches this nodes id. You may have started two or more nodes with the same node id!
      at org.jboss.messaging.core.plugin.postoffice.cluster.DefaultClusteredPostOffice.updateQueueStats(DefaultClusteredPostOffice.java:894)
      at org.jboss.messaging.core.plugin.postoffice.cluster.QueueStatsRequest.execute(QueueStatsRequest.java:61)
      at org.jboss.messaging.core.plugin.postoffice.cluster.DefaultClusteredPostOffice$DataReceiver.receive(DefaultClusteredPostOffice.java:2494)
      at org.jgroups.JChannel.up(JChannel.java:1102)
      at org.jgroups.stack.ProtocolStack.up(ProtocolStack.java:377)
      at org.jgroups.stack.ProtocolStack.receiveUpEvent(ProtocolStack.java:393)
      at org.jgroups.stack.Protocol.passUp(Protocol.java:538)
      at org.jgroups.protocols.pbcast.GMS.up(GMS.java:751)
      at org.jgroups.stack.Protocol.receiveUpEvent(Protocol.java:488)
      at org.jgroups.protocols.pbcast.GMS.receiveUpEvent(GMS.java:771)
      at org.jgroups.stack.Protocol.passUp(Protocol.java:538)
      at org.jgroups.protocols.VIEW_SYNC.up(VIEW_SYNC.java:154)
      at org.jgroups.stack.Protocol.receiveUpEvent(Protocol.java:488)
      at org.jgroups.stack.Protocol.passUp(Protocol.java:538)
      at org.jgroups.protocols.FRAG.up(FRAG.java:168)
      at org.jgroups.stack.Protocol.receiveUpEvent(Protocol.java:488)
      at org.jgroups.stack.Protocol.passUp(Protocol.java:538)
      at org.jgroups.protocols.pbcast.STABLE.up(STABLE.java:258)
      at org.jgroups.stack.Protocol.receiveUpEvent(Protocol.java:488)
      at org.jgroups.stack.Protocol.passUp(Protocol.java:538)
      at org.jgroups.protocols.UNICAST.up(UNICAST.java:223)
      at org.jgroups.stack.Protocol.receiveUpEvent(Protocol.java:488)
      at org.jgroups.stack.Protocol.passUp(Protocol.java:538)
      at org.jgroups.protocols.pbcast.NAKACK.handleMessage(NAKACK.java:685)
      at org.jgroups.protocols.pbcast.NAKACK.up(NAKACK.java:517)
      at org.jgroups.stack.Protocol.receiveUpEvent(Protocol.java:488)
      at org.jgroups.stack.Protocol.passUp(Protocol.java:538)
      at org.jgroups.protocols.VERIFY_SUSPECT.up(VERIFY_SUSPECT.java:170)
      at org.jgroups.stack.Protocol.receiveUpEvent(Protocol.java:488)
      at org.jgroups.stack.Protocol.passUp(Protocol.java:538)
      at org.jgroups.protocols.FD.up(FD.java:274)
      at org.jgroups.stack.Protocol.receiveUpEvent(Protocol.java:488)
      at org.jgroups.stack.Protocol.passUp(Protocol.java:538)
      at org.jgroups.protocols.MERGE2.up(MERGE2.java:162)
      at org.jgroups.stack.Protocol.receiveUpEvent(Protocol.java:488)
      at org.jgroups.stack.Protocol.passUp(Protocol.java:538)
      at org.jgroups.protocols.Discovery.up(Discovery.java:225)
      at org.jgroups.stack.Protocol.receiveUpEvent(Protocol.java:488)
      at org.jgroups.stack.Protocol.passUp(Protocol.java:538)
      at org.jgroups.stack.Protocol.up(Protocol.java:565)
      at org.jgroups.stack.Protocol.receiveUpEvent(Protocol.java:488)
      at org.jgroups.stack.Protocol.passUp(Protocol.java:538)
      at org.jgroups.protocols.TP.handleIncomingMessage(TP.java:908)
      at org.jgroups.protocols.TP.handleIncomingPacket(TP.java:850)
      at org.jgroups.protocols.TP.receive(TP.java:780)
      at org.jgroups.protocols.UDP.run(UDP.java:261)
      at java.lang.Thread.run(Thread.java:534)
      2007-01-15 17:30:49,311 ERROR [org.jgroups.protocols.UDP] failed unmarshalling message
      java.lang.IllegalStateException: Received stats from node with id that matches this nodes id. You may have started two or more nodes with the same node id!
      at org.jboss.messaging.core.plugin.postoffice.cluster.DefaultClusteredPostOffice.updateQueueStats(DefaultClusteredPostOffice.java:894)
      at org.jboss.messaging.core.plugin.postoffice.cluster.QueueStatsRequest.execute(QueueStatsRequest.java:61)
      at org.jboss.messaging.core.plugin.postoffice.cluster.DefaultClusteredPostOffice$DataReceiver.receive(DefaultClusteredPostOffice.java:2494)
      at org.jgroups.JChannel.up(JChannel.java:1102)
      at org.jgroups.stack.ProtocolStack.up(ProtocolStack.java:377)
      at org.jgroups.stack.ProtocolStack.receiveUpEvent(ProtocolStack.java:393)
      at org.jgroups.stack.Protocol.passUp(Protocol.java:538)
      at org.jgroups.protocols.pbcast.GMS.up(GMS.java:751)
      at org.jgroups.stack.Protocol.receiveUpEvent(Protocol.java:488)
      at org.jgroups.protocols.pbcast.GMS.receiveUpEvent(GMS.java:771)
      at org.jgroups.stack.Protocol.passUp(Protocol.java:538)
      at org.jgroups.protocols.VIEW_SYNC.up(VIEW_SYNC.java:154)
      at org.jgroups.stack.Protocol.receiveUpEvent(Protocol.java:488)
      at org.jgroups.stack.Protocol.passUp(Protocol.java:538)
      at org.jgroups.protocols.FRAG.up(FRAG.java:168)
      at org.jgroups.stack.Protocol.receiveUpEvent(Protocol.java:488)
      at org.jgroups.stack.Protocol.passUp(Protocol.java:538)
      at org.jgroups.protocols.pbcast.STABLE.up(STABLE.java:258)
      at org.jgroups.stack.Protocol.receiveUpEvent(Protocol.java:488)
      at org.jgroups.stack.Protocol.passUp(Protocol.java:538)
      at org.jgroups.protocols.UNICAST.up(UNICAST.java:223)
      at org.jgroups.stack.Protocol.receiveUpEvent(Protocol.java:488)
      at org.jgroups.stack.Protocol.passUp(Protocol.java:538)
      at org.jgroups.protocols.pbcast.NAKACK.handleMessage(NAKACK.java:685)
      at org.jgroups.protocols.pbcast.NAKACK.up(NAKACK.java:517)
      at org.jgroups.stack.Protocol.receiveUpEvent(Protocol.java:488)
      at org.jgroups.stack.Protocol.passUp(Protocol.java:538)
      at org.jgroups.protocols.VERIFY_SUSPECT.up(VERIFY_SUSPECT.java:170)
      at org.jgroups.stack.Protocol.receiveUpEvent(Protocol.java:488)
      at org.jgroups.stack.Protocol.passUp(Protocol.java:538)
      at org.jgroups.protocols.FD.up(FD.java:274)
      at org.jgroups.stack.Protocol.receiveUpEvent(Protocol.java:488)
      at org.jgroups.stack.Protocol.passUp(Protocol.java:538)
      at org.jgroups.protocols.MERGE2.up(MERGE2.java:162)
      at org.jgroups.stack.Protocol.receiveUpEvent(Protocol.java:488)
      at org.jgroups.stack.Protocol.passUp(Protocol.java:538)
      at org.jgroups.protocols.Discovery.up(Discovery.java:225)
      at org.jgroups.stack.Protocol.receiveUpEvent(Protocol.java:488)
      at org.jgroups.stack.Protocol.passUp(Protocol.java:538)
      at org.jgroups.stack.Protocol.up(Protocol.java:565)
      at org.jgroups.stack.Protocol.receiveUpEvent(Protocol.java:488)
      at org.jgroups.stack.Protocol.passUp(Protocol.java:538)
      at org.jgroups.protocols.TP.handleIncomingMessage(TP.java:908)
      at org.jgroups.protocols.TP.handleIncomingPacket(TP.java:850)
      at org.jgroups.protocols.TP.receive(TP.java:780)
      at org.jgroups.protocols.UDP.run(UDP.java:261)
      at java.lang.Thread.run(Thread.java:534)

      My JGroups configuration in cluster-service.xml is configured as below:


      <!--
      The default UDP stack:
      - If you have a multihomed machine, set the UDP protocol's bind_addr attribute to the
      appropriate NIC IP address, e.g bind_addr="192.168.0.2".
      - On Windows machines, because of the media sense feature being broken with multicast
      (even after disabling media sense) set the UDP protocol's loopback attribute to true
      -->

      <UDP mcast_addr="228.1.2.3" mcast_port="45566"
      ip_ttl="8" ip_mcast="true"
      mcast_recv_buf_size="150000" mcast_send_buf_size="800000"
      ucast_recv_buf_size="150000" ucast_send_buf_size="800000"
      loopback="false"/>
      <PING timeout="2000" num_initial_members="3"
      up_thread="true" down_thread="true"/>
      <MERGE2 min_interval="10000" max_interval="20000"/>
      <!-- <FD_SOCK down_thread="true" up_thread="true"/> -->
      <FD shun="true" up_thread="true" down_thread="true"
      timeout="10000" max_tries="5"/>
      <VERIFY_SUSPECT timeout="3000" num_msgs="3"
      up_thread="true" down_thread="true"/>
      <pbcast.NAKACK gc_lag="50" retransmit_timeout="300,600,1200,2400,4800"
      max_xmit_size="8192"
      up_thread="true" down_thread="true"/>
      <UNICAST timeout="300,600,1200,2400,4800" window_size="100" min_threshold="10"
      down_thread="true"/>
      <pbcast.STABLE desired_avg_gossip="20000" max_bytes="400000"
      up_thread="true" down_thread="true"/>
      <FRAG frag_size="8192"
      down_thread="true" up_thread="true"/>
      <pbcast.GMS join_timeout="5000" join_retry_timeout="2000"
      shun="true" print_local_addr="true"/>
      <pbcast.STATE_TRANSFER up_thread="true" down_thread="true"/>


      I am using ClusteredPostOfficeservice and the configuration is defined in mysql-persistance-service.xml


      <mbean code="org.jboss.messaging.core.plugin.ClusteredPostOfficeService"
      name="jboss.messaging:service=PostOffice"
      xmbean-dd="xmdesc/ClusteredPostOffice-xmbean.xml">
      <depends optional-attribute-name="ServerPeer">jboss.messaging:service=ServerPeer
      jboss.jca:service=DataSourceBinding,name=MySqlDS
      <depends optional-attribute-name="TransactionManager">jboss:service=TransactionManager
      Clustered Queue
      MySqlDS
      true