Re: Memory leaks using refcursors

Поиск
Список
Период
Сортировка
От Guillaume Smet
Тема Re: Memory leaks using refcursors
Дата
Msg-id 1d4e0c10701171527u744fd81eh6de7908599349af3@mail.gmail.com
обсуждение исходный текст
Ответ на Re: Memory leaks using refcursors  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-jdbc
Hi Tom,

On 1/17/07, Tom Lane <tgl@sss.pgh.pa.us> wrote:
> While I agree that the driver probably should do that, I'm not sure why
> you are having a problem.  A cursor doesn't normally accumulate its
> result set in memory on the backend side, so I wouldn't have expected
> all that big a memory leak.  What queries are you executing?

I don't know exactly how much queries are executed during this
transaction but it's a lot of queries and they are _all_ executed
through stored proc returning cursors.

The self contained test case is available here:
http://people.openwide.fr/~gsmet/postgresql/refcursor_problem/ and
especially the stored proc is in the readme file along with all the
instructions to run the test case.

I just run a test case with 10k iterations and the backend which
executes the queries uses 236 MB of memory before the commit.

--
Guillaume

В списке pgsql-jdbc по дате отправления:

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: Memory leaks using refcursors
Следующее
От: Dave Cramer
Дата:
Сообщение: Re: Memory leaks using refcursors