开发者

HornetQ MDB timeout

JBoss 5.1 with HornetQ

I need a MDB to rollback if it cannot process a message in 30 s开发者_Go百科econds. Is this possible ?

The @TransactionTimeout(30000) annotation doesn't seem to work.

I use it along with:

@TransactionManagement(value = TransactionManagementType.CONTAINER) @TransactionAttribute(value = TransactionAttributeType.REQUIRED)

Current behavior is that if 5 minutes pass, JMS rolls back the transaction. However, this way the code is executed multiple times: for the first delivery and for each redelivery as JMS does know that the transactions has been canceled.

Could this be coped somehow ? Ideally I would like the MDB to rollback before JMS cancels the transaction.


try this

@ActivationConfigProperty(propertyName = "transactionTimeout", propertyValue = "30")
0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜