On Jun 23, 2008, at 3:31 AM, BenLeino wrote:
>
> Hi,
>
> I have a serious problem with a container managed transaction, that
> runs
> over an hour. Everything works finde but in the end, when all
> operations
> have finished, I get a transaction timeout exception.
>
> Log looks like:
> "The transaction has been rolled back rather than commited:
> Transaction
> timeout"
>
> How can I increase the timeout for container managed transaction? Is
> there
> are a way to do it on a method-base (annotations, or code within the
> method
> itsself) or is there a way to do it gloabally?
Hi Tim,
Which version of Geronimo?
The default transaction timeout is 600 seconds.
To globally override the default, assuming Geronimo 2.1.1:
Stop your server.
Edit var/config/config.xml
Locate the following element:
<module name="org.apache.geronimo.configs/transaction/2.1.1/car">
And add the following TransactionManager GBean attribute override:
<gbean name="TransactionManager">
<attribute name="defaultTransactionTimeoutSeconds">3600</
attribute>
</gbean>
That should give you a default of 1 hour.
Offhand, don't recall how to (if you can) override on a container/bean/
method basis...
--kevan