Re: Hung backends
От | Joseph Shraibman |
---|---|
Тема | Re: Hung backends |
Дата | |
Msg-id | 3A22F3DE.31F45B28@selectacast.net обсуждение исходный текст |
Ответ на | Re: Hung backends (Tom Lane <tgl@sss.pgh.pa.us>) |
Список | pgsql-general |
Tom Lane wrote: > > "Schmidt, Peter" <peter.schmidt@prismedia.com> writes: > > It turned out the Java VM was still running on the clients, keeping TCP > > connections open (exactly as you suggested). > > Hmm, so the VM forgets to close connections belonging to a crashed > Java thread? Seems like a severe deficiency in the VM to me... > > regards, tom lane There is no such thing as a crashed java thread. It either terminated or is still running. You are supposed to explictly close your connections to the db in java. If you don't you will have to wait until the Connection object is garbage collected for it to be closed. If your java app is sitting around not doing much then it might never get around to calling the garbage collector. Bottom line: 1) expliclty close connections yourself 2) Call System.gc() from time to time if you need to. -- Joseph Shraibman jks@selectacast.net Increase signal to noise ratio. http://www.targabot.com
В списке pgsql-general по дате отправления: