|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.activemq.broker.BrokerFilter
org.apache.activemq.advisory.AdvisoryBroker
public class AdvisoryBroker
This broker filter handles tracking the state of the broker for purposes of publishing advisory messages to advisory consumers.
| Field Summary | |
|---|---|
protected ProducerId |
advisoryProducerId
|
protected java.util.concurrent.ConcurrentHashMap<ConnectionId,ConnectionInfo> |
connections
|
protected java.util.concurrent.ConcurrentHashMap<ConsumerId,ConsumerInfo> |
consumers
|
protected java.util.concurrent.ConcurrentHashMap<ActiveMQDestination,DestinationInfo> |
destinations
|
protected java.util.concurrent.ConcurrentHashMap<BrokerInfo,ActiveMQMessage> |
networkBridges
|
protected java.util.concurrent.ConcurrentHashMap<ProducerId,ProducerInfo> |
producers
|
| Fields inherited from class org.apache.activemq.broker.BrokerFilter |
|---|
next |
| Constructor Summary | |
|---|---|
AdvisoryBroker(Broker next)
|
|
| Method Summary | |
|---|---|
void |
addConnection(ConnectionContext context,
ConnectionInfo info)
A client is establishing a connection with the broker. |
Subscription |
addConsumer(ConnectionContext context,
ConsumerInfo info)
Adds a consumer. |
Destination |
addDestination(ConnectionContext context,
ActiveMQDestination destination,
boolean create)
Used to create a destination. |
void |
addDestinationInfo(ConnectionContext context,
DestinationInfo info)
Add and process a DestinationInfo object |
void |
addProducer(ConnectionContext context,
ProducerInfo info)
Adds a producer. |
void |
fastProducer(ConnectionContext context,
ProducerInfo producerInfo)
Called to notify a producer is too fast |
protected void |
fireAdvisory(ConnectionContext context,
ActiveMQTopic topic,
Command command)
|
protected void |
fireAdvisory(ConnectionContext context,
ActiveMQTopic topic,
Command command,
ConsumerId targetConsumerId)
|
protected void |
fireAdvisory(ConnectionContext context,
ActiveMQTopic topic,
Command command,
ConsumerId targetConsumerId,
ActiveMQMessage advisoryMessage)
|
protected void |
fireConsumerAdvisory(ConnectionContext context,
ActiveMQDestination consumerDestination,
ActiveMQTopic topic,
Command command)
|
protected void |
fireConsumerAdvisory(ConnectionContext context,
ActiveMQDestination consumerDestination,
ActiveMQTopic topic,
Command command,
ConsumerId targetConsumerId)
|
protected void |
fireProducerAdvisory(ConnectionContext context,
ActiveMQDestination producerDestination,
ActiveMQTopic topic,
Command command)
|
protected void |
fireProducerAdvisory(ConnectionContext context,
ActiveMQDestination producerDestination,
ActiveMQTopic topic,
Command command,
ConsumerId targetConsumerId)
|
java.util.Map<ConnectionId,ConnectionInfo> |
getAdvisoryConnections()
|
java.util.Map<ConsumerId,ConsumerInfo> |
getAdvisoryConsumers()
|
java.util.Map<ActiveMQDestination,DestinationInfo> |
getAdvisoryDestinations()
|
java.util.Map<ProducerId,ProducerInfo> |
getAdvisoryProducers()
|
void |
isFull(ConnectionContext context,
Destination destination,
Usage usage)
Called when a Usage reaches a limit |
void |
messageConsumed(ConnectionContext context,
MessageReference messageReference)
called when message is consumed |
void |
messageDelivered(ConnectionContext context,
MessageReference messageReference)
Called when message is delivered to the broker |
void |
messageDiscarded(ConnectionContext context,
Subscription sub,
MessageReference messageReference)
Called when a message is discarded - e.g. |
void |
messageExpired(ConnectionContext context,
MessageReference messageReference,
Subscription subscription)
A Message has Expired |
void |
networkBridgeStarted(BrokerInfo brokerInfo,
boolean createdByDuplex,
java.lang.String remoteIp)
|
void |
networkBridgeStopped(BrokerInfo brokerInfo)
|
void |
nowMasterBroker()
called when the broker becomes the master in a master/slave configuration |
void |
removeConnection(ConnectionContext context,
ConnectionInfo info,
java.lang.Throwable error)
A client is disconnecting from the broker. |
void |
removeConsumer(ConnectionContext context,
ConsumerInfo info)
Removes a consumer. |
void |
removeDestination(ConnectionContext context,
ActiveMQDestination destination,
long timeout)
Used to destroy a destination. |
void |
removeDestinationInfo(ConnectionContext context,
DestinationInfo destInfo)
Remove and process a DestinationInfo object |
void |
removeProducer(ConnectionContext context,
ProducerInfo info)
Removes a producer. |
void |
sendToDeadLetterQueue(ConnectionContext context,
MessageReference messageReference,
Subscription subscription)
A message needs to go the a DLQ |
void |
slowConsumer(ConnectionContext context,
Destination destination,
Subscription subs)
Called when there is a slow consumer |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected final java.util.concurrent.ConcurrentHashMap<ConnectionId,ConnectionInfo> connections
protected final java.util.concurrent.ConcurrentHashMap<ConsumerId,ConsumerInfo> consumers
protected final java.util.concurrent.ConcurrentHashMap<ProducerId,ProducerInfo> producers
protected final java.util.concurrent.ConcurrentHashMap<ActiveMQDestination,DestinationInfo> destinations
protected final java.util.concurrent.ConcurrentHashMap<BrokerInfo,ActiveMQMessage> networkBridges
protected final ProducerId advisoryProducerId
| Constructor Detail |
|---|
public AdvisoryBroker(Broker next)
| Method Detail |
|---|
public void addConnection(ConnectionContext context,
ConnectionInfo info)
throws java.lang.Exception
Broker
addConnection in interface BrokeraddConnection in class BrokerFilterjava.lang.Exception - TODO
public Subscription addConsumer(ConnectionContext context,
ConsumerInfo info)
throws java.lang.Exception
Region
addConsumer in interface RegionaddConsumer in class BrokerFiltercontext - the environment the operation is being executed under.
java.lang.Exception - TODO
public void addProducer(ConnectionContext context,
ProducerInfo info)
throws java.lang.Exception
Broker
addProducer in interface BrokeraddProducer in interface RegionaddProducer in class BrokerFiltercontext - the enviorment the operation is being executed under.
java.lang.Exception - TODO
public Destination addDestination(ConnectionContext context,
ActiveMQDestination destination,
boolean create)
throws java.lang.Exception
Region
addDestination in interface RegionaddDestination in class BrokerFilterdestination - the destination to create.
java.lang.Exception - TODO
public void addDestinationInfo(ConnectionContext context,
DestinationInfo info)
throws java.lang.Exception
Broker
addDestinationInfo in interface BrokeraddDestinationInfo in class BrokerFilterjava.lang.Exception
public void removeDestination(ConnectionContext context,
ActiveMQDestination destination,
long timeout)
throws java.lang.Exception
Region
removeDestination in interface RegionremoveDestination in class BrokerFiltercontext - the environment the operation is being executed under.destination - what is being removed from the broker.timeout - the max amount of time to wait for the destination to quiesce
java.lang.Exception - TODO
public void removeDestinationInfo(ConnectionContext context,
DestinationInfo destInfo)
throws java.lang.Exception
Broker
removeDestinationInfo in interface BrokerremoveDestinationInfo in class BrokerFilterjava.lang.Exception
public void removeConnection(ConnectionContext context,
ConnectionInfo info,
java.lang.Throwable error)
throws java.lang.Exception
Broker
removeConnection in interface BrokerremoveConnection in class BrokerFiltercontext - the environment the operation is being executed under.error - null if the client requested the disconnect or the error
that caused the client to disconnect.
java.lang.Exception - TODO
public void removeConsumer(ConnectionContext context,
ConsumerInfo info)
throws java.lang.Exception
Region
removeConsumer in interface RegionremoveConsumer in class BrokerFiltercontext - the environment the operation is being executed under.
java.lang.Exception - TODO
public void removeProducer(ConnectionContext context,
ProducerInfo info)
throws java.lang.Exception
Broker
removeProducer in interface BrokerremoveProducer in interface RegionremoveProducer in class BrokerFiltercontext - the enviorment the operation is being executed under.
java.lang.Exception - TODO
public void messageExpired(ConnectionContext context,
MessageReference messageReference,
Subscription subscription)
Broker
messageExpired in interface BrokermessageExpired in class BrokerFilter
public void messageConsumed(ConnectionContext context,
MessageReference messageReference)
Broker
messageConsumed in interface BrokermessageConsumed in class BrokerFilter
public void messageDelivered(ConnectionContext context,
MessageReference messageReference)
Broker
messageDelivered in interface BrokermessageDelivered in class BrokerFilter
public void messageDiscarded(ConnectionContext context,
Subscription sub,
MessageReference messageReference)
Broker
messageDiscarded in interface BrokermessageDiscarded in class BrokerFilter
public void slowConsumer(ConnectionContext context,
Destination destination,
Subscription subs)
Broker
slowConsumer in interface BrokerslowConsumer in class BrokerFilter
public void fastProducer(ConnectionContext context,
ProducerInfo producerInfo)
Broker
fastProducer in interface BrokerfastProducer in class BrokerFilter
public void isFull(ConnectionContext context,
Destination destination,
Usage usage)
Broker
isFull in interface BrokerisFull in class BrokerFilterpublic void nowMasterBroker()
Broker
nowMasterBroker in interface BrokernowMasterBroker in class BrokerFilter
public void sendToDeadLetterQueue(ConnectionContext context,
MessageReference messageReference,
Subscription subscription)
Broker
sendToDeadLetterQueue in interface BrokersendToDeadLetterQueue in class BrokerFilter
public void networkBridgeStarted(BrokerInfo brokerInfo,
boolean createdByDuplex,
java.lang.String remoteIp)
networkBridgeStarted in interface BrokernetworkBridgeStarted in class BrokerFilterpublic void networkBridgeStopped(BrokerInfo brokerInfo)
networkBridgeStopped in interface BrokernetworkBridgeStopped in class BrokerFilter
protected void fireAdvisory(ConnectionContext context,
ActiveMQTopic topic,
Command command)
throws java.lang.Exception
java.lang.Exception
protected void fireAdvisory(ConnectionContext context,
ActiveMQTopic topic,
Command command,
ConsumerId targetConsumerId)
throws java.lang.Exception
java.lang.Exception
protected void fireConsumerAdvisory(ConnectionContext context,
ActiveMQDestination consumerDestination,
ActiveMQTopic topic,
Command command)
throws java.lang.Exception
java.lang.Exception
protected void fireConsumerAdvisory(ConnectionContext context,
ActiveMQDestination consumerDestination,
ActiveMQTopic topic,
Command command,
ConsumerId targetConsumerId)
throws java.lang.Exception
java.lang.Exception
protected void fireProducerAdvisory(ConnectionContext context,
ActiveMQDestination producerDestination,
ActiveMQTopic topic,
Command command)
throws java.lang.Exception
java.lang.Exception
protected void fireProducerAdvisory(ConnectionContext context,
ActiveMQDestination producerDestination,
ActiveMQTopic topic,
Command command,
ConsumerId targetConsumerId)
throws java.lang.Exception
java.lang.Exception
protected void fireAdvisory(ConnectionContext context,
ActiveMQTopic topic,
Command command,
ConsumerId targetConsumerId,
ActiveMQMessage advisoryMessage)
throws java.lang.Exception
java.lang.Exceptionpublic java.util.Map<ConnectionId,ConnectionInfo> getAdvisoryConnections()
public java.util.Map<ConsumerId,ConsumerInfo> getAdvisoryConsumers()
public java.util.Map<ProducerId,ProducerInfo> getAdvisoryProducers()
public java.util.Map<ActiveMQDestination,DestinationInfo> getAdvisoryDestinations()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||