destMessages.addEventListener(this, EventType.SET_CHANGED, this);
setDefaultCounts(type);
}
public DestMetricsCounters getMetrics() {
DestMetricsCounters dmc = super.getMetrics();
synchronized (this) {
// current # of active consumers
dmc.setActiveConsumers(activeConsumerCnt);
// current # of failover consumers
// only applies to queues
dmc.setFailoverConsumers(failoverConsumerCnt);
// max # of active consumers
dmc.setHWActiveConsumers(hwActiveCount);
// max # of failover consumers
dmc.setHWFailoverConsumers(hwFailoverCount);
// avg active consumer
dmc.setAvgActiveConsumers((int)activeAverage);
// avg failover consumer
dmc.setAvgFailoverConsumers((int)failoverAverage);
}
return dmc;
}