compute_query_id

Поиск
Список
Период
Сортировка
От Vijaykumar Jain
Тема compute_query_id
Дата
Msg-id CAM+6J945dckHgp7f_nvuOpcOxJLoXsKRtPH6zhFFJZ8f7Ox_ag@mail.gmail.com
обсуждение исходный текст
Ответы Re: compute_query_id
Список pgsql-general
hi,

I noticed this new param compute_query_id in pg14beta.
it is interesting as I was long wanting to identify a query with a unique id like we have for http requests etc so that we can trace the query all the way to shards via FDW etc.

but i cannot see them in the logs even after setting compute_query_id on.
i also read
compute_query_id_query  for the same.
how is the compute_query_id actually calculated? 
why does it show 0 in logs for random sql queries. 
log_line_prefix = '%Q :'
0 :LOG:  statement: select * from pg_stat_activity;

i mean pid already was doing the job to identify the query and its children even it logs,
but i know pid will get recycled.

tldr;
how is compute_query_id different from pid to identify some query running ?
can it be passed on to FDW queries ? for tracing etc ?

am i totally getting its use case totally wrong :) 


--
Thanks,
Vijay
Mumbai, India

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

Предыдущее
От: Celia McInnis
Дата:
Сообщение: Treating float arrays as vectors?
Следующее
От: Julien Rouhaud
Дата:
Сообщение: Re: compute_query_id