Re: [GENERAL] plpyhton

Поиск
Список
Период
Сортировка
От Joshua Tolley
Тема Re: [GENERAL] plpyhton
Дата
Msg-id 4cefdab2.16958e0a.588d.ffff9748@mx.google.com
обсуждение исходный текст
Ответ на Re: [GENERAL] plpyhton  (c k <shreeseva.learning@gmail.com>)
Список pgsql-admin
On Fri, Nov 26, 2010 at 05:28:52PM +0530, c k wrote:
> Thanks for your reply.
> But if a database has 100+ connections then isn't loading any such
> interpreter consumes more memory and requires more CPU? Does all PL
> languages behave in the same fashion?

If there are lots of connections, and each calls a plpython function (for
example), then each will load a python interpreter, and certainly that could
add up to serious memory usage. I can't speak for *every* PL; C functions
don't load any special interpreter, for instance, and I don't think there's
anything special you have to load to run SQL functions, beyond what gets
loaded anyway.

If you have problems with hundreds of connections using too much memory when
each loads an interpreter, you ought to consider getting more memory, using a
connection pooler, changing how you do things, or some combination of the
above.

--
Joshua Tolley / eggyknap
End Point Corporation
http://www.endpoint.com

Вложения

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

Предыдущее
От: c k
Дата:
Сообщение: Re: [GENERAL] plpyhton
Следующее
От: Dimitri Fontaine
Дата:
Сообщение: Re: Pre-Allocate tablespace on disk