public class LoggingBrokerPlugin extends BrokerPluginSupport
next| Constructor and Description |
|---|
LoggingBrokerPlugin() |
| Modifier and Type | Method and Description |
|---|---|
void |
acknowledge(ConsumerBrokerExchange consumerExchange,
MessageAck ack)
Used to acknowledge the receipt of a message by a client.
|
void |
addBroker(Connection connection,
BrokerInfo info)
A remote Broker connects
|
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 |
addSession(ConnectionContext context,
SessionInfo info)
Adds a session.
|
void |
afterPropertiesSet() |
void |
beginTransaction(ConnectionContext context,
TransactionId xid)
Starts a transaction.
|
void |
commitTransaction(ConnectionContext context,
TransactionId xid,
boolean onePhase)
Commits a transaction.
|
void |
fastProducer(ConnectionContext context,
ProducerInfo producerInfo,
ActiveMQDestination destination)
Called to notify a producer is too fast
|
void |
forgetTransaction(ConnectionContext context,
TransactionId transactionId)
Forgets a transaction.
|
Connection[] |
getClients() |
ActiveMQDestination[] |
getDestinations() |
java.util.Set<ActiveMQDestination> |
getDurableDestinations() |
BrokerInfo[] |
getPeerBrokerInfos()
Get the BrokerInfo's of any connected Brokers
|
TransactionId[] |
getPreparedTransactions(ConnectionContext context)
Gets a list of all the prepared xa transactions.
|
void |
isFull(ConnectionContext context,
Destination destination,
Usage usage)
Called when a Usage reaches a limit
|
boolean |
isLogAll() |
boolean |
isLogConnectionEvents() |
boolean |
isLogConsumerEvents() |
boolean |
isLogInternalEvents() |
boolean |
isLogMessageEvents() |
boolean |
isLogProducerEvents() |
boolean |
isLogSessionEvents() |
boolean |
isLogTransactionEvents() |
boolean |
isPerDestinationLogger() |
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 message,
Subscription subscription)
A Message has Expired
|
Response |
messagePull(ConnectionContext context,
MessagePull pull)
Allows a consumer to pull a message from a queue
|
void |
nowMasterBroker()
called when the broker becomes the master in a master/slave
configuration
|
void |
postProcessDispatch(MessageDispatch messageDispatch)
Notify the Broker that a dispatch has happened
|
int |
prepareTransaction(ConnectionContext context,
TransactionId xid)
Prepares a transaction.
|
void |
preProcessDispatch(MessageDispatch messageDispatch)
Notify the Broker that a dispatch is going to happen
|
void |
processDispatchNotification(MessageDispatchNotification messageDispatchNotification)
Process a notification of a dispatch - used by a Slave Broker
|
void |
removeBroker(Connection connection,
BrokerInfo info)
Remove a BrokerInfo
|
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 info)
Remove and process a DestinationInfo object
|
void |
removeProducer(ConnectionContext context,
ProducerInfo info)
Removes a producer.
|
void |
removeSession(ConnectionContext context,
SessionInfo info)
Removes a session.
|
void |
removeSubscription(ConnectionContext context,
RemoveSubscriptionInfo info)
Deletes a durable subscription.
|
void |
rollbackTransaction(ConnectionContext context,
TransactionId xid)
Rollsback a transaction.
|
void |
send(ProducerBrokerExchange producerExchange,
Message messageSend)
Send a message to the broker to using the specified destination.
|
boolean |
sendToDeadLetterQueue(ConnectionContext context,
MessageReference messageReference,
Subscription subscription,
java.lang.Throwable poisonCause)
A message needs to go the a DLQ
|
void |
setLogAll(boolean logAll)
Logger all Events that go through the Plugin
|
void |
setLogConnectionEvents(boolean logConnectionEvents)
Logger Events that are related to connections
|
void |
setLogConsumerEvents(boolean logConsumerEvents)
Logger Events that are related to Consumers
|
void |
setLogInternalEvents(boolean logInternalEvents)
Logger Events that are normally internal to the broker
|
void |
setLogMessageEvents(boolean logMessageEvents)
Logger Events that are related to message processing
|
void |
setLogProducerEvents(boolean logProducerEvents)
Logger Events that are related to Producers
|
void |
setLogSessionEvents(boolean logSessionEvents)
Logger Events that are related to sessions
|
void |
setLogTransactionEvents(boolean logTransactionEvents)
Logger Events that are related to transaction processing
|
void |
setPerDestinationLogger(boolean perDestinationLogger) |
void |
slowConsumer(ConnectionContext context,
Destination destination,
Subscription subs)
Called when there is a slow consumer
|
void |
start() |
void |
stop() |
java.lang.String |
toString() |
installPluginbrokerServiceStarted, gc, getAdaptor, getAdminConnectionContext, getBrokerId, getBrokerName, getBrokerSequenceId, getBrokerService, getDestinationMap, getDestinations, getExecutor, getNext, getRoot, getScheduler, getTempDataStore, getVmConnectorURI, isExpired, isFaultTolerantConfiguration, isStopped, networkBridgeStarted, networkBridgeStopped, processConsumerControl, reapplyInterceptor, setAdminConnectionContext, setNextpublic void afterPropertiesSet()
throws java.lang.Exception
java.lang.Exceptionpublic boolean isLogAll()
public void setLogAll(boolean logAll)
public boolean isLogMessageEvents()
public void setLogMessageEvents(boolean logMessageEvents)
public boolean isLogConnectionEvents()
public void setLogConnectionEvents(boolean logConnectionEvents)
public boolean isLogSessionEvents()
public void setLogSessionEvents(boolean logSessionEvents)
public boolean isLogTransactionEvents()
public void setLogTransactionEvents(boolean logTransactionEvents)
public boolean isLogConsumerEvents()
public void setLogConsumerEvents(boolean logConsumerEvents)
public boolean isLogProducerEvents()
public void setLogProducerEvents(boolean logProducerEvents)
public boolean isLogInternalEvents()
public void setLogInternalEvents(boolean logInternalEvents)
public void acknowledge(ConsumerBrokerExchange consumerExchange, MessageAck ack) throws java.lang.Exception
Regionacknowledge in interface Regionacknowledge in class MutableBrokerFilterconsumerExchange - the environment the operation is being executed under.java.lang.Exception - TODOpublic Response messagePull(ConnectionContext context, MessagePull pull) throws java.lang.Exception
RegionmessagePull in interface RegionmessagePull in class MutableBrokerFilterjava.lang.Exceptionpublic void addConnection(ConnectionContext context, ConnectionInfo info) throws java.lang.Exception
BrokeraddConnection in interface BrokeraddConnection in class MutableBrokerFilterjava.lang.Exception - TODOpublic Subscription addConsumer(ConnectionContext context, ConsumerInfo info) throws java.lang.Exception
RegionaddConsumer in interface RegionaddConsumer in class MutableBrokerFiltercontext - the environment the operation is being executed under.java.lang.Exception - TODOpublic void addProducer(ConnectionContext context, ProducerInfo info) throws java.lang.Exception
BrokeraddProducer in interface BrokeraddProducer in interface RegionaddProducer in class MutableBrokerFiltercontext - the enviorment the operation is being executed under.java.lang.Exception - TODOpublic void commitTransaction(ConnectionContext context, TransactionId xid, boolean onePhase) throws java.lang.Exception
BrokercommitTransaction in interface BrokercommitTransaction in class MutableBrokerFilterjava.lang.Exception - TODOpublic void removeSubscription(ConnectionContext context, RemoveSubscriptionInfo info) throws java.lang.Exception
RegionremoveSubscription in interface RegionremoveSubscription in class MutableBrokerFiltercontext - the environment the operation is being executed under.info - TODOjava.lang.Exception - TODOpublic TransactionId[] getPreparedTransactions(ConnectionContext context) throws java.lang.Exception
BrokergetPreparedTransactions in interface BrokergetPreparedTransactions in class MutableBrokerFiltercontext - transaction idsjava.lang.Exception - TODOpublic int prepareTransaction(ConnectionContext context, TransactionId xid) throws java.lang.Exception
BrokerprepareTransaction in interface BrokerprepareTransaction in class MutableBrokerFilterjava.lang.Exception - TODOpublic void removeConnection(ConnectionContext context, ConnectionInfo info, java.lang.Throwable error) throws java.lang.Exception
BrokerremoveConnection in interface BrokerremoveConnection in class MutableBrokerFiltercontext - 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 - TODOpublic void removeConsumer(ConnectionContext context, ConsumerInfo info) throws java.lang.Exception
RegionremoveConsumer in interface RegionremoveConsumer in class MutableBrokerFiltercontext - the environment the operation is being executed under.java.lang.Exception - TODOpublic void removeProducer(ConnectionContext context, ProducerInfo info) throws java.lang.Exception
BrokerremoveProducer in interface BrokerremoveProducer in interface RegionremoveProducer in class MutableBrokerFiltercontext - the enviorment the operation is being executed under.java.lang.Exception - TODOpublic void rollbackTransaction(ConnectionContext context, TransactionId xid) throws java.lang.Exception
BrokerrollbackTransaction in interface BrokerrollbackTransaction in class MutableBrokerFilterjava.lang.Exception - TODOpublic void send(ProducerBrokerExchange producerExchange, Message messageSend) throws java.lang.Exception
Regionsend in interface Regionsend in class MutableBrokerFilterproducerExchange - the environment the operation is being executed under.java.lang.Exception - TODOpublic void beginTransaction(ConnectionContext context, TransactionId xid) throws java.lang.Exception
BrokerbeginTransaction in interface BrokerbeginTransaction in class MutableBrokerFilterjava.lang.Exception - TODOpublic void forgetTransaction(ConnectionContext context, TransactionId transactionId) throws java.lang.Exception
BrokerforgetTransaction in interface BrokerforgetTransaction in class MutableBrokerFilterjava.lang.Exceptionpublic Connection[] getClients() throws java.lang.Exception
getClients in interface BrokergetClients in class MutableBrokerFilterjava.lang.Exception - TODOpublic Destination addDestination(ConnectionContext context, ActiveMQDestination destination, boolean create) throws java.lang.Exception
RegionaddDestination in interface RegionaddDestination in class MutableBrokerFilterdestination - the destination to create.java.lang.Exception - TODOpublic void removeDestination(ConnectionContext context, ActiveMQDestination destination, long timeout) throws java.lang.Exception
RegionremoveDestination in interface RegionremoveDestination in class MutableBrokerFiltercontext - 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 quiescejava.lang.Exception - TODOpublic ActiveMQDestination[] getDestinations() throws java.lang.Exception
getDestinations in interface BrokergetDestinations in class MutableBrokerFilterjava.lang.Exception - TODOpublic void start()
throws java.lang.Exception
start in interface Servicestart in class BrokerPluginSupportjava.lang.Exceptionpublic void stop()
throws java.lang.Exception
stop in interface Servicestop in class BrokerPluginSupportjava.lang.Exceptionpublic void addSession(ConnectionContext context, SessionInfo info) throws java.lang.Exception
BrokeraddSession in interface BrokeraddSession in class MutableBrokerFilterjava.lang.Exception - TODOpublic void removeSession(ConnectionContext context, SessionInfo info) throws java.lang.Exception
BrokerremoveSession in interface BrokerremoveSession in class MutableBrokerFilterjava.lang.Exception - TODOpublic void addBroker(Connection connection, BrokerInfo info)
BrokeraddBroker in interface BrokeraddBroker in class MutableBrokerFilterpublic void removeBroker(Connection connection, BrokerInfo info)
BrokerremoveBroker in interface BrokerremoveBroker in class MutableBrokerFilterpublic BrokerInfo[] getPeerBrokerInfos()
BrokergetPeerBrokerInfos in interface BrokergetPeerBrokerInfos in class MutableBrokerFilterpublic void preProcessDispatch(MessageDispatch messageDispatch)
BrokerpreProcessDispatch in interface BrokerpreProcessDispatch in class MutableBrokerFilterpublic void postProcessDispatch(MessageDispatch messageDispatch)
BrokerpostProcessDispatch in interface BrokerpostProcessDispatch in class MutableBrokerFilterpublic void processDispatchNotification(MessageDispatchNotification messageDispatchNotification) throws java.lang.Exception
RegionprocessDispatchNotification in interface RegionprocessDispatchNotification in class MutableBrokerFilterjava.lang.Exception - TODOpublic java.util.Set<ActiveMQDestination> getDurableDestinations()
getDurableDestinations in interface BrokergetDurableDestinations in class MutableBrokerFilterpublic void addDestinationInfo(ConnectionContext context, DestinationInfo info) throws java.lang.Exception
BrokeraddDestinationInfo in interface BrokeraddDestinationInfo in class MutableBrokerFilterjava.lang.Exceptionpublic void removeDestinationInfo(ConnectionContext context, DestinationInfo info) throws java.lang.Exception
BrokerremoveDestinationInfo in interface BrokerremoveDestinationInfo in class MutableBrokerFilterjava.lang.Exceptionpublic void messageExpired(ConnectionContext context, MessageReference message, Subscription subscription)
BrokermessageExpired in interface BrokermessageExpired in class MutableBrokerFilterpublic boolean sendToDeadLetterQueue(ConnectionContext context, MessageReference messageReference, Subscription subscription, java.lang.Throwable poisonCause)
BrokersendToDeadLetterQueue in interface BrokersendToDeadLetterQueue in class MutableBrokerFilterpoisonCause - reason for dlq submission, may be nullpublic void fastProducer(ConnectionContext context, ProducerInfo producerInfo, ActiveMQDestination destination)
BrokerfastProducer in interface BrokerfastProducer in class MutableBrokerFilterpublic void isFull(ConnectionContext context, Destination destination, Usage usage)
BrokerisFull in interface BrokerisFull in class MutableBrokerFilterpublic void messageConsumed(ConnectionContext context, MessageReference messageReference)
BrokermessageConsumed in interface BrokermessageConsumed in class MutableBrokerFilterpublic void messageDelivered(ConnectionContext context, MessageReference messageReference)
BrokermessageDelivered in interface BrokermessageDelivered in class MutableBrokerFilterpublic void messageDiscarded(ConnectionContext context, Subscription sub, MessageReference messageReference)
BrokermessageDiscarded in interface BrokermessageDiscarded in class MutableBrokerFilterpublic void slowConsumer(ConnectionContext context, Destination destination, Subscription subs)
BrokerslowConsumer in interface BrokerslowConsumer in class MutableBrokerFilterpublic void nowMasterBroker()
BrokernowMasterBroker in interface BrokernowMasterBroker in class MutableBrokerFilterpublic java.lang.String toString()
toString in class java.lang.Objectpublic void setPerDestinationLogger(boolean perDestinationLogger)
public boolean isPerDestinationLogger()
Copyright © 2005-2014 Red Hat, Inc.. All Rights Reserved.