You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@ibatis.apache.org by "adamb (JIRA)" <ib...@incubator.apache.org> on 2006/07/06 22:21:30 UTC

[jira] Commented: (IBATIS-318) Transaction demarcated accross multiple threads...

    [ http://issues.apache.org/jira/browse/IBATIS-318?page=comments#action_12419597 ] 

adamb commented on IBATIS-318:
------------------------------

It may be working as designed, but not as documented.  The Documentation just says to make sure that you end all transactions that you start to avoid losing connections in the pool ...(and we are ensuring that)... however the documentation does not say that all transactions are required to be started executed and ended in the same thread...

> 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:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira