|
patch: add a finalizer to AbstractJdbc1Statement: msg#00182db.postgresql.jdbc
This patch adds a finalizer to AbstractJdbc1Statement that closes the statement. Without this, when server-side preparation is in use statements that are executed then discarded without an explicit close() will leak resources on the backend while that connection remains open, as a DEALLOCATE never gets executed. Objects with a finalizer are more expensive to create (depending on the VM). If it's too much of a price to pay in the general case, there's another approach that uses phantom references and only pays the cost when backend resources are actually allocated, but the code becomes much more complex. -O
---------------------------(end of broadcast)--------------------------- TIP 1: subscribe and unsubscribe commands go to majordomo@xxxxxxxxxxxxxx |
|
| <Prev in Thread] | Current Thread | [Next in Thread> |
|---|---|---|
| Previous by Date: | patch: fix 'compile' target to do correct dependency checking: 00182, Oliver Jowett |
|---|---|
| Next by Date: | Re: Bug #926: if old postgresql.jar in CLASSPATH, ant fails: 00182, Palle Girgensohn |
| Previous by Thread: | patch: fix 'compile' target to do correct dependency checkingi: 00182, Oliver Jowett |
| Next by Thread: | Re: patch: add a finalizer to AbstractJdbc1Statement: 00182, Paul Thomas |
| Indexes: | [Date] [Thread] [Top] [All Lists] |
| News | FAQ | advertise |