Examples of BrokerAdmin


Examples of com.trendmicro.tme.broker.BrokerAdmin

            node.create(false, limit.toBuilder().setSizeBytes(Long.valueOf(sizeLimit)).build().toString().getBytes());
        }
       
        String broker = exchangeFarm.getCurrentExchangeHost(ex);
        if(broker != null) {
            BrokerAdmin brokerAdmin = new BrokerAdmin(broker);
            brokerAdmin.jmxConnectServer();
            try {
                brokerAdmin.setExchangeAttrib(ex, "MaxTotalMsgBytes", Long.valueOf(sizeLimit));
            }
            finally {
                brokerAdmin.jmxCloseServer();
            }
        }
    }
View Full Code Here

Examples of org.activemq.broker.BrokerAdmin

    /**
     * @param command
     * @throws JMSException
     */
    private void consumeBrokerAdminCommand(BrokerAdminCommand command) throws JMSException {
        BrokerAdmin brokerAdmin = brokerConnector.getBrokerContainer().getBroker().getBrokerAdmin();
        if (BrokerAdminCommand.CREATE_DESTINATION.equals(command.getCommand())) {
            brokerAdmin.createMessageContainer(command.getDestination());
        }
        else if (BrokerAdminCommand.DESTROY_DESTINATION.equals(command.getCommand())) {
            brokerAdmin.destoryMessageContainer(command.getDestination());
        }
        else if (BrokerAdminCommand.EMPTY_DESTINATION.equals(command.getCommand())) {
            brokerAdmin.getMessageContainerAdmin(command.getDestination()).empty();
        }
        else {
            throw new JMSException("Broker Admin Command type: " + command.getCommand() + " not recognized.");
        }
    }
View Full Code Here

Examples of org.codehaus.activemq.broker.BrokerAdmin

    /**
     * @param command
     * @throws JMSException
     */
    private void consumeBrokerAdminCommand(BrokerAdminCommand command) throws JMSException {
        BrokerAdmin brokerAdmin = brokerConnector.getBrokerContainer().getBroker().getBrokerAdmin();
        if (BrokerAdminCommand.CREATE_DESTINATION.equals(command.getCommand())) {
            brokerAdmin.createMessageContainer(command.getDestination());
        }
        else if (BrokerAdminCommand.DESTROY_DESTINATION.equals(command.getCommand())) {
            brokerAdmin.destoryMessageContainer(command.getDestination());
        }
        else if (BrokerAdminCommand.EMPTY_DESTINATION.equals(command.getCommand())) {
            brokerAdmin.getMessageContainerAdmin(command.getDestination()).empty();
        }
        else {
            throw new JMSException("Broker Admin Command type: " + command.getCommand() + " not recognized.");
        }
    }
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.