On 13 May 2010, at 11:13, "Tomás Tormo" <tto...@indenova.com> wrote:

>>
>> http://commons.apache.org/dbcp/configuration.html
>>
> Thanks, I was already checking that.
>
>> I don't know anything about Introscope.
> It just an monitoring tool application
>
>> If maxActive is larger than the number of active connections, then
>> there's nothing wrong there, is there?  I'm not sure what you're
>> trying
>> to explain by that.
>>
>>
> Yes maxActive is larger than the active connections. Both queries
> (the one running and the one stalled) are trying to access the same
> register in BBDD (is the case when two different users are doing the
> same), but the query is just a simple SELECt, that's why I think is
> surprising that the second one is getting stalled...
>
>> If you can see some stalled connections, take a thread dump to see
>> what
>> they're doing/waiting on.
>
> Could I use jvisualvm for that? I knew I could see threads state
> there, but I didn't know I could see why they are waiting...

Yes, or jstack on the command line.

> Sorry for my ignorance, I'm just starting in this field...

Gotta start somewhere. :)

p


>
>
>
> On 13/05/10 11:05, Pid wrote:
>> On 13/05/2010 09:35, Tom�s Tormo wrote:
>>
>>> Greetings
>>>
>>> I would like to understand correctly how Tomcat database pool works.
>>>
>> It's a repackaged version of Apache Commons DBCP.
>>
>>
>>> As I understand, when the application starts, a pool connection is
>>> created with *initialSize* connections (0 by default).
>>>
>>> Later on, new connections are created on demand of the application,
>>> untill it reaches the *maxActive* connections. If *maxActive* has
>>> been
>>> reached and the application requests for a new connection, the
>>> pool will
>>> wait *maxWait* milliseconds for a free connection.
>>>
>>> If any connection has been released, it will be kept as idle as
>>> long as
>>> *maxIdle* is not reached. No more connections will be created if
>>> there
>>> are *minIdle* or more connections in the pool in idle state.
>>>
>> http://commons.apache.org/dbcp/configuration.html
>>
>>
>>> �Am I right?
>>>
>>> But I still have some questions:
>>>
>>> �How to see the pool connection state in real time? (idle conn
>>> ections,
>>> active connections, etc). We are using Introscope for monitoring an
>>> application, and we can see some stalled connections... but the
>>> maxActive parameter is far bigger (100) than the actived connections
>>> shown by Introscope (24). This is happening with Tomcat 5.5 on
>>> CentOs
>>> using Java 1.6.
>>>
>> I don't know anything about Introscope.
>>
>> If maxActive is larger than the number of active connections, then
>> there's nothing wrong there, is there?  I'm not sure what you're
>> trying
>> to explain by that.
>>
>> If you can see some stalled connections, take a thread dump to see
>> what
>> they're doing/waiting on.
>>
>>
>> p
>>
>>
>>
>
>
> --
> Un saludo,
>
> Tom�s Tormo Franco
> Area de sistemas
>
> INDENOVA S.L.
> C/ Dels Traginers 14, 2� B
> Pol�gono Vara de Quart
> 46014 Valencia
> Tel. (34) 96 381 99 47
> Fax. (34) 96 381 99 48
>
> tto...@indenova.com
> http://www.indenova.com
>
> Desc�rguese gratuitamente el software eSigna Viewer para
> visualizar documentos firmados electr�nicamente: 
> http://www.indenova.com/eSignaViewer.
> php
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
> For additional commands, e-mail: users-h...@tomcat.apache.org
>

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org

Reply via email to