Re: Allow auto_explain to log to NOTICE

2019-01-31 Thread Daniel Gustafsson
> On 5 Jan 2019, at 01:04, Michael Paquier wrote: > > On Fri, Jan 04, 2019 at 02:45:55PM +0100, Daniel Gustafsson wrote: >> (Michael: sorry for not having responded to your comments on the patch, $life >> has had little time over for hacking lately) > > No worries, I understand. > >> There is t

Re: Allow auto_explain to log to NOTICE

2019-01-04 Thread Michael Paquier
On Fri, Jan 04, 2019 at 02:45:55PM +0100, Daniel Gustafsson wrote: > (Michael: sorry for not having responded to your comments on the patch, $life > has had little time over for hacking lately) No worries, I understand. > There is that. We might not be excited about writing tests for this > cont

Re: Allow auto_explain to log to NOTICE

2019-01-04 Thread Daniel Gustafsson
(Michael: sorry for not having responded to your comments on the patch, $life has had little time over for hacking lately) > On 4 Jan 2019, at 13:49, Michael Paquier wrote: > > On Fri, Jan 04, 2019 at 01:06:24PM +0100, Peter Eisentraut wrote: >> Do we really want to add user-facing options just

Re: Allow auto_explain to log to NOTICE

2019-01-04 Thread Michael Paquier
On Fri, Jan 04, 2019 at 01:06:24PM +0100, Peter Eisentraut wrote: > Do we really want to add user-facing options just to be able to run > tests? Should we write the tests differently instead? The take is that the output of the plans generated includes data which is run-dependent because the durat

Re: Allow auto_explain to log to NOTICE

2019-01-04 Thread Peter Eisentraut
On 26/12/2018 06:42, Michael Paquier wrote: > On Tue, Oct 30, 2018 at 11:44:42AM +0100, Daniel Gustafsson wrote: >> Circling back to this, I updated the patch with providing another >> option as I couldn’t think of another way to do it cleanly. I’ll >> add the patch to the next CF but as it’s just

Re: Allow auto_explain to log to NOTICE

2018-12-25 Thread Michael Paquier
On Tue, Oct 30, 2018 at 11:44:42AM +0100, Daniel Gustafsson wrote: > Circling back to this, I updated the patch with providing another > option as I couldn’t think of another way to do it cleanly. I’ll > add the patch to the next CF but as it’s just about to start it > should be moved to the next

Re: Allow auto_explain to log to NOTICE

2018-10-30 Thread Daniel Gustafsson
> On 31 Jul 2018, at 14:23, Andrew Dunstan > wrote: >> I’m not sure it’s worth adding this much to the code just to be able to test >> it, but it seemed like a good excercise to write to have something to reason >> about. > > I think it probably is, buit I'm not very happy about the hack, so I

Re: Allow auto_explain to log to NOTICE

2018-07-31 Thread Andrew Dunstan
On 07/17/2018 02:03 PM, Daniel Gustafsson wrote: On 17 Jul 2018, at 19:11, Andrew Dunstan wrote: On 07/17/2018 12:04 PM, Daniel Gustafsson wrote: Since DEBUG is not a defined loglevel, it seems superfluous to include it here. It’s also omitted from the documentation so it should probably be

Re: Allow auto_explain to log to NOTICE

2018-07-17 Thread Daniel Gustafsson
> On 17 Jul 2018, at 19:11, Andrew Dunstan > wrote: > > On 07/17/2018 12:04 PM, Daniel Gustafsson wrote: >> Since DEBUG is not a defined loglevel, it seems superfluous to include it >> here. >> It’s also omitted from the documentation so it should probably be omitted >> from >> here. >> >> +

Re: Allow auto_explain to log to NOTICE

2018-07-17 Thread Andrew Dunstan
On 07/17/2018 12:04 PM, Daniel Gustafsson wrote: On 4 Jul 2018, at 15:34, Andrew Dunstan wrote: On Wed, Jun 20, 2018 at 2:06 PM, Daniel Gustafsson wrote: On 27 Apr 2018, at 04:24, Andres Freund wrote: On 2018-04-27 11:52:18 +0930, Tom Dunstan wrote: I'd argue this should contain the non

Re: Allow auto_explain to log to NOTICE

2018-07-17 Thread Daniel Gustafsson
> On 4 Jul 2018, at 15:34, Andrew Dunstan > wrote: > > On Wed, Jun 20, 2018 at 2:06 PM, Daniel Gustafsson wrote: >>> On 27 Apr 2018, at 04:24, Andres Freund wrote: >>> >>> On 2018-04-27 11:52:18 +0930, Tom Dunstan wrote: > I'd argue this should contain the non-error cases. It's just as >>

Re: Allow auto_explain to log to NOTICE

2018-07-04 Thread Andrew Dunstan
On Wed, Jun 20, 2018 at 2:06 PM, Daniel Gustafsson wrote: >> On 27 Apr 2018, at 04:24, Andres Freund wrote: >> >> On 2018-04-27 11:52:18 +0930, Tom Dunstan wrote: I'd argue this should contain the non-error cases. It's just as reasonable to want to add this as a debug level or such. >>>

Re: Allow auto_explain to log to NOTICE

2018-06-20 Thread Daniel Gustafsson
> On 27 Apr 2018, at 04:24, Andres Freund wrote: > > On 2018-04-27 11:52:18 +0930, Tom Dunstan wrote: >>> I'd argue this should contain the non-error cases. It's just as >>> reasonable to want to add this as a debug level or such. >> >> So all of warning, info, debug and debug1-5? > > Yea. Like

Re: Allow auto_explain to log to NOTICE

2018-04-26 Thread Andrew Gierth
> "Tom" == Tom Dunstan writes: Tom> Hi all Tom> This patch allows a user to configure auto_explain to log to Tom> NOTICE instead of the server log. This allows automated testing of Tom> application-generated queries to ensure correct plans etc from Tom> code that can inspect returned n

Re: Allow auto_explain to log to NOTICE

2018-04-26 Thread Andres Freund
On 2018-04-27 11:52:18 +0930, Tom Dunstan wrote: > > I'd argue this should contain the non-error cases. It's just as > > reasonable to want to add this as a debug level or such. > > > > So all of warning, info, debug and debug1-5? Yea. Likely nobody will ever use debug5, but I don't see a point m

Re: Allow auto_explain to log to NOTICE

2018-04-26 Thread Tom Dunstan
(Resent with subscribed email address, thanks gmail) Hi Andres, thanks for the extremely fast review! On 27 April 2018 at 11:46, Andres Freund wrote: > > > I don't see any tests for auto_explain so haven't added any test cases. > >> > Happy to do so if that's deemed necessary. > >> > I'd be in

Re: Allow auto_explain to log to NOTICE

2018-04-26 Thread Andres Freund
Hi, On 2018-04-27 11:43:58 +0930, Tom Dunstan wrote: > This patch allows a user to configure auto_explain to log to NOTICE instead > of the server log. This allows automated testing of application-generated > queries to ensure correct plans etc from code that can inspect returned > notices but not

Allow auto_explain to log to NOTICE

2018-04-26 Thread Tom Dunstan
Hi all This patch allows a user to configure auto_explain to log to NOTICE instead of the server log. This allows automated testing of application-generated queries to ensure correct plans etc from code that can inspect returned notices but not the server log. I don't see any tests for auto_expla