Package org.jgroups.protocols.pbcast

Examples of org.jgroups.protocols.pbcast.NAKACK2$RetransmitTask


    protected JChannel createChannel(String name) throws Exception {
        JChannel ch=new JChannel(new SHARED_LOOPBACK(),
                                 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);
View Full Code Here


    protected MockProtocol  receiver;

    @BeforeMethod
    protected void setup() throws Exception {
        receiver=new MockProtocol();
        nak=(NAKACK2)new NAKACK2().setValue("use_mcast_xmit", false);
        transport=new MockTransport();
        ProtocolStack stack=new ProtocolStack();
        stack.addProtocols(transport, nak, receiver);
        stack.init();
View Full Code Here

        tunnel.setGossipRouterHosts(gossip_router_hosts);
        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

        b=Util.createRandomAddress("B");
        c=Util.createRandomAddress("C");
        v1=View.create(a, 1, a, b);
        v2=View.create(a, 2, a, b, c);

        nak=new NAKACK2();
        d1=new Digest(v1.getMembersRaw(), new long[]{11,11, 30,35});
        d2=new Digest(v2.getMembersRaw(), new long[]{10,10, 30,30, 50,50});

        TP transport=new TP() {
            public boolean supportsMulticasting() {return false;}
View Full Code Here

        Protocol flow_control_prot=flow_control_class.newInstance();
        flow_control_prot.setValue("min_credits", 1000).setValue("max_credits", 10000).setValue("max_block_time", 1000);

        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));
View Full Code Here

    private TOANode createNewChannel(String name) throws Exception {
        JChannel channel = new JChannel(new Protocol[]{
                new SHARED_LOOPBACK(),
                new SHARED_LOOPBACK_PING(),
                new MERGE3(),
                new NAKACK2(),
                new UNICAST3(),
                new TOA(),
                new GMS()
        }).name(name);
        TOANode toaNode = new TOANode(channel);
View Full Code Here

    protected JChannel create(String name, boolean insert_discard) throws Exception {
        JChannel ch=new JChannel(new SHARED_LOOPBACK(),
                                 new DISCARD().setValue("discard_all", insert_discard),
                                 new PING(),
                                 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)
View Full Code Here

                                   .setValue("sock_conn_timeout",300).setValue("bind_addr", bind_addr),
                                 gossip,
                                 new MERGE3().setValue("min_interval",1000).setValue("max_interval",3000),
                                 new FD().setValue("timeout",2000).setValue("max_tries",2),
                                 new VERIFY_SUSPECT(),
                                 new NAKACK2().setValue("use_mcast_xmit",false),
                                 new UNICAST3(), new STABLE(), new GMS().joinTimeout(1000));
        if(name != null)
            ch.setName(name);
        return ch;
    }
View Full Code Here


    protected JChannel createChannel(String name) throws Exception {
        JChannel ch=new JChannel(new SHARED_LOOPBACK(),
                                 new SHARED_LOOPBACK_PING(),
                                 new NAKACK2().setValue("become_server_queue_size", 10),
                                 new UNICAST3(),
                                 new GMS().setValue("print_local_addr", false));
        ch.setName(name);
        return ch;
    }
View Full Code Here

        System.out.println("coord_view: " + coord_view);
        Channel coord_channel = findChannel(coord);
        System.out.println("coord_channel: " + coord_channel.getAddress());
       
        MutableDigest digest=new MutableDigest(coord_view.getMembersRaw());
        NAKACK2 nakack=(NAKACK2)coord_channel.getProtocolStack().findProtocol(NAKACK2.class);
        digest.merge(nakack.getDigest(coord));
       
        GMS gms=(GMS)coord_channel.getProtocolStack().findProtocol(GMS.class);
        gms.installView(coord_view, digest);
        System.out.println("gms.getView() " + gms.getView());
       
View Full Code Here

TOP

Related Classes of org.jgroups.protocols.pbcast.NAKACK2$RetransmitTask

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.