Examples of GroupChannel


Examples of org.apache.catalina.tribes.group.GroupChannel

        if ( valves.size() == 0 ) {
            addValve(new JvmRouteBinderValve());
            addValve(new ReplicationValve());
        }
        if ( clusterDeployer != null ) clusterDeployer.setCluster(this);
        if ( channel == null ) channel = new GroupChannel();
        if ( channel instanceof GroupChannel && !((GroupChannel)channel).getInterceptors().hasNext()) {
            channel.addInterceptor(new MessageDispatch15Interceptor());
            channel.addInterceptor(new TcpFailureDetector());
        }
    }
View Full Code Here

Examples of org.apache.catalina.tribes.group.GroupChannel

        if (mbind != null) service.setMcastBindAddress(mbind);
        service.setMcastFrequency(mcastfreq);
        service.setMcastDropTime(mcastdrop);
        service.setMcastPort(mcastport);

        ManagedChannel channel = new GroupChannel();
        channel.setChannelReceiver(rx);
        channel.setChannelSender(ps);
        channel.setMembershipService(service);

        if (gzip) channel.addInterceptor(new GzipInterceptor());
        if ( frag ) {
            FragmentationInterceptor fi = new FragmentationInterceptor();
            fi.setMaxSize(fragsize);
            channel.addInterceptor(fi);
        }
        if (order) {
            OrderInterceptor oi = new OrderInterceptor();
            oi.setMaxQueue(ordersize);
            channel.addInterceptor(oi);
        }
       
        if ( async ) {
            MessageDispatchInterceptor mi = new MessageDispatchInterceptor();
            mi.setMaxQueueSize(asyncsize);
            channel.addInterceptor(mi);
            System.out.println("Added MessageDispatchInterceptor");
        }
       
        return channel;
       
View Full Code Here

Examples of org.apache.catalina.tribes.group.GroupChannel

        if ( valves.size() == 0 ) {
            addValve(new JvmRouteBinderValve());
            addValve(new ReplicationValve());
        }
        if ( clusterDeployer != null ) clusterDeployer.setCluster(this);
        if ( channel == null ) channel = new GroupChannel();
        if ( channel instanceof GroupChannel && !((GroupChannel)channel).getInterceptors().hasNext()) {
            channel.addInterceptor(new MessageDispatch15Interceptor());
            channel.addInterceptor(new TcpFailureDetector());
        }
    }
View Full Code Here

Examples of org.apache.catalina.tribes.group.GroupChannel

        if ( valves.size() == 0 ) {
            addValve(new JvmRouteBinderValve());
            addValve(new ReplicationValve());
        }
        if ( clusterDeployer != null ) clusterDeployer.setCluster(this);
        if ( channel == null ) channel = new GroupChannel();
        if ( channel instanceof GroupChannel && !((GroupChannel)channel).getInterceptors().hasNext()) {
            channel.addInterceptor(new MessageDispatch15Interceptor());
            channel.addInterceptor(new TcpFailureDetector());
        }
    }
View Full Code Here

Examples of org.apache.catalina.tribes.group.GroupChannel

    public void init() throws ClusteringFault {
        log.info("Initializing cluster...");
        addRequestBlockingHandlerToInFlows();
        primaryMembershipManager = new MembershipManager(configurationContext);

        channel = new GroupChannel();
        channel.setHeartbeat(true);
        channelSender = new ChannelSender(channel, primaryMembershipManager, synchronizeAllMembers());
        axis2ChannelListener =
                new Axis2ChannelListener(configurationContext, configurationManager, contextManager);
        channel.addChannelListener(axis2ChannelListener);
View Full Code Here

Examples of org.apache.catalina.tribes.group.GroupChannel

        cluster.setManagerTemplate((org.apache.catalina.ha.ClusterManager)manager);
        //cluster.setDebug(debug);
        // removed since 5.5.9? cluster.setExpireSessionsOnShutdown(expireSession);
        // removed since 5.5.9? cluster.setUseDirtyFlag(useDirty);

        GroupChannel channel = new GroupChannel();
        channel.setChannelReceiver(listener);
        channel.setChannelSender(trans);
        channel.setMembershipService(mcast);

        cluster.setChannel(channel);
        cluster.addValve(clusterValve);
        // removed since 5.5.9? cluster.setPrintToScreen(true);
View Full Code Here

Examples of org.apache.catalina.tribes.group.GroupChannel

                    break;
                }
            }
        }
        membershipManager = new MembershipManager();
        channel = new GroupChannel();
        channelSender = new ChannelSender(channel, membershipManager, synchronizeAllMembers());
        channelListener = new ChannelListener(configurationContext, configurationManager,
                                              contextManager, controlCmdProcessor);

        // Set the maximum number of retries, if message sending to a particular node fails
View Full Code Here

Examples of org.apache.catalina.tribes.group.GroupChannel

       //Set the parameters
       setParameters(channel, initParams);
      
       // if the channel is a GroupChannel then add the sender, receiver, and membership service
       if (channel instanceof GroupChannel) {
           GroupChannel groupChannel = (GroupChannel)channel;
           //Add the MembershipService
           if (membership != null){
               groupChannel.setMembershipService((MembershipService)membership.getInternalObject());
           }
          
           //Add Receiver
           if (receiver != null){
               groupChannel.setChannelReceiver((ChannelReceiver)receiver.getInternalObject());
           }
          
           //Add Sender
           if (sender != null){
               groupChannel.setChannelSender((ChannelSender)sender.getInternalObject());
           }
       } else {
           log.warn(className + " is not an instance of GroupChannel. Did not set Receiver, Sender, or MembershipService");
       }
      
View Full Code Here

Examples of org.apache.catalina.tribes.group.GroupChannel

    private boolean noMultiCast;

    private static final GroupChannel createChannel(String address, int port, String bindAddress) {

        //create a channel
        GroupChannel channel = new GroupChannel();
        McastService mcastService = (McastService)channel.getMembershipService();
        mcastService.setPort(port);
        mcastService.setAddress(address);

        // REVIEW: In my case, there are multiple IP addresses
        // One for the WIFI and the other one for VPN. For some reason the VPN one doesn't support
View Full Code Here

Examples of org.apache.catalina.tribes.group.GroupChannel

    public void start() {
        if (map != null) {
            throw new IllegalStateException("The registry has already been started");
        }
        GroupChannel channel = createChannel(address, port, bind);
        map =
            new ReplicatedMap(null, channel, timeout, this.domainURI,
                              new ClassLoader[] {ReplicatedDomainRegistry.class.getClassLoader()});
        map.addListener(this);

        if (noMultiCast) {
            map.getChannel().addInterceptor(new DisableMcastInterceptor());
        }

        // Configure the receiver ports
        ChannelReceiver receiver = channel.getChannelReceiver();
        if (receiver instanceof ReceiverBase) {
            if (receiverAddress != null) {
                ((ReceiverBase)receiver).setAddress(receiverAddress);
            }
            ((ReceiverBase)receiver).setPort(receiverPort);
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.