开发者

How to know who is connected to a Tibco EMS Queue

开发者 https://www.devze.com 2023-03-09 18:29 出处:网络
We are using a Tibco EMS Queue to send messages. We are the publisher. Whenever we are pu开发者_如何学JAVAblishing messages it seems someone is consuming that. When we asked the other team who is subs

We are using a Tibco EMS Queue to send messages. We are the publisher. Whenever we are pu开发者_如何学JAVAblishing messages it seems someone is consuming that. When we asked the other team who is subscribing, they said they are not consuming.

Is it possible to know to who is connected to the EMS Queue and consuming the messages?


If you've got access to the EMS dashboard utility then bring up the view of all queues on the server, then right-click on the queue you're interested in and select "Consumers" and it will give you a detailed view of who is attached to a queue.

If you don't have the dashboard app then you'll probably need to hassle your EMS admins for a copy. It's part of the standard install, so they will have it.


ssl://corelayer:6223> show consumers queue=pub_queryMapsRequest.v1.queue.domainA.App.query.d1.eu_e1
                                                                              Msgs Sent
  Id Conn User        T Queue                                                 SAS Sent Size   Uptime
6544 5995 app_domain_d1 Q pub_queryMapsRequest.v1.queue.domainA.App.query.d1.eu_e1 +C-    0    0  0:09:42
6545 5996 app_domain_d1 Q pub_queryMapsRequest.v1.queue.domainA.App.query.d1.eu_e1 +C-    0    0  0:09:42
6546 5997 app_domain_d1 Q pub_queryMapsRequest.v1.queue.domainA.App.query.d1.eu_e1 +C-    0    0  0:09:42
6547 5998 app_domain_d1 Q pub_queryMapsRequest.v1.queue.domainA.App.query.d1.eu_e1 +C-    0    0  0:09:42
ssl://corelayer:6223>


You could very well use the tools that come with TIBCO EMS. There is also a very good tool called "Gems" which gives you a power-user like control over EMS. I usually prefer Gems when I have to do some monitoring (something like your case)

Heres a tutorial for Gems. http://www.youtube.com/watch?v=GvRN1auqXvE


You can use TibjmsAdmin.getConsumers() as in to get all consumer information. Even from a queue. Shouldn't you use topics instead of queues if you have multiple consumers ?

public ConsumerInfo[] getConsumers(java.lang.Long connectionID, java.lang.String username, DestinationInfo destination, boolean durable, int dataFlags) throws TibjmsAdminException


Queues are meant for the point to point communications. Officially there should be only one subscriber, you can do show queue and find out the number of subscribers to the queue.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号