connection pooling and open statement objects

From: "G(dot)Nagarajan" <gnagarajan(at)dkf(dot)de>
To: <pgsql-jdbc(at)postgresql(dot)org>
Subject: connection pooling and open statement objects
Date: 2002-09-09 14:09:52
Message-ID: NFBBIOPECKPCJJHHBOGJKEDPDHAA.gnagarajan@dkf.de
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-jdbc

hi,

In an earlier discussion, someone had remarked that if the statment
objects are not explicitly closed, the resources allocated to it are not
released. ie, I have code like this:

- get Connection object from connection pool
- create statement object
- create resultset using the statement
- process the resultset
- return the connection object to the connection pool

This cycle is repeated for all the sql statements in the application. If
the
memory will not be released till the statement object is explicitly closed,
then it
might lead to a memory leak later.

any suggestion or remarks are welcome

regards,
Nagarajan.

Responses

Browse pgsql-jdbc by date

  From Date Subject
Next Message Dave Cramer 2002-09-09 14:21:42 Re: connection pooling and open statement objects
Previous Message Fred Tsang 2002-09-09 10:48:32 Re: compile of jdbc driver failed - jdk 1.4.0_01