@Override public void dispose(ConnectionContext context) throws IOException { if (this.store != null) { this.store.removeAllMessages(context); this.store.dispose(context); } this.destinationStatistics.setParent(null); this.memoryUsage.stop(); this.disposed = true; }
/** * @param brokerService * @param store * @param destination * @param parentStats * @throws Exception */ public BaseDestination(BrokerService brokerService, MessageStore store, ActiveMQDestination destination, DestinationStatistics parentStats) throws Exception { this.brokerService = brokerService; this.broker = brokerService.getBroker(); this.store = store; this.destination = destination; // let's copy the enabled property from the parent DestinationStatistics this.destinationStatistics.setEnabled(parentStats.isEnabled()); this.destinationStatistics.setParent(parentStats); this.systemUsage = new SystemUsage(brokerService.getProducerSystemUsage(), destination.toString()); this.memoryUsage = this.systemUsage.getMemoryUsage(); this.memoryUsage.setUsagePortion(1.0f); this.regionBroker = brokerService.getRegionBroker(); this.scheduler = brokerService.getBroker().getScheduler(); }
@Override public void dispose(ConnectionContext context) throws IOException { if (this.store != null) { this.store.removeAllMessages(context); this.store.dispose(context); } this.destinationStatistics.setParent(null); this.memoryUsage.stop(); this.disposed = true; }
@Override public void dispose(ConnectionContext context) throws IOException { if (this.store != null) { this.store.removeAllMessages(context); this.store.dispose(context); } this.destinationStatistics.setParent(null); this.memoryUsage.stop(); this.disposed = true; }
public void dispose(ConnectionContext context) throws IOException { if (this.store != null) { this.store.removeAllMessages(context); this.store.dispose(context); } this.destinationStatistics.setParent(null); this.memoryUsage.stop(); }
@Override public void dispose(ConnectionContext context) throws IOException { if (this.store != null) { this.store.removeAllMessages(context); this.store.dispose(context); } this.destinationStatistics.setParent(null); this.memoryUsage.stop(); this.disposed = true; }
/** * @param broker * @param store * @param destination * @param parentStats * @throws Exception */ public BaseDestination(BrokerService brokerService, MessageStore store, ActiveMQDestination destination, DestinationStatistics parentStats) throws Exception { this.brokerService = brokerService; this.broker = brokerService.getBroker(); this.store = store; this.destination = destination; // let's copy the enabled property from the parent DestinationStatistics this.destinationStatistics.setEnabled(parentStats.isEnabled()); this.destinationStatistics.setParent(parentStats); this.systemUsage = new SystemUsage(brokerService.getProducerSystemUsage(), destination.toString()); this.memoryUsage = this.systemUsage.getMemoryUsage(); this.memoryUsage.setUsagePortion(1.0f); this.regionBroker = brokerService.getRegionBroker(); }
/** * @param brokerService * @param store * @param destination * @param parentStats * @throws Exception */ public BaseDestination(BrokerService brokerService, MessageStore store, ActiveMQDestination destination, DestinationStatistics parentStats) throws Exception { this.brokerService = brokerService; this.broker = brokerService.getBroker(); this.store = store; this.destination = destination; // let's copy the enabled property from the parent DestinationStatistics this.destinationStatistics.setEnabled(parentStats.isEnabled()); this.destinationStatistics.setParent(parentStats); this.systemUsage = new SystemUsage(brokerService.getProducerSystemUsage(), destination.toString()); this.memoryUsage = this.systemUsage.getMemoryUsage(); this.memoryUsage.setUsagePortion(1.0f); this.regionBroker = brokerService.getRegionBroker(); this.scheduler = brokerService.getBroker().getScheduler(); }
/** * @param brokerService * @param store * @param destination * @param parentStats * @throws Exception */ public BaseDestination(BrokerService brokerService, MessageStore store, ActiveMQDestination destination, DestinationStatistics parentStats) throws Exception { this.brokerService = brokerService; this.broker = brokerService.getBroker(); this.store = store; this.destination = destination; // let's copy the enabled property from the parent DestinationStatistics this.destinationStatistics.setEnabled(parentStats.isEnabled()); this.destinationStatistics.setParent(parentStats); this.systemUsage = new SystemUsage(brokerService.getProducerSystemUsage(), destination.toString()); this.memoryUsage = this.systemUsage.getMemoryUsage(); this.memoryUsage.setUsagePortion(1.0f); this.regionBroker = brokerService.getRegionBroker(); this.scheduler = brokerService.getBroker().getScheduler(); }
/** * @param brokerService * @param store * @param destination * @param parentStats * @throws Exception */ public BaseDestination(BrokerService brokerService, MessageStore store, ActiveMQDestination destination, DestinationStatistics parentStats) throws Exception { this.brokerService = brokerService; this.broker = brokerService.getBroker(); this.store = store; this.destination = destination; // let's copy the enabled property from the parent DestinationStatistics this.destinationStatistics.setEnabled(parentStats.isEnabled()); this.destinationStatistics.setParent(parentStats); this.systemUsage = new SystemUsage(brokerService.getProducerSystemUsage(), destination.toString()); this.memoryUsage = this.systemUsage.getMemoryUsage(); this.memoryUsage.setUsagePortion(1.0f); this.regionBroker = brokerService.getRegionBroker(); this.scheduler = brokerService.getBroker().getScheduler(); }