From: | Vik Fearing <vik(dot)fearing(at)2ndquadrant(dot)com> |
---|---|
To: | Adrien Nayrat <adrien(dot)nayrat(at)anayrat(dot)info>, Michael Paquier <michael(at)paquier(dot)xyz> |
Cc: | David Rowley <david(dot)rowley(at)2ndquadrant(dot)com>, PostgreSQL mailing lists <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: New GUC to sample log queries |
Date: | 2018-07-15 10:53:29 |
Message-ID: | f994f21f-3782-8ef8-8f48-26f0f3af9405@2ndquadrant.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On 10/07/18 20:34, Adrien Nayrat wrote:
> On 06/27/2018 11:13 PM, Adrien Nayrat wrote:
>>> 3) Is it intentional to only sample with log_min_duration_statement and
>>> not also with log_duration? It seems like it should affect both. In
>>> both cases, the name is too generic. Something called "log_sample_rate"
>>> should sample **everything**.
>> I do not think it could be useful to sample other case such as log_duration.
>>
>> But yes, the GUC is confusing and I am not comfortable to introduce a new GUC in
>> my initial patch.
>>
>> Maybe we should adapt current GUC with something like :
>>
>> log_min_duration_statement = <time>,<sample rate>>
>> This give :
>>
>> log_min_duration_statement = 0,0.1
>>
>> Equivalent to :
>> log_min_duration_statement = 0
>> log_sample_rate = 0.1
>>
>> Thought?
>>
>
> After reflection it seems a bad idea :
>
> * it breaks compatibility with external tools
> * it introduce a kind of "composite" GUC which may add complexity to use. For
> example in pg_settings view.
Yes, I think that was a very bad idea.
> What do you think of : log_min_duration_statement_sample ?
Hmm. Not sure if that last word should be _sample, _sampling, _rate, or
a combination of those.
> Is it too long?
I introduced idle_in_transaction_session_timeout, so I'm not one to say
a setting name is too long :)
--
Vik Fearing +33 6 46 75 15 36
http://2ndQuadrant.fr PostgreSQL : Expertise, Formation et Support
From | Date | Subject | |
---|---|---|---|
Next Message | Amit Kapila | 2018-07-15 11:09:50 | Re: YA race condition in 001_stream_rep.pl (was Re: pgsql: Allow using the updated tuple while moving it to a different par) |
Previous Message | Alexander Lakhin | 2018-07-15 10:32:59 | Re: make installcheck-world in a clean environment |