Re: Would like to monitor memory use offline

2008-08-12 Thread Christopher Schultz
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Richard, Richard S. Huntrods wrote: | I FIXED THE PROBLEM! | | Yep - totally fixed (tested and verified). | | What I decided to do was to move the close statements (and nulling RSMD) | into the FINALLY block - it seemed pointless to duplicate cod

Re: Would like to monitor memory use offline

2008-08-12 Thread Richard S. Huntrods
Chris, | If I close the resultset AND the statement, then the connector | should release all the objects created by those two. The connection is, | after all, just a pipe between the database and the java code. The | connector should not (IMO) be hanging on to statement or resultset | objects j

Re: Would like to monitor memory use offline

2008-08-12 Thread Christopher Schultz
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Richard, Richard S. Huntrods wrote: | I use a RSMD object in all my queries. I don't close | it. - MAYBE THAT's THE PROBLEM. I will test and report... Looking back at the JDBC API, I'm not sure you have any control over the RSMD query, result, etc.

Re: Would like to monitor memory use offline

2008-08-12 Thread Richard S. Huntrods
Richard, Richard S. Huntrods wrote: | Everything is local except the pooled connections, so I would say this | is the problem. This code was originally written before tomcat had good | connection pools, and so I had to write my own. The pool is basically a | vector of connections. I wouldn't wan

Re: Would like to monitor memory use offline

2008-08-12 Thread Christopher Schultz
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Richard, Richard S. Huntrods wrote: | Everything is local except the pooled connections, so I would say this | is the problem. This code was originally written before tomcat had good | connection pools, and so I had to write my own. The pool is basic

Re: Would like to monitor memory use offline

2008-08-11 Thread Richard S. Huntrods
Richard, Richard S. Huntrods wrote: |> Richard, |> |> Richard S. Huntrods wrote: |> |public static Vector listLookup(String table) { |> | //Connection connection = null; // connection is managed by a |> | connection pool |> |> So, is 'connection' a local or not? | It's part of my co

Re: Would like to monitor memory use offline

2008-08-11 Thread Christopher Schultz
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Richard, Richard S. Huntrods wrote: |> Richard, |> |> Richard S. Huntrods wrote: |> |public static Vector listLookup(String table) { |> | //Connection connection = null; // connection is managed by a |> | connection pool |> |> So, is 'con

Re: Would like to monitor memory use offline

2008-08-09 Thread Richard S. Huntrods
Richard, Richard S. Huntrods wrote: |public static Vector listLookup(String table) { | //Connection connection = null; // connection is managed by a | connection pool So, is 'connection' a local or not? It's part of my code (I use my own connection pool class) but not to the DBMS co

Re: Would like to monitor memory use offline

2008-08-08 Thread Christopher Schultz
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Richard, Richard S. Huntrods wrote: |public static Vector listLookup(String table) { | //Connection connection = null; // connection is managed by a | connection pool So, is 'connection' a local or not? |Statement statement = nu

Re: Would like to monitor memory use offline

2008-08-08 Thread Richard S. Huntrods
Chris, Richard, Richard S. Huntrods wrote: | In my code I was calling resultSet.close(), but not statement.close(). That'll do it. Actually, fixing it did NOT help. See more below... | The problem is, even though I verified (debug statements) that the call | is being made, the memory is ST

Re: Would like to monitor memory use offline

2008-08-07 Thread Christopher Schultz
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Richard, Richard S. Huntrods wrote: | In my code I was calling resultSet.close(), but not statement.close(). That'll do it. | The problem is, even though I verified (debug statements) that the call | is being made, the memory is STILL not being rel

Re: Would like to monitor memory use offline

2008-08-07 Thread Richard S. Huntrods
Well, thanks to Lamda probe and then to jmap, I have found my memory leak. Here are the gory details in case anyone is interested. It's not really a Tomcat issue, but rather the boundary between Tomcat and MySQL: I have a memory leak in my application, and jmap shows me that all my objects of

Re: Would like to monitor memory use offline

2008-08-07 Thread Philip Wigg
Hi, the manager application can return values in XML. You just need to hit:- http://localhost:8080/manager/status?XML=true or wherever it's located. This makes it a bit easier to write shell scripts based on Free Heap or Max Threads or whatever. I've got a perl script which checks whatever value

Re: Would like to monitor memory use offline

2008-08-06 Thread Richard S. Huntrods
To Ben & Mark, Thanks for the replies. I've been trying various things based on your suggestions. I find my best tool at the moment is "Lambda Probe" - though it hasn't been updated in a while, it does show me all the things (for the most part) that I wanted to watch. There's definitely some

Re: Would like to monitor memory use offline

2008-08-03 Thread Sameer Acharya
ect: Would like to monitor memory use offline > To: users@tomcat.apache.org > Date: Sunday, August 3, 2008, 7:48 AM > I've been running Tomcat for many versions now, mostly > without incident. > However with the latest set of upgrades rather > "forced" upon me al

Re: Would like to monitor memory use offline

2008-08-03 Thread Mark Thomas
Richard S. Huntrods wrote: SO - my question - is there a relatively easy way to create something (say a servlet) to watch the stack *just like I can do manually using the manager application* but email me when the stack approaches the memory limits? Richard, Tomcat is open source so if you w

Re: Would like to monitor memory use offline

2008-08-03 Thread Ben Stringer
On Sat, 2008-08-02 at 19:18 -0700, Richard S. Huntrods wrote: > > SO - my question - is there a relatively easy way to create something > (say a servlet) to watch the stack *just like I can do manually using > the manager application* but email me when the stack approaches the > memory limits?

Would like to monitor memory use offline

2008-08-02 Thread Richard S. Huntrods
I've been running Tomcat for many versions now, mostly without incident. However with the latest set of upgrades rather "forced" upon me all at once (instead of managed more properly), my application appears to have a severe memory leak. System Info: OS is Solaris 10-u5 (2008); java 1.6.0_06-b