narcist527
asked on
JMS Tibco queue/topic : how to get messages count of queue?
any one can help he in how to get messages count of tibco queue using java? appreciate any help
thanks in advance
thanks in advance
you want to get the number of messages currently on the queue?
ASKER
@gurpsbassi, yes. we are using ssl connection . thanks
And there are no consumers of the queue?
If there are consumers, then the messages will not remain on the queue for you to count.
If there are consumers, then the messages will not remain on the queue for you to count.
ASKER
no one will consume these messages as this is an error tibco queue.
In that case I would use a QueueBrowser
ASKER
TibjmsAdmin admin = new TibjmsAdmin(server, username, password);
QueueInfo info = admin.getQueue(queue);
long pendingMessages = info.getPendingMessageCoun t();
StatData sd = info.getInboundStatistics( );
long TotalMs =sd.getTotalMessages();
it is throwing some security exception even though I am using correct credentials
QueueInfo info = admin.getQueue(queue);
long pendingMessages = info.getPendingMessageCoun
StatData sd = info.getInboundStatistics(
long TotalMs =sd.getTotalMessages();
it is throwing some security exception even though I am using correct credentials
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.