Re: Horrible trigger performance after upgrade 8.0.12 -> 8.2.3
В списке pgsql-performance по дате отправления:
| От | Tom Lane |
|---|---|
| Тема | Re: Horrible trigger performance after upgrade 8.0.12 -> 8.2.3 |
| Дата | |
| Msg-id | 16985.1174420705@sss.pgh.pa.us обсуждение исходный текст |
| Ответ на | Horrible trigger performance after upgrade 8.0.12 -> 8.2.3 (Joseph S <jks@selectacast.net>) |
| Список | pgsql-performance |
Joseph S <jks@selectacast.net> writes:
> After upgrading to 8.2.3 INSERTs and UPDATEs on one of my tables became
> incredibly slow. I traced the problem to one of my triggers that calls
> one of my defined functions (that is IMMUTABLE). If I inline the
> function instead of calling it the runtime for my test update drops from
> 10261.234 ms to 564.094 ms. The time running the trigger itself
> dropped from 9749.910 to 99.504.
With no more details than that, I don't see how you expect any useful
comments. Let's see the code. Also, what PG version are you comparing to?
> BTW does make any sense to bother marking trigger functions as STABLE or
> IMMUTABLE?
No, the trigger mechanisms don't pay any attention to that. I can
hardly conceive of a useful trigger that wouldn't be VOLATILE anyway,
since side effects are more or less the point.
regards, tom lane
В списке pgsql-performance по дате отправления:
Сайт использует файлы cookie для корректной работы и повышения удобства. Нажимая кнопку «Принять» или продолжая пользоваться сайтом, вы соглашаетесь на их использование в соответствии с Политикой в отношении обработки cookie ООО «ППГ», в том числе на передачу данных из файлов cookie сторонним статистическим и рекламным службам. Вы можете управлять настройками cookie через параметры вашего браузера