pg_stat_statements in core
От | ITAGAKI Takahiro |
---|---|
Тема | pg_stat_statements in core |
Дата | |
Msg-id | 20081021134140.811D.52131E4D@oss.ntt.co.jp обсуждение исходный текст |
Ответ на | Re: contrib/pg_stat_statements (ITAGAKI Takahiro <itagaki.takahiro@oss.ntt.co.jp>) |
Ответы |
Re: pg_stat_statements in core
|
Список | pgsql-hackers |
I wrote: > Now I'm working on storing statistics into disks on server > shutdown. If it is impossible unless the module is in core, > I would change my policy... I reconsidered this part and found that pg_stat_statements needs to be in core to write stats in file on server shutdown because: 1. shared_preload_libraries are only loaded in postmaster and backends. 2. Postmaster should write stats file because itis the only process that knows when to shutdown. 3. Postmaster cannot attach shared memory which contains statementstats because it cannot acquire LWLocks at all. My next plan is put pg_stat_statements into core and treat it just like as freespacemap in 8.3 or before. Stats file is read by bootstrap process and written down by bgwriter process. All of the codes in pg_stat_statements will be merged into pgstat.c and some of interface functions will be called from ExecutorRun instead of using ExecutorRun_hook. If no objections, I'll go ahead in the direction. Regards, --- ITAGAKI Takahiro NTT Open Source Software Center
В списке pgsql-hackers по дате отправления: