On 01/21/2016 03:36 AM, Stein Wang wrote:
Hi,
I also want to get the event for a specific class, but in module
qpidtoollibs.broker, there are only two classes about events, EventHelper
and BrokerEvent. I've no idea what to do to get the event of my interested
classes. Could anybody give some suggestions? Thanks.
You can look at the source of qpid-printevents to see an example of the
usage of the EvenHelper class.
Here's a summary of how it works:
EventHelper.eventAddress creates a subscription address for receiving
events from the broker. It defaults to all events, but you can use the
"cls" argument to specify a specific class of events you wish to
receive. You can also select on package and severity.
Create a receiver with the address from eventAddress and receive
messages. Each message represents one event. You can use
EventHelper.event to convert the raw message into an object that is
easily queried and viewed.
If you like, I can provide a more concrete example.
-Ted
--
View this message in context:
http://qpid.2158936.n2.nabble.com/QPID-QMF-and-QPID-TOOLS-tp7636902p7636938.html
Sent from the Apache Qpid users mailing list archive at Nabble.com.
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@qpid.apache.org
For additional commands, e-mail: users-h...@qpid.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@qpid.apache.org
For additional commands, e-mail: users-h...@qpid.apache.org