On 29/07/2003 07:18 LEON wrote:
I use tomcat+linux_postgresql+jsp to develop system.

I start postgresql with 1024 processes.
FE:
postmaster -i -S -N 1024 -B 2048 -D /var/lib/pgsql/data

My jsp doesn't implement connection pool.It directly connects postgresql
by jdbc.

IME, that is not a good way to do it. Use a connection pool.


After I run the Ui some times, the UI(jsp) would report "ieSorry,too many
clientslg" .The exception is SQLException.

I must restart tomcat or postgresql I can continue to running my UI.

My guess would be that you have a bug in your application which is not always closing the connection so eventually you exceed max_connections. You should always close the connection in a finally{} block so that is guaranteed that it will be closed regardless of any earlier exceptions which are thrown.


HTH

--
Paul Thomas
+------------------------------+---------------------------------------------+
| Thomas Micro Systems Limited | Software Solutions for the Smaller Business |
| Computer Consultants | http://www.thomas-micro-systems-ltd.co.uk |
+------------------------------+---------------------------------------------+


---------------------------(end of broadcast)---------------------------
TIP 6: Have you searched our list archives?

http://archives.postgresql.org

Reply via email to