Re: Connections with Tomcat 3.2.4 and PostgreSQL 7.1.3

From: "Dave Cramer" <Dave(at)micro-automation(dot)net>
To: "'Justin Clift'" <justin(at)postgresql(dot)org>, "'Tony Grant'" <tony(at)animaproductions(dot)com>
Cc: <pgsql-jdbc(at)postgresql(dot)org>, "'Hari Yellina'" <hyellina(at)iprimus(dot)com(dot)au>
Subject: Re: Connections with Tomcat 3.2.4 and PostgreSQL 7.1.3
Date: 2002-03-06 12:21:34
Message-ID: 012001c1c509$74e27420$8201a8c0@inspiron
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-jdbc

Justin,

Because Garbage Collection is not a guaranteed process. You have no
guarantee when it is going to run. This could get you into a situation
where you have no more connections and no way to get them.

A much better solution is a pool, then you don't incur the overhead of
starting the connection.

Dave

-----Original Message-----
From: pgsql-jdbc-owner(at)postgresql(dot)org
[mailto:pgsql-jdbc-owner(at)postgresql(dot)org] On Behalf Of Justin Clift
Sent: Wednesday, March 06, 2002 1:46 AM
To: Tony Grant
Cc: pgsql-jdbc(at)postgresql(dot)org; Hari Yellina
Subject: Re: [JDBC] Connections with Tomcat 3.2.4 and PostgreSQL 7.1.3

Hi Tony,

The java guys here are wondering why it's necessary to explicitely close
the connections to the database in their .jsp's, as the java garbage
collector should do this automatically?

:-)

Regards and best wishes,

Justin Clift

--
"My grandfather once told me that there are two kinds of people: those
who work and those who take the credit. He told me to try to be in the
first group; there was less competition there."
- Indira Gandhi

---------------------------(end of broadcast)---------------------------
TIP 3: if posting/reading through Usenet, please send an appropriate
subscribe-nomail command to majordomo(at)postgresql(dot)org so that your
message can get through to the mailing list cleanly

In response to

Browse pgsql-jdbc by date

  From Date Subject
Next Message Dave Cramer 2002-03-06 12:30:40 Re: Connections with Tomcat 3.2.4 and PostgreSQL 7.1.3
Previous Message tsmets 2002-03-06 10:26:45 Re: Connections with Tomcat 3.2.4 and PostgreSQL 7.1.3