Examples of MembershipListener


Examples of org.apache.catalina.tribes.MembershipListener

     */
    @Override
    public void memberAdded(Member member) {
        //notify upwards
        for (int i=0; i<membershipListeners.size(); i++ ) {
            MembershipListener membershipListener = (MembershipListener)membershipListeners.get(i);
            if (membershipListener != null) membershipListener.memberAdded(member);
        }
    }
View Full Code Here

Examples of org.apache.catalina.tribes.MembershipListener

     */
    @Override
    public void memberDisappeared(Member member) {
        //notify upwards
        for (int i=0; i<membershipListeners.size(); i++ ) {
            MembershipListener membershipListener = (MembershipListener)membershipListeners.get(i);
            if (membershipListener != null) membershipListener.memberDisappeared(member);
        }
    }
View Full Code Here

Examples of org.apache.catalina.tribes.MembershipListener

     */
    @Override
    public void memberAdded(Member member) {
        //notify upwards
        for (int i=0; i<membershipListeners.size(); i++ ) {
            MembershipListener membershipListener = (MembershipListener)membershipListeners.get(i);
            if (membershipListener != null) membershipListener.memberAdded(member);
        }
    }
View Full Code Here

Examples of org.apache.catalina.tribes.MembershipListener

     */
    @Override
    public void memberDisappeared(Member member) {
        //notify upwards
        for (int i=0; i<membershipListeners.size(); i++ ) {
            MembershipListener membershipListener = (MembershipListener)membershipListeners.get(i);
            if (membershipListener != null) membershipListener.memberDisappeared(member);
        }
    }
View Full Code Here

Examples of org.jgroups.MembershipListener

      syncChannel.setOpt(Channel.LOCAL, Boolean.FALSE);

      asyncChannel.setOpt(Channel.LOCAL, Boolean.FALSE);

      MessageListener cml = new ControlMessageListener();
      MembershipListener ml = new ControlMembershipListener();
      RequestHandler rh = new PostOfficeRequestHandler();

      // register as a listener for nodeid-adress mapping events
      nodeAddressMapListener = new NodeAddressMapListener();
View Full Code Here

Examples of org.jgroups.MembershipListener

  
         this.channel = this.createChannel();              
      }
     
      // Subscribe to events generated by the channel
      MembershipListener meml = new MembershipListenerImpl();
      MessageListener msgl = this.stateIdPrefix == null ? null : new MessageListenerImpl();
      this.dispatcher = new RpcHandler(this.scopeId.shortValue(), this.channel, msgl, meml, new RequestMarshallerImpl(), new ResponseMarshallerImpl());
     
      if (!this.channel.isConnected())
      {
         this.channelSelfConnected = true;
         this.channel.connect(this.getGroupName());
        
         this.log.debug("Get current members");
         this.waitForView();
      }
      else
      {
         meml.viewAccepted(this.channel.getView());
      }
     
      // See if the channel will not let us receive our own invocations and
      // we have to make them ourselves
      Boolean receiveLocal = (Boolean) this.channel.getOpt(Channel.LOCAL);
View Full Code Here

Examples of org.jgroups.MembershipListener

            this.channel = this.createChannel();
        }

        // Subscribe to events generated by the channel
        MembershipListener meml = new MembershipListenerImpl();
        MessageListener msgl = this.stateIdPrefix == null ? null : new MessageListenerImpl();
        this.dispatcher = new RpcHandler(this.scopeId.shortValue(), this.channel, msgl, meml, new RequestMarshallerImpl(),
                new ResponseMarshallerImpl());

        if (!this.channel.isConnected()) {
            this.channelSelfConnected = true;
            this.channel.connect(this.getGroupName());

            this.log.debug("Get current members");
            this.waitForView();
        } else {
            meml.viewAccepted(this.channel.getView());
            // Since we haven't triggered a flush, we need to manually open the gate to allow rpcs.
            this.flushBlockGate.open();
        }

        // See if the channel will not let us receive our own invocations and
View Full Code Here

Examples of org.jgroups.MembershipListener

        frame.pack();
        frame.getRootPane().setDefaultButton(put_button);
        frame.setVisible(true);
        setTitle("ReplCacheDemo");

        cache.addMembershipListener(new MembershipListener() {
            public void viewAccepted(View new_view) {
                setTitle("ReplCacheDemo");
            }

            public void suspect(Address suspected_mbr) {
View Full Code Here

Examples of org.jgroups.MembershipListener

  
         this.channel = this.createChannel();              
      }
     
      // Subscribe to events generated by the channel
      MembershipListener meml = new MembershipListenerImpl();
      MessageListener msgl = this.stateIdPrefix == null ? null : new MessageListenerImpl();
      this.dispatcher = new RpcHandler(this.scopeId.shortValue(), this.channel, msgl, meml, new Object(), new RequestMarshallerImpl(), new ResponseMarshallerImpl());
     
      if (!this.channel.isConnected())
      {
         this.channelSelfConnected = true;
         this.channel.connect(this.getGroupName());
        
         this.log.debug("Get current members");
         this.waitForView();
      }
      else
      {
         meml.viewAccepted(this.channel.getView());
      }
     
      // See if the channel will not let us receive our own invocations and
      // we have to make them ourselves
      Boolean receiveLocal = (Boolean) this.channel.getOpt(Channel.LOCAL);
View Full Code Here

Examples of org.jgroups.MembershipListener

      dataChannel.setOpt(Channel.LOCAL, Boolean.FALSE);
     
      MessageListener messageListener = new ControlMessageListener();
     
      MembershipListener membershipListener = new ControlMembershipListener();
     
      RequestHandler requestHandler = new ControlRequestHandler();
     
      dispatcher = new MessageDispatcher(controlChannel, messageListener, membershipListener, requestHandler, true);
             
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.