weblogic jms消息状态message

今天同事问我说,如何处理RECEIVE、VISIBLE的JMS消息?有点懵,之前从没有关注过消息的状态。Weblogic81中,我们是不能看到destination中的消息的,只能看到当前destination中,有多少message, 有多少pending的message。而92中,我们监控destination的时候,可以看到具体的message,而且message后面会跟一个state string。标题中说的RECEIVE、VISIBLE就是这个state string,其实state有很多,常见的也就是RECEIVE、VISIBLE。下面我们看看所有这些STATE在代码(MessageInfo.java)中的解释,

VISIBLE:Indicates that the message is visible on the destination.消息已经入列,等待被消费。

ORDERED:Indicates that the message belongs to a Unit of Order. 消息处于某个unit中。

DELAYED:Indicates that the message exists on the destination but is classified as pending because it has a scheduled delivery time or is delayed. 消息已经入列,但因为TimeToDeliver还没有到,直到TimeToDeliver,该消息才会变成VISIBLE。

RECEIVE:Indicates that the message exists on the destination but is classified as pending because it has been received but not acknowledged. The actual state may also include STATE_TRANSACTION if the receive operation was performed as part of a transaction.消息已经入列,且已经被DELIVER到某个CONSUMER,但CONSUMER的ACKNOWLEDGE还没有收到。可能是网络问题或客户端设为CLIENT_ACK模式。

SEND:Indicates that the message exists on the destination but is classified as pending because it is part of a send operation that is in progress. The actual state may also include STATE_TRANSACTION if the send operation was perfromed as part of a transaction.消息已经入列,且正在被DELIVER到CONSUMER端。

TRANSACTION:Indicates that the message exists on the destination but is classified as pending because it is part of a send or receive operation that is being performed as part of a global transaction.

PAUSED:Indicates that the message exists on the destination but is being held in a pending state because of a pause operation. 消息因为PAUSE被PENDING在DEST中。

REDELIVERY_COUNT_EXCEEDED:Indicates that the message has exceeded the redelivery count set for the destination and is no longer available for consumption. 消息反复REDELIVERY的上限已经到达,这样的消息不会被重发。

根据消息的状态,我们基本可以断定JMS消息相关问题的位置,从而调查可以做到有的放矢。[@more@]

来自 “ ITPUB博客 ” ,链接:http://blog.itpub.net/21645448/viewspace-1022396/,如需转载,请注明出处,否则将追究法律责任。

转载于:http://blog.itpub.net/21645448/viewspace-1022396/

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值