protected void configureTopic(Topic topic, ActiveMQDestination destination) { if (broker.getDestinationPolicy() != null) { PolicyEntry entry = broker.getDestinationPolicy().getEntryFor(destination); if (entry != null) { entry.configure(broker,topic); } } }
protected void configureTopic(Topic topic, ActiveMQDestination destination) { if (broker == null) { throw new IllegalStateException("broker property is not set"); } if (broker.getDestinationPolicy() != null) { PolicyEntry entry = broker.getDestinationPolicy().getEntryFor(destination); if (entry != null) { entry.configure(broker,topic); } } }
protected void configureQueue(Queue queue, ActiveMQDestination destination) { if (broker == null) { throw new IllegalStateException("broker property is not set"); } if (broker.getDestinationPolicy() != null) { PolicyEntry entry = broker.getDestinationPolicy().getEntryFor(destination); if (entry != null) { entry.configure(broker,queue); } } }
protected Subscription createSubscription(ConnectionContext context, ConsumerInfo info) throws JMSException { ActiveMQDestination destination = info.getDestination(); PolicyEntry entry = null; if (destination != null && broker.getDestinationPolicy() != null) { entry = broker.getDestinationPolicy().getEntryFor(destination); } if (info.isBrowser()) { QueueBrowserSubscription sub = new QueueBrowserSubscription(broker,usageManager, context, info); if (entry != null) { entry.configure(broker, usageManager, sub); } return sub; } else { QueueSubscription sub = new QueueSubscription(broker, usageManager,context, info); if (entry != null) { entry.configure(broker, usageManager, sub); } return sub; } }
protected Subscription createSubscription(ConnectionContext context, ConsumerInfo info) throws JMSException { if (info.isDurable()) { throw new JMSException("A durable subscription cannot be created for a temporary topic."); } try { TopicSubscription answer = new TopicSubscription(broker, context, info, usageManager); // lets configure the subscription depending on the destination ActiveMQDestination destination = info.getDestination(); if (destination != null && broker.getDestinationPolicy() != null) { PolicyEntry entry = broker.getDestinationPolicy().getEntryFor(destination); if (entry != null) { entry.configure(broker, usageManager, answer); } } answer.init(); return answer; } catch (Exception e) { LOG.error("Failed to create TopicSubscription ", e); JMSException jmsEx = new JMSException("Couldn't create TopicSubscription"); jmsEx.setLinkedException(e); throw jmsEx; } }
@Override public void processConsumerControl(ConsumerBrokerExchange consumerExchange, ConsumerControl control) { Subscription sub = subscriptions.get(control.getConsumerId()); if (sub != null && sub instanceof AbstractSubscription) { ((AbstractSubscription) sub).setPrefetchSize(control.getPrefetch()); if (broker.getDestinationPolicy() != null) { PolicyEntry entry = broker.getDestinationPolicy().getEntryFor(control.getDestination()); if (entry != null) { entry.configurePrefetch(sub); } } LOG.debug("setting prefetch: {}, on subscription: {}; resulting value: {}", new Object[]{ control.getPrefetch(), control.getConsumerId(), sub.getConsumerInfo().getPrefetchSize()}); try { lookup(consumerExchange.getConnectionContext(), control.getDestination(),false).wakeup(); } catch (Exception e) { LOG.warn("failed to deliver post consumerControl dispatch-wakeup, to destination: {}", control.getDestination(), e); } } }
if (destination != null && broker.getDestinationPolicy() != null) { PolicyEntry entry = broker.getDestinationPolicy().getEntryFor(destination); if (entry != null) { entry.configure(broker, usageManager, sub); TopicSubscription answer = new TopicSubscription(broker, context, info, usageManager); if (destination != null && broker.getDestinationPolicy() != null) { PolicyEntry entry = broker.getDestinationPolicy().getEntryFor(destination); if (entry != null) { entry.configure(broker, usageManager, answer);
if (dest != null && regionBroker.getDestinationPolicy() != null) { PolicyEntry entry = regionBroker.getDestinationPolicy().getEntryFor(dest); if (entry != null) { entry.configure(broker, usageManager, this);
if (broker.getDestinationPolicy() != null) { PolicyEntry entry = broker.getDestinationPolicy().getEntryFor(destination);
protected void configureQueue(Queue queue, ActiveMQDestination destination) { if (broker == null) { throw new IllegalStateException("broker property is not set"); } if (broker.getDestinationPolicy() != null) { PolicyEntry entry = broker.getDestinationPolicy().getEntryFor(destination); if (entry != null) { entry.configure(broker,queue); } } }
protected void configureQueue(Queue queue, ActiveMQDestination destination) { if (broker == null) { throw new IllegalStateException("broker property is not set"); } if (broker.getDestinationPolicy() != null) { PolicyEntry entry = broker.getDestinationPolicy().getEntryFor(destination); if (entry != null) { entry.configure(broker,queue); } } }
protected void configureTopic(Topic topic, ActiveMQDestination destination) { if (broker.getDestinationPolicy() != null) { PolicyEntry entry = broker.getDestinationPolicy().getEntryFor(destination); if (entry != null) { entry.configure(broker,topic); } } }
protected void configureTopic(Topic topic, ActiveMQDestination destination) { if (broker == null) { throw new IllegalStateException("broker property is not set"); } if (broker.getDestinationPolicy() != null) { PolicyEntry entry = broker.getDestinationPolicy().getEntryFor(destination); if (entry != null) { entry.configure(broker,topic); } } }
protected void configureTopic(Topic topic, ActiveMQDestination destination) { if (broker.getDestinationPolicy() != null) { PolicyEntry entry = broker.getDestinationPolicy().getEntryFor(destination); if (entry != null) { entry.configure(broker,topic); } } }
protected void configureTopic(Topic topic, ActiveMQDestination destination) { if (broker.getDestinationPolicy() != null) { PolicyEntry entry = broker.getDestinationPolicy().getEntryFor(destination); if (entry != null) { entry.configure(broker,topic); } } }
protected void configureQueue(Queue queue, ActiveMQDestination destination) { if (broker == null) { throw new IllegalStateException("broker property is not set"); } if (broker.getDestinationPolicy() != null) { PolicyEntry entry = broker.getDestinationPolicy().getEntryFor(destination); if (entry != null) { entry.configure(broker,queue); } } }
protected void configureTopic(Topic topic, ActiveMQDestination destination) { if (broker == null) { throw new IllegalStateException("broker property is not set"); } if (broker.getDestinationPolicy() != null) { PolicyEntry entry = broker.getDestinationPolicy().getEntryFor(destination); if (entry != null) { entry.configure(broker,topic); } } }
protected void configureTopic(Topic topic, ActiveMQDestination destination) { if (broker == null) { throw new IllegalStateException("broker property is not set"); } if (broker.getDestinationPolicy() != null) { PolicyEntry entry = broker.getDestinationPolicy().getEntryFor(destination); if (entry != null) { entry.configure(broker,topic); } } }
protected void configureQueue(Queue queue, ActiveMQDestination destination) { if (broker == null) { throw new IllegalStateException("broker property is not set"); } if (broker.getDestinationPolicy() != null) { PolicyEntry entry = broker.getDestinationPolicy().getEntryFor(destination); if (entry != null) { entry.configure(broker,queue); } } }
protected void configureTopic(Topic topic, ActiveMQDestination destination) { if (broker == null) { throw new IllegalStateException("broker property is not set"); } if (broker.getDestinationPolicy() != null) { PolicyEntry entry = broker.getDestinationPolicy().getEntryFor(destination); if (entry != null) { entry.configure(broker,topic); } } }