Uploaded image for project: 'JGroups'
  1. JGroups
  2. JGRP-666

The thread is blocked when join the group.

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Won't Do
    • Icon: Major Major
    • 2.7
    • 2.6.1
    • None
    • Windox XP Sun JDK 1.5 ; Jgroup 2.6.1

    • High

      Run this test case in three window that we can all them as A, B, C. after starting all these tree, then stop C first and resart it quickly, then B, and A.

      public class TestJoin {

      public static final String DEFAULT_PROTOCOL_STACK=
      "UDP(mcast_addr=228.8.8.8;mcast_port=45566;ip_ttl=32;mcast_send_buf_size=150000;" +
      "mcast_recv_buf_size=80000):" +
      "PING(timeout=2000;num_initial_members=2):MERGE2(min_interval=5000;max_interval=10000):" +
      "FD_SOCK:" +
      "FD(timeout=10000;max_tries=5;shun=true):" +
      "VERIFY_SUSPECT(timeout=12500):" +
      "pbcast.NAKACK(gc_lag=50;retransmit_timeout=300,600,1200,2400,4800;max_xmit_size=8192):" +
      "UNICAST(timeout=300,600,1200,2400):pbcast.STABLE(desired_avg_gossip=20000):" +
      "FRAG(frag_size=8096;down_thread=false;up_thread=false):" +
      "pbcast.GMS(join_timeout=5000;join_retry_timeout=2000;shun=false;print_local_addr=false)";

      public static void main(String[] args)
      {
      NotificationBus bus;
      try

      { bus = new NotificationBus ( "test", DEFAULT_PROTOCOL_STACK ); bus.getChannel ().setOpt ( Channel.LOCAL, Boolean.FALSE ); bus.start (); }

      catch (Exception e)

      { // TODO Auto-generated catch block e.printStackTrace(); }

      while(true)
      {
      System.out.println("******************************************");
      try

      { Thread.sleep(5000); }

      catch (InterruptedException e)

      { // TODO Auto-generated catch block e.printStackTrace(); }

      }
      }
      }

      And after that, the A and B will be blocked for joining the group. here is hte console output:
      (it should join the group and output the ****************)

      2008-1-18 10:49:15 org.jgroups.JChannel init
      Info: JGroups version: 2.6.1
      2008-1-18 10:49:16 org.jgroups.protocols.pbcast.NAKACK setProperties
      Warn: max_xmit_size was deprecated in 2.6 and will be ignored
      2008-1-18 10:49:16 org.jgroups.stack.Protocol setPropertiesInternal
      Warn: down_thread was deprecated and is ignored
      2008-1-18 10:49:16 org.jgroups.stack.Protocol setPropertiesInternal
      Warn: up_thread was deprecated and is ignored
      2008-1-18 10:49:16 org.jgroups.protocols.pbcast.GMS setProperties
      Warn: join_retry_timeout has been deprecated and its value will be ignored
      2008-1-18 10:49:21 org.jgroups.protocols.pbcast.ClientGmsImpl join
      Warn: join(10.70.148.165:1371) sent to 10.70.148.165:1350 timed out (after 5000 ms), retrying
      2008-1-18 10:49:26 org.jgroups.protocols.pbcast.ClientGmsImpl join
      Warn: join(10.70.148.165:1371) sent to 10.70.148.165:1350 timed out (after 5000 ms), retrying
      2008-1-18 10:49:31 org.jgroups.protocols.pbcast.ClientGmsImpl join
      Warn: join(10.70.148.165:1371) sent to 10.70.148.165:1350 timed out (after 5000 ms), retrying
      2008-1-18 10:49:36 org.jgroups.protocols.pbcast.ClientGmsImpl join
      Warn: join(10.70.148.165:1371) sent to 10.70.148.165:1350 timed out (after 5000 ms), retrying
      2008-1-18 10:49:41 org.jgroups.protocols.pbcast.ClientGmsImpl join
      Warn: join(10.70.148.165:1371) sent to 10.70.148.165:1350 timed out (after 5000 ms), retrying
      2008-1-18 10:49:46 org.jgroups.protocols.pbcast.ClientGmsImpl join
      Warn: join(10.70.148.165:1371) sent to 10.70.148.165:1350 timed out (after 5000 ms), retrying

      I have used Jgroups 2.2.9, and the same problem happened (different console output with more message trace information.).

        1. TestJoin.java
          0.9 kB
          Vladimir Blagojevic
        2. udp.xml
          3 kB
          Vladimir Blagojevic

              rhn-engineering-bban Bela Ban
              legacy_external_user Legacy User (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

                Created:
                Updated:
                Resolved: