Re: idea: log_statement_sample_rate - bottom limit for sampling

2019-11-06 Thread Tomas Vondra
On Wed, Nov 06, 2019 at 08:00:57PM +0100, Adrien Nayrat wrote: On 11/6/19 7:21 PM, Tomas Vondra wrote: I've pushed the reworked version of log_statement_sample_rate patch [1]. If I understand correctly, that makes this patch unnecessary, and we should mark it as rejected. Or do we still need it?

Re: idea: log_statement_sample_rate - bottom limit for sampling

2019-11-06 Thread Adrien Nayrat
On 11/6/19 7:21 PM, Tomas Vondra wrote: > I've pushed the reworked version of log_statement_sample_rate patch [1]. > If I understand correctly, that makes this patch unnecessary, and we > should mark it as rejected. Or do we still need it? Yes, the goal of this patch was to disable sampling and lo

Re: idea: log_statement_sample_rate - bottom limit for sampling

2019-11-06 Thread Tomas Vondra
On Sun, Aug 04, 2019 at 11:41:54PM +0200, Tomas Vondra wrote: On Sun, Aug 04, 2019 at 10:48:48PM +0200, Tomas Vondra wrote: On Sun, Aug 04, 2019 at 04:25:12PM -0400, Tom Lane wrote: Tomas Vondra writes: On Sun, Aug 04, 2019 at 03:16:12PM -0400, Tom Lane wrote: Isn't the issue here the intera

Re: idea: log_statement_sample_rate - bottom limit for sampling

2019-08-04 Thread Tomas Vondra
On Sun, Aug 04, 2019 at 10:48:48PM +0200, Tomas Vondra wrote: On Sun, Aug 04, 2019 at 04:25:12PM -0400, Tom Lane wrote: Tomas Vondra writes: On Sun, Aug 04, 2019 at 03:16:12PM -0400, Tom Lane wrote: Isn't the issue here the interaction between log_transaction_sample_rate and log_min_duration_

Re: idea: log_statement_sample_rate - bottom limit for sampling

2019-08-04 Thread Tomas Vondra
On Sun, Aug 04, 2019 at 04:25:12PM -0400, Tom Lane wrote: Tomas Vondra writes: On Sun, Aug 04, 2019 at 03:16:12PM -0400, Tom Lane wrote: Isn't the issue here the interaction between log_transaction_sample_rate and log_min_duration_statement? No, that interaction only affects statement-level

Re: idea: log_statement_sample_rate - bottom limit for sampling

2019-08-04 Thread Tom Lane
Tomas Vondra writes: > On Sun, Aug 04, 2019 at 03:16:12PM -0400, Tom Lane wrote: >> Isn't the issue here the interaction between log_transaction_sample_rate >> and log_min_duration_statement? > No, that interaction only affects statement-level sampling. OK, I was confusing the features. > For t

Re: idea: log_statement_sample_rate - bottom limit for sampling

2019-08-04 Thread Tomas Vondra
On Sun, Aug 04, 2019 at 03:16:12PM -0400, Tom Lane wrote: Tomas Vondra writes: OK, I have the revert ready. The one thing I'm wondering about is whether we need to revert log_transaction_sample_rate too? I think it's pretty much independent feature, so I think we can keep that. Opinions? Isn'

Re: idea: log_statement_sample_rate - bottom limit for sampling

2019-08-04 Thread Tom Lane
Tomas Vondra writes: > OK, I have the revert ready. The one thing I'm wondering about is > whether we need to revert log_transaction_sample_rate too? I think it's > pretty much independent feature, so I think we can keep that. Opinions? Isn't the issue here the interaction between log_transaction

Re: idea: log_statement_sample_rate - bottom limit for sampling

2019-08-04 Thread Tomas Vondra
On Fri, Aug 02, 2019 at 09:53:40AM +0200, Adrien Nayrat wrote: On 8/1/19 12:04 PM, Tomas Vondra wrote: On Thu, Aug 01, 2019 at 11:47:46AM +0200, Adrien Nayrat wrote: Hi, As we are at the end of this CF and there is still discussions about whether we should revert log_statement_sample_limit and

Re: idea: log_statement_sample_rate - bottom limit for sampling

2019-08-02 Thread Adrien Nayrat
On 8/1/19 12:04 PM, Tomas Vondra wrote: > On Thu, Aug 01, 2019 at 11:47:46AM +0200, Adrien Nayrat wrote: >> Hi, >> >> As we are at the end of this CF and there is still discussions about whether >> we >> should revert log_statement_sample_limit and log_statement_sample_rate, or >> try >> to fix i

Re: idea: log_statement_sample_rate - bottom limit for sampling

2019-08-01 Thread Tomas Vondra
On Thu, Aug 01, 2019 at 11:47:46AM +0200, Adrien Nayrat wrote: Hi, As we are at the end of this CF and there is still discussions about whether we should revert log_statement_sample_limit and log_statement_sample_rate, or try to fix it in v12. I moved this patch to next commit fest and change st

Re: idea: log_statement_sample_rate - bottom limit for sampling

2019-08-01 Thread Adrien Nayrat
Hi, As we are at the end of this CF and there is still discussions about whether we should revert log_statement_sample_limit and log_statement_sample_rate, or try to fix it in v12. I moved this patch to next commit fest and change status from "ready for commiter" to "need review". I hope I didn't

Re: idea: log_statement_sample_rate - bottom limit for sampling

2019-07-31 Thread Adrien Nayrat
On 7/28/19 12:19 AM, Tomas Vondra wrote: > Hi, > > I've started reviewing this patch, thinking that maybe I could get it > committed as it's marked as RFC. In general I agree with having this > fuature, but I think we need to rethink the GUC because the current > approach is just confusing. > > T

Re: idea: log_statement_sample_rate - bottom limit for sampling

2019-07-30 Thread Michael Paquier
On Tue, Jul 30, 2019 at 03:43:58PM -0400, Tom Lane wrote: > Well, we do not need to have a backwards-compatibility problem > here, because we have yet to release a version containing > log_statement_sample_rate. I do not think it's too late to decide > that v12's semantics for that are broken, and

Re: idea: log_statement_sample_rate - bottom limit for sampling

2019-07-30 Thread Tomas Vondra
On Tue, Jul 30, 2019 at 03:43:58PM -0400, Tom Lane wrote: Tomas Vondra writes: I've started reviewing this patch, thinking that maybe I could get it committed as it's marked as RFC. In general I agree with having this fuature, but I think we need to rethink the GUC because the current approach

Re: idea: log_statement_sample_rate - bottom limit for sampling

2019-07-30 Thread Tom Lane
Tomas Vondra writes: > I've started reviewing this patch, thinking that maybe I could get it > committed as it's marked as RFC. In general I agree with having this > fuature, but I think we need to rethink the GUC because the current > approach is just confusing. > ... > What I think we should do

Re: idea: log_statement_sample_rate - bottom limit for sampling

2019-07-27 Thread Tomas Vondra
Hi, I've started reviewing this patch, thinking that maybe I could get it committed as it's marked as RFC. In general I agree with having this fuature, but I think we need to rethink the GUC because the current approach is just confusing. The way the current patch works is that we have three GUC

Re: idea: log_statement_sample_rate - bottom limit for sampling

2019-07-12 Thread Pavel Stehule
Hi pá 12. 7. 2019 v 13:07 odesílatel Adrien Nayrat napsal: > The following review has been posted through the commitfest application: > make installcheck-world: tested, passed > Implements feature: tested, passed > Spec compliant: tested, passed > Documentation:teste

Re: idea: log_statement_sample_rate - bottom limit for sampling

2019-07-12 Thread Adrien Nayrat
The following review has been posted through the commitfest application: make installcheck-world: tested, passed Implements feature: tested, passed Spec compliant: tested, passed Documentation:tested, passed Sorry, I forgot to tick "passed" boxes.

Re: idea: log_statement_sample_rate - bottom limit for sampling

2019-07-12 Thread Adrien Nayrat
The following review has been posted through the commitfest application: make installcheck-world: tested, failed Implements feature: tested, failed Spec compliant: tested, failed Documentation:tested, failed I test the latest patch attached to this thread (log_stateme

Re: idea: log_statement_sample_rate - bottom limit for sampling

2019-06-19 Thread Pavel Stehule
st 19. 6. 2019 v 10:49 odesílatel Adrien Nayrat napsal: > On 6/18/19 8:29 PM, Pavel Stehule wrote: > > > > > > út 18. 6. 2019 v 14:03 odesílatel Adrien Nayrat < > adrien.nay...@anayrat.info > > > napsal: > > > > Hi, > > > > I tried the patch, here my com

Re: idea: log_statement_sample_rate - bottom limit for sampling

2019-06-19 Thread Adrien Nayrat
On 6/18/19 8:29 PM, Pavel Stehule wrote: > > > út 18. 6. 2019 v 14:03 odesílatel Adrien Nayrat > napsal: > > Hi, > > I tried the patch, here my comment: > > > gettext_noop("Zero effective disables sampling. " > >                          "-1

Re: idea: log_statement_sample_rate - bottom limit for sampling

2019-06-18 Thread Pavel Stehule
út 18. 6. 2019 v 14:03 odesílatel Adrien Nayrat napsal: > Hi, > > I tried the patch, here my comment: > > > gettext_noop("Zero effective disables sampling. " > > "-1 use sampling every time (without limit)."), > > I do not agree with the zero case. In fact, sampling is di

Re: idea: log_statement_sample_rate - bottom limit for sampling

2019-06-18 Thread Adrien Nayrat
Hi, I tried the patch, here my comment: > gettext_noop("Zero effective disables sampling. " > "-1 use sampling every time (without limit)."), I do not agree with the zero case. In fact, sampling is disabled as soon as setting is less than log_min_duration_statements. Fur

Re: idea: log_statement_sample_rate - bottom limit for sampling

2019-06-17 Thread Pavel Stehule
Hi po 17. 6. 2019 v 22:40 odesílatel Pavel Stehule napsal: > Hi > > čt 6. 6. 2019 v 10:48 odesílatel Gilles Darold napsal: > >> Le 06/06/2019 à 10:38, Pavel Stehule a écrit : >> > Hi >> > >> > I like the idea of sampling slow statements via >> > log_statement_sample_rate. But I miss some parame

Re: idea: log_statement_sample_rate - bottom limit for sampling

2019-06-17 Thread Pavel Stehule
Hi čt 6. 6. 2019 v 10:48 odesílatel Gilles Darold napsal: > Le 06/06/2019 à 10:38, Pavel Stehule a écrit : > > Hi > > > > I like the idea of sampling slow statements via > > log_statement_sample_rate. But I miss some parameter that can ensure > > so every query executed over this limit is logged

Re: idea: log_statement_sample_rate - bottom limit for sampling

2019-06-06 Thread Gilles Darold
Le 06/06/2019 à 10:38, Pavel Stehule a écrit : > Hi > > I like the idea of sampling slow statements via  > log_statement_sample_rate. But I miss some parameter that can ensure > so every query executed over this limit is logged. > > Can we introduce new option > > log_statement_sampling_limit > > T

idea: log_statement_sample_rate - bottom limit for sampling

2019-06-06 Thread Pavel Stehule
Hi I like the idea of sampling slow statements via log_statement_sample_rate. But I miss some parameter that can ensure so every query executed over this limit is logged. Can we introduce new option log_statement_sampling_limit The query with execution time over this limit is logged every time