Class ChannelCoordinator

    • Field Detail

      • sm

        protected static final StringManager sm
        String manager for this class.
    • Constructor Detail

      • ChannelCoordinator

        public ChannelCoordinator()
        Default constructor.
      • ChannelCoordinator

        public ChannelCoordinator​(ChannelReceiver receiver,
                                  ChannelSender sender,
                                  MembershipService service)
        Construct a ChannelCoordinator with the specified receiver, sender and membership service.
        Parameters:
        receiver - The channel receiver
        sender - The channel sender
        service - The membership service
    • Method Detail

      • start

        public void start​(int svc)
                   throws ChannelException
        Description copied from interface: ChannelInterceptor
        Starts up the channel. This can be called multiple times for individual services to start The svc parameter can be the logical or value of any constants
        Specified by:
        start in interface ChannelInterceptor
        Overrides:
        start in class ChannelInterceptorBase
        Parameters:
        svc - one of:
        • Channel.DEFAULT - will start all services
        • Channel.MBR_RX_SEQ - starts the membership receiver
        • Channel.MBR_TX_SEQ - starts the membership broadcaster
        • Channel.SND_TX_SEQ - starts the replication transmitter
        • Channel.SND_RX_SEQ - starts the replication receiver
        Throws:
        ChannelException - if a startup error occurs or the service is already started.
        See Also:
        Channel
      • stop

        public void stop​(int svc)
                  throws ChannelException
        Description copied from interface: ChannelInterceptor
        Shuts down the channel. This can be called multiple times for individual services to shut down. The svc parameter can be the logical or value of any constants
        Specified by:
        stop in interface ChannelInterceptor
        Overrides:
        stop in class ChannelInterceptorBase
        Parameters:
        svc - one of:
        • Channel.DEFAULT - will shut down all services
        • Channel.MBR_RX_SEQ - stops the membership receiver
        • Channel.MBR_TX_SEQ - stops the membership broadcaster
        • Channel.SND_TX_SEQ - stops the replication transmitter
        • Channel.SND_RX_SEQ - stops the replication receiver
        Throws:
        ChannelException - if a startup error occurs or the service is already started.
        See Also:
        Channel
      • internalStart

        protected void internalStart​(int svc)
                              throws ChannelException
        Starts up the channel. This can be called multiple times for individual services to start The svc parameter can be the logical or value of any constants
        Parameters:
        svc - int value of
        DEFAULT - will start all services
        MBR_RX_SEQ - starts the membership receiver
        MBR_TX_SEQ - starts the membership broadcaster
        SND_TX_SEQ - starts the replication transmitter
        SND_RX_SEQ - starts the replication receiver
        Throws:
        ChannelException - if a startup error occurs or the service is already started.
      • internalStop

        protected void internalStop​(int svc)
                             throws ChannelException
        Shuts down the channel. This can be called multiple times for individual services to shutdown The svc parameter can be the logical or value of any constants
        Parameters:
        svc - int value of
        DEFAULT - will shutdown all services
        MBR_RX_SEQ - stops the membership receiver
        MBR_TX_SEQ - stops the membership broadcaster
        SND_TX_SEQ - stops the replication transmitter
        SND_RX_SEQ - stops the replication receiver
        Throws:
        ChannelException - if a startup error occurs or the service is already started.
      • accept

        public boolean accept​(ChannelMessage msg)
        Description copied from interface: MessageListener
        Allows skipping processing of the specified message.
        Specified by:
        accept in interface MessageListener
        Parameters:
        msg - the message
        Returns:
        true if the message will be processed
      • getClusterReceiver

        public ChannelReceiver getClusterReceiver()
        Returns the cluster receiver.
        Returns:
        the cluster receiver
      • getClusterSender

        public ChannelSender getClusterSender()
        Returns the cluster sender.
        Returns:
        the cluster sender
      • getMembershipService

        public MembershipService getMembershipService()
        Returns the membership service.
        Returns:
        the membership service
      • setClusterReceiver

        public void setClusterReceiver​(ChannelReceiver clusterReceiver)
        Sets the cluster receiver.
        Parameters:
        clusterReceiver - The new cluster receiver
      • setClusterSender

        public void setClusterSender​(ChannelSender clusterSender)
        Sets the cluster sender.
        Parameters:
        clusterSender - The new cluster sender
      • setMembershipService

        public void setMembershipService​(MembershipService membershipService)
        Sets the membership service.
        Parameters:
        membershipService - The new membership service