[ http://jira.jboss.com/jira/browse/JBAS-31?page=comments#action_12310793 ]
     
Adrian Brock commented on JBAS-31:
----------------------------------

I do see that unregisterConnection should also remove the connection
from connectionStackTraces rather than leaving it to the garbage collector
to remove it from the WeakHashMap.

The other code is correct.

At the end of the invocation (the servlet request), it invokes 
popMetaAwareObject
which does "closeAll".

If there is a transaction, the unclosed connections are added to the 
synchronization
and checked at transaction termination.
This will create a synchronization if necessary (the purpose of the true flag).

If there is no transaction the connections are closed immediately.

However, it should really be checking whether the transaction is still active
rather than (tx != null). But this would really represent buggy code
that is leaving a transaction association with the thread.

> CachedConnectionManager - inUseConnections not correct
> ------------------------------------------------------
>
>          Key: JBAS-31
>          URL: http://jira.jboss.com/jira/browse/JBAS-31
>      Project: JBoss Application Server
>         Type: Bug
>   Components: JCA service
>     Versions: JBossAS-3.2.6 Final
>     Reporter: Scott M Stark
>     Assignee: Scott M Stark
>  Attachments: test.jsp
>
>
> For CachedConnectionManager service debug option is
> enabled to monitor connections.
> <!-- Enable connection close debug monitoring -->
> <attribute name="Debug">true</attribute>
> Using jmx-console, if we look at the "inUseCount"
> property. The number displayed is not consitent with
> the underlying connection pool. "listInUseConnections"
> shows stack traces for connections that have been
> closed long back. It take a long time for the
> "inUseCount" to drop down, but never drops to 0 even
> after the connection pools correctly show inUseCount as 0.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://jira.jboss.com/jira/secure/Administrators.jspa
-
If you want more information on JIRA, or have a bug to report see:
   http://www.atlassian.com/software/jira



-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now. 
http://productguide.itmanagersjournal.com/
_______________________________________________
JBoss-Development mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-development

Reply via email to