Package org.activemq.message

Examples of org.activemq.message.BrokerInfo


        factory.setBrokerName(brokerName);
        factory.setQuickClose(true);
        factory.setInternalConnection(true);
        localConnection = (ActiveMQConnection) factory.createConnection();
        localConnection.start();
        BrokerInfo info = new BrokerInfo();
        info.setBrokerName(remoteBrokerName);
        info.setClusterName(remoteClusterName);
        localConnection.asyncSendPacket(info);
        if (localPrefetchPolicy != null) {
            localConnection.setPrefetchPolicy(localPrefetchPolicy);
        }
    }
View Full Code Here


        }
        this.activeClient = client;
        if (client != null) {
            BrokerConnector brokerConnector = client.getBrokerConnector();
            if (brokerConnector != null) {
                BrokerInfo brokerInfo = brokerConnector.getBrokerInfo();
                if (brokerInfo != null) {
                    brokerName = brokerInfo.getBrokerName();
                    clusterName = brokerInfo.getClusterName();
                }
            }
        }
    }
View Full Code Here

        this.consumerInfo = info;
        this.client = client;
        if (client != null) {
            BrokerConnector connector = client.getBrokerConnector();
            if (connector != null) {
                BrokerInfo bi = connector.getBrokerInfo();
                if (bi != null) {
                    this.brokerName = bi.getBrokerName();
                    this.clusterName = bi.getClusterName();
                }
            }
        }
    }
View Full Code Here

    }
   
    private void sendBrokerInfo() throws JMSException{
        //inform the other side we are a remote channel
        if (boondocksChannel != null) {
            BrokerInfo info = new BrokerInfo();
            info.setBrokerName(brokerContainer.getBroker().getBrokerName());
            info.setClusterName(brokerContainer.getBroker().getBrokerClusterName());
            info.setRemote(true);
            boondocksChannel.asyncSend(info);
        }
    }
View Full Code Here

        fac.setTurboBoost(true);
        remoteConnection = new ActiveMQConnection(fac, remoteUserName, remotePassword, channel);
        remoteConnection.setClientID("Boondocks:" + remoteClusterName + ":" +  remoteBrokerName);
        remoteConnection.setQuickClose(true);
        remoteConnection.start();
        BrokerInfo info = new BrokerInfo();
        info.setBrokerName(brokerContainer.getBroker().getBrokerName());
        info.setClusterName(brokerContainer.getBroker().getBrokerClusterName());
        channel.asyncSend(info);
      
       
    }
View Full Code Here

                composite.setIncrementTimeout(false);
            }
            transportChannel.addTransportStatusEventListener(this);
            remoteConnection.setClientID(brokerContainer.getBroker().getBrokerName() + "_NetworkChannel");
            remoteConnection.start();
            BrokerInfo info = new BrokerInfo();
            info.setBrokerName(brokerContainer.getBroker().getBrokerName());
            info.setClusterName(brokerContainer.getBroker().getBrokerClusterName());
         
            Receipt receipt = remoteConnection.syncSendRequest(info);
            if (receipt != null){
                remoteBrokerName = receipt.getBrokerName();
                remoteClusterName = receipt.getClusterName();
View Full Code Here

        factory.setBrokerName(brokerName);
        factory.setQuickClose(true);
        factory.setInternalConnection(true);
        localConnection = (ActiveMQConnection) factory.createConnection();
        localConnection.start();
        BrokerInfo info = new BrokerInfo();
        info.setBrokerName(remoteBrokerName);
        info.setClusterName(remoteClusterName);
        localConnection.asyncSendPacket(info);
    }
View Full Code Here

    /**
     * @return a new Packet instance
     */

    public Packet createPacket() {
        return new BrokerInfo();
    }
View Full Code Here

     * @throws IOException
     */

    public void buildPacket(Packet packet, DataInput dataIn) throws IOException {
        super.buildPacket(packet, dataIn);
        BrokerInfo info = (BrokerInfo) packet;
        info.setBrokerName(dataIn.readUTF());
        info.setClusterName(dataIn.readUTF());
        info.setStartTime(dataIn.readLong());
        info.setProperties((Properties) super.readObject(dataIn));
        if (wireFormatVersion>=2){
            info.setRemote(dataIn.readBoolean());
        }
    }
View Full Code Here

        }
    }
   
    private void sendBrokerInfo() throws JMSException{
        //inform the other side we are a remote channel
        BrokerInfo info = new BrokerInfo();
        info.setBrokerName(brokerContainer.getBroker().getBrokerName());
        info.setClusterName(brokerContainer.getBroker().getBrokerClusterName());
        info.setRemote(true);
        boondocksChannel.asyncSend(info);
    }
View Full Code Here

TOP

Related Classes of org.activemq.message.BrokerInfo

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.