You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@ibatis.apache.org by "Sridhar Vijendran (JIRA)" <ib...@incubator.apache.org> on 2005/02/15 11:28:13 UTC

[jira] Commented: (IBATIS-67) iBatis hanging

     [ http://issues.apache.org/jira/browse/IBATIS-67?page=comments#action_59201 ]
     
Sridhar Vijendran commented on IBATIS-67:
-----------------------------------------

Hi Clinton,

We were using the same exact pattern that you have suggested. We actually did a special code review to ensure that the endTransaction is called in finally block.

Apparently the issue was not with no of connections. We could recreate the problem 
even with a single browser session repeating say 200 to 300 transactions.
At any time netstat command did not show more than 2/3 connections.

While we could not track down the exact cause, we could figure out that the problem was more of an aging problem with DAO manager framework. 

We resolved the issue by eliminating the DAO manager frameowrk alone and using Spring DAO template instead. (Of course , now we had to roll back in catch block.)

We could not recreate this problem outside the container environment. So I assumed that this issue could be because of ThreadLocal creation by Websphere JVM rather than iBatis code.

I totally agree with you in that the priority of this issue to be downgraded.
However there is a small chance that there might be an aging issue with DAO manager framework.

By the way, but for this issue that now stands resolved, we had great time working with iBatis and it is a great tool to enhance productivity, reduce scattering of SQL and provide ratural way to map ResultSet to JavaBeans.

That I could change the architecture of the system just under a couple of hours itself is a testimony to nice abstractions of iBatis.

Thanks and Regards,
Sridhar

> iBatis hanging
> --------------
>
>          Key: IBATIS-67
>          URL: http://issues.apache.org/jira/browse/IBATIS-67
>      Project: iBatis for Java
>         Type: Bug
>   Components: SQL Maps, DAO
>     Versions: 2.0.8, 2.0.9
>  Environment: Websphere Application Server 5.0 on Windows 
> iBatis DAO framwork and SQL Maps 2.0.8 
> Informix JDBC driver 2.21 JC3
>     Reporter: Sridhar Vijendran
>     Assignee: Clinton Begin
>     Priority: Minor

>
> We are using both iBatis DAO framework and SQL Maps.
> iBatis configuration:
> The DAO framework is configured to use SQLMAP as transaction manager.
> The SQL Maps is configured to use JDBC transaction manager SIMPLE datasource. However the issue occurs also for JDBC transaction manager JNDI datasource and for EXTERNAL transaction manager JNDI datasource.
> Coding Pattern: We are using SqlMapDaoTemplate provided with iBatis. The coding pattern is exactly identical to JPetStore 4 
> sample of iBatis.
> Manifestation of the issue:
> The application works fine for several thousand database calls 
> through iBatis. After a while, suddenly it hangs  whenever it is tries to access the database through iBatis.
> How we figured out to be an iBatis issue:
> We wrote a test jsp that accesses the database through 
> 1.Simple JDBC 2. JDBC with JNDI/Connecion Pooling 
> 3. A new instance of iBatis DAO manager
> 4. iBatis DAO manager instantiated in the static block during the first database call through iBatis.
> The first 3 calls work fine. The last one hangs forever.
> We are not able to determine if the issue is due to 
> iBatis DAO framework or iBatis SQL Maps DAO or it is an 
> issue due to iBatis SQL Map DAO template.
> We are in QA stage and we are using quirky solution of having 
> a pool of iBatis DAO managers and creating new instances 
> of DAO manager after a certain time of usage.
> Any clue to getting this issue resolved is highly appreciated.
> Also I would request the users/authors of iBatis to recommend 
> the usage patterns of iBatis that is proven to work in solid and roubust way in production environment.
>   

-- 
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
-
If you want more information on JIRA, or have a bug to report see:
   http://www.atlassian.com/software/jira