JBoss事务超时设置? [英] JBoss transaction timeout setting?

查看:492
本文介绍了JBoss事务超时设置?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我们在JBoss 5.1.0.GA应用程序中有一个计时器服务触发的任务,问题是我们无法更改事务超时.较长的Lucene索引所花费的时间可能超过默认的300秒限制.

We have a timer service triggered task in JBoss 5.1.0.GA application and the problem is that we cannot change the transaction time out. This long Lucene indexing can take longer than the default 300 second limit.

问题是如何更改超时值,将@TransactionTimeout(1800)添加到worker方法或该类没有任何作用.

The question is how to change the timeout value, adding @TransactionTimeout(1800) to the worker method or the class did not have any effect.

在deploy/transaction-jboss-beans.xml中进行此设置可以很好地工作:

Setting this in deploy/transaction-jboss-beans.xml works fine:

<property name="transactionTimeout">1800</property>

,但是注释似乎对计时器启动的或正常的无状态EJB都没有影响.

but the annotation doesn't seem to have effect on either timer initiated or normal stateless EJBs.

推荐答案

我正在将EJB3与Jboss 5.1.0.GA一起使用,并且已成功设置 此值在JBOSS_HOME/deploy/transaction-jboss-beans.xml中.

I am using EJB3 with Jboss 5.1.0.GA and have successfully set this value in JBOSS_HOME/deploy/transaction-jboss-beans.xml.

默认值为<property name="transactionTimeout">300</property>

这篇关于JBoss事务超时设置?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆