Package org.jgroups.protocols.pbcast

Examples of org.jgroups.protocols.pbcast.GMS$GmsHeader


          new VERIFY_SUSPECT(),
          new BARRIER(),
          new NAKACK2(),
          new UNICAST3(),
          new STABLE(),
          new GMS(),
          new UFC(),
          new MFC(),
          new FRAG2()};
        JChannel ch=new JChannel(prot_stack).name(args[0]);
View Full Code Here


        System.out.println(" -- "+ msg);
    }

    private static void modifyStack(JChannel ch) {
        ProtocolStack stack=ch.getProtocolStack();
        GMS gms=(GMS)stack.findProtocol(GMS.class);
        if(gms != null)
            gms.setLogCollectMessages(false);
    }
View Full Code Here

                                 new SHARED_LOOPBACK_PING(),
                                 new FD(),
                                 new NAKACK2().setValue("use_mcast_xmit", false),
                                 new UNICAST3(),
                                 new STABLE().setValue("max_bytes", 50000),
                                 new GMS().setValue("print_local_addr", false),
                                 new SUPERVISOR());
        ch.setName(name);
        return ch;
    }
View Full Code Here

         channel.connect(GROUP);

         System.out.println("shutting down the participant channel");
         Util.shutdown(channel);

         GMS coord_gms=(GMS)coordinator.getProtocolStack().findProtocol(GMS.class);
         if(coord_gms != null)
             coord_gms.setLevel("trace");

         View view;
         long end_time=System.currentTimeMillis() + 20000;
         while(System.currentTimeMillis() < end_time) {
             view=coordinator.getView();
             if(view.size() == 1)
                 break;
             Util.sleep(500);
         }
         view=coordinator.getView();
         assert view.size() == 1 : "coordinator's view is " + view + ", but we expected a view of 1 member";
         if(coord_gms != null)
             coord_gms.setLevel("warn");
     }
View Full Code Here

        List<Protocol> protocols=new ArrayList<Protocol>();
        protocols.addAll(Arrays.asList(tunnel, new PING(), new MERGE3().setValue("min_interval", 1000).setValue("max_interval", 3000)));
        if(include_failure_detection)
            protocols.addAll(Arrays.asList(new FD().setValue("timeout", 2000).setValue("max_tries", 2), new VERIFY_SUSPECT()));
        protocols.addAll(Arrays.asList(new NAKACK2().setValue("use_mcast_xmit", false), new UNICAST3(), new STABLE(),
                                       new GMS().joinTimeout(1000)));
        JChannel ch=new JChannel(protocols);
        if(name != null)
            ch.setName(name);
        return ch;
    }
View Full Code Here

        ch=new JChannel(new SHARED_LOOPBACK().setValue("thread_pool_rejection_policy", "run"),
                        new SHARED_LOOPBACK_PING(),
                        new NAKACK2().setValue("use_mcast_xmit", false),
                        new UNICAST3(),
                        new STABLE().setValue("max_bytes", 50000),
                        new GMS().setValue("print_local_addr", false),
                        flow_control_prot,
                        new FRAG2().fragSize(800));
        ch.connect("FCTest");
    }
View Full Code Here

                new SHARED_LOOPBACK_PING(),
                new MERGE3(),
                new NAKACK2(),
                new UNICAST3(),
                new TOA(),
                new GMS()
        }).name(name);
        TOANode toaNode = new TOANode(channel);
        registeredToaNodes.add(toaNode);
        return toaNode;
    }
View Full Code Here

                                 new NAKACK2().setValue("use_mcast_xmit",false)
                                   .setValue("log_discard_msgs",false).setValue("log_not_found_msgs",false),
                                 new UNICAST3(),
                                 new STABLE().setValue("max_bytes",50000),
                                 new SEQUENCER(), // below GMS, to establish total order between views and messages
                                 new GMS().setValue("print_local_addr",false).setValue("join_timeout", 100).setValue("leave_timeout",100)
                                   .setValue("log_view_warnings",false).setValue("view_ack_collection_timeout",50)
                                   .setValue("log_collect_msgs",false));
        ch.setName(name);
        return ch;
    }
View Full Code Here

        return ch;
    }

    protected static void injectViewAndDigest(View view, Digest digest, JChannel ... channels) {
        for(JChannel ch: channels) {
            GMS gms=(GMS)ch.getProtocolStack().findProtocol(GMS.class);
            gms.installView(view);

            Protocol nak=ch.getProtocolStack().findProtocol(NAKACK.class, NAKACK2.class);
            if(nak != null)
                nak.down(new Event(Event.SET_DIGEST, digest));
        }
View Full Code Here

        }
    }

    private static void injectMergeEvent(Event evt, JChannel ... channels) {
        for(JChannel ch: channels) {
            GMS gms=(GMS)ch.getProtocolStack().findProtocol(GMS.class);
            gms.up(evt);
        }
    }
View Full Code Here

TOP

Related Classes of org.jgroups.protocols.pbcast.GMS$GmsHeader

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.