ibatis-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Jeff Butler (JIRA)" <ibatis-...@incubator.apache.org>
Subject [jira] Commented: (IBATIS-318) Transaction demarcated accross multiple threads...
Date Tue, 11 Jul 2006 21:14:30 GMT
    [ http://issues.apache.org/jira/browse/IBATIS-318?page=comments#action_12420440 ] 

Jeff Butler commented on IBATIS-318:

You'll be happy to know that we've made that method protected in the 2.2.0 release.  However,
we will continue to stress that this is an unsupported means of extending iBATIS and our implementation
will be subject to change at any time.

I don't sense any will among the committers to allow transactions to span thread boundaries,
so I think you'll always be "in the wild" on this one.  What's more likely is that we'll fix
IBATIS-320 so that you can have multiple open transactions in a thread.  There is some semblance
of an API for that.

I have recently updated the documentation with some further clarifications on this issue.

> Transaction demarcated accross multiple threads...
> --------------------------------------------------
>          Key: IBATIS-318
>          URL: http://issues.apache.org/jira/browse/IBATIS-318
>      Project: iBatis for Java
>         Type: Bug

>   Components: SQL Maps
>     Versions: 2.1.5
>     Reporter: adamb

> We are using iBATIS in the following way:
> send the server a message which will do a SqlMap.startTransaction()
> ...
> some time later
> ...
> send the server a message which will do a SqlMap.<some sql operation>
> ...
> If we set:
> Pool.MaximumActiveConnections=1
> Then we hit problems if the thread that does operations on the SqlMap is different to
the thread which started the transaction
> because
> SqlMapClientImpl.getLocalSqlMapSession()
> stores the session in a Threadlocal so it finds no session and attempts to automatically
create a new one, but since the max connections has been reached it fails.

This message is automatically generated by JIRA.
If you think it was sent incorrectly contact one of the administrators:
For more information on JIRA, see:

View raw message