Re: Allow pooled connections to list all prepared queries
| От | Christopher Kings-Lynne |
|---|---|
| Тема | Re: Allow pooled connections to list all prepared queries |
| Дата | |
| Msg-id | 41CE2B0B.50601@familyhealth.com.au обсуждение исходный текст |
| Ответ на | Re: Allow pooled connections to list all prepared queries (Tom Lane <tgl@sss.pgh.pa.us>) |
| Список | pgsql-patches |
> The usefulness of this seems pretty dubious. You aren't going to have a > bunch of random bits of code sharing a connection; it's going to be a > single application that probably knows perfectly well exactly which > queries it needs prepared. So I don't think the stats will pay for > themselves. Not true. Personally, I was looking for something like this, before I decided to go with stored sql procs instead. The problem is a website that uses persistent connections. Say we have a query that takes 350ms to get threads in a forum, and half of that is planning time. Any particular PHP process does not know if a previous process has already prepared that query or not. So I have to prepare it every time, deal with errors, etc. However, I now use sql stored procs as basically 'cached prepared queries', so it's no longer a problem for me. Chris
В списке pgsql-patches по дате отправления: