Directly Access Event Bus Properties

Event buses can be monitored by directly accessing information on their state at any time.

Here's the list of data each event bus exposes via its getter methods.

Method Description
getId() The unique (sequential) ID of this bus (within this JVM/classloader).
getUuid() The universally unique identifier (UUID) for this bus.
getName() The name assigned to this bus or its default name if one was not assigned.
getState() The current state of this bus (ALIVE, SHUTTING_DOWN, TERMINATED).
isAlive() Indicates if this bus has not been shutdown.
getCreatedOn() The time this job instance was created.
getStartedOn() The time this job instance started running
isDebug() Indicates if the bus should emit debug log messages when events are published or delivered and during the shutdown process.
getShutdownTimeout() The time in milliseconds this bus will wait for events to complete before forcibly shutting down (defaults to 30 seconds).
getShutdownTimeoutAsString() The time as human readable string this bus will wait for events to complete before forcibly shutting down (defaults to 30 seconds).
getPublishersCreated() The number of event publishers created by this bus.
getEventsPublished() The number of events sent to this event bus for delivery to listeners.
getEventsDelivered() The combined number of events each listener on this event bus has received.
getEventsActive() The approximate number of threads that are actively delivering events using this bus' executorService or -1 if unknown.
getEventsQueued() The number of events waiting to be executed by this bus' executorService or -1 if unknown.
getTaskCount() The approximate total number of tasks that have ever been scheduled for execution by this bus' executorService or -1 if unknown.
getCompletedTaskCount() The approximate total number of tasks that have completed execution by this bus' executorService or -1 if unknown.
getCorePoolSize() The core number of threads in this bus' executorService or -1 if unknown.
getLargestPoolSize() The largest number of threads that have ever simultaneously been in the pool in this bus' executorService or -1 if unknown.
getMaximumPoolSize() The maximum allowed number of threads in this bus' executorService or -1 if unknown.
getPoolSize() The current number of threads in this bus' executorService pool or -1 if unknown.
getErrorCount() The number of exceptions this bus has experienced.
getTypedListenerCount() The number of type-specific listeners subscribed to this bus.
getUntypedListenerCount() The number of non-type-specific listeners subscribed to this bus.
getListenerCount() The total number of listeners subscribed to this bus.
Mobile Analytics