Re: ALTER SYSTEM SET command to change postgresql.conf parameters (RE: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review])

2013-06-21 Thread Robert Haas
On Thu, Jun 20, 2013 at 12:18 AM, Amit Kapila amit.kap...@huawei.com wrote: Auto.conf- 1 Vote (Josh) System.auto.conf - 1 Vote (Josh) Postgresql.auto.conf - 2 Votes (Zoltan, Amit) Persistent.auto.conf - 0 Vote generated_by_server.conf - 1 Vote (Peter E) System.conf

Re: ALTER SYSTEM SET command to change postgresql.conf parameters (RE: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review])

2013-06-21 Thread Amit kapila
On Friday, June 21, 2013 11:48 PM Robert Haas wrote: On Thu, Jun 20, 2013 at 12:18 AM, Amit Kapila amit.kap...@huawei.com wrote: Auto.conf- 1 Vote (Josh) System.auto.conf - 1 Vote (Josh) Postgresql.auto.conf - 2 Votes (Zoltan, Amit) Persistent.auto.conf - 0 Vote

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review]

2013-06-21 Thread Amit kapila
On Friday, June 21, 2013 11:43 PM Robert Haas wrote: On Fri, Jun 21, 2013 at 12:56 PM, Fujii Masao masao.fu...@gmail.com wrote: On Sat, Jun 22, 2013 at 12:11 AM, Robert Haas robertmh...@gmail.com wrote: On Wed, Jun 19, 2013 at 1:59 PM, Peter Eisentraut pete...@gmx.net wrote: On 6/7/13 12:14 AM,

Re: ALTER SYSTEM SET command to change postgresql.conf parameters (RE: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review])

2013-06-19 Thread Amit Kapila
On Tuesday, June 18, 2013 11:25 PM Josh Berkus wrote: Amit, I think, the decision of name, we can leave to committer with below possibilities, as it is very difficult to build consensus on any particular name. Auto.conf System.auto.conf Postgresql.auto.conf Persistent.auto.conf

Re: ALTER SYSTEM SET command to change postgresql.conf parameters (RE: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review])

2013-06-19 Thread Peter Eisentraut
On 6/13/13 5:47 PM, Josh Berkus wrote: 2. File name to store settings set by ALTER SYSTEM command is still persistent.auto.conf Why? Shouldn't it just be auto.conf? Or system.auto.conf? I prefer auto.conf, personally. Well, not much about it is automatic, really. It's just set

Re: ALTER SYSTEM SET command to change postgresql.conf parameters (RE: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review])

2013-06-19 Thread Josh Berkus
On 06/19/2013 10:48 AM, Peter Eisentraut wrote: On 6/13/13 5:47 PM, Josh Berkus wrote: 2. File name to store settings set by ALTER SYSTEM command is still persistent.auto.conf Why? Shouldn't it just be auto.conf? Or system.auto.conf? I prefer auto.conf, personally. Well, not much about

Re: ALTER SYSTEM SET command to change postgresql.conf parameters (RE: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review])

2013-06-19 Thread Peter Eisentraut
On 6/19/13 1:49 PM, Josh Berkus wrote: On 06/19/2013 10:48 AM, Peter Eisentraut wrote: On 6/13/13 5:47 PM, Josh Berkus wrote: 2. File name to store settings set by ALTER SYSTEM command is still persistent.auto.conf Why? Shouldn't it just be auto.conf? Or system.auto.conf? I prefer

Re: ALTER SYSTEM SET command to change postgresql.conf parameters (RE: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review])

2013-06-19 Thread Magnus Hagander
On Jun 19, 2013 7:55 PM, Peter Eisentraut pete...@gmx.net wrote: On 6/19/13 1:49 PM, Josh Berkus wrote: On 06/19/2013 10:48 AM, Peter Eisentraut wrote: On 6/13/13 5:47 PM, Josh Berkus wrote: 2. File name to store settings set by ALTER SYSTEM command is still persistent.auto.conf Why?

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review]

2013-06-19 Thread Peter Eisentraut
On 6/7/13 12:14 AM, Amit Kapila wrote: I will change the patch as per below syntax if there are no objections: ALTER SYSTEM SET configuration_parameter {TO | =} {value, | 'value'}; I do like using ALTER SYSTEM in general, but now that I think about it, the 9.3 feature to create global

Re: ALTER SYSTEM SET command to change postgresql.conf parameters (RE: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review])

2013-06-19 Thread Alvaro Herrera
Magnus Hagander wrote: On Jun 19, 2013 7:55 PM, Peter Eisentraut pete...@gmx.net wrote: generated_by_server.conf System.conf? alter_system.conf ? -- Álvaro Herrerahttp://www.2ndQuadrant.com/ PostgreSQL Development, 24x7 Support, Training Services -- Sent via

Re: ALTER SYSTEM SET command to change postgresql.conf parameters (RE: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review])

2013-06-19 Thread Tom Lane
Josh Berkus j...@agliodbs.com writes: True, but can you think of a better word to mean don't edit this by hand? The file name is not nearly as important for that as putting in a header comment # Don't edit this file by hand. regards, tom lane -- Sent via pgsql-hackers

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review]

2013-06-19 Thread Amit Kapila
On Wednesday, June 19, 2013 11:30 PM Peter Eisentraut wrote: On 6/7/13 12:14 AM, Amit Kapila wrote: I will change the patch as per below syntax if there are no objections: ALTER SYSTEM SET configuration_parameter {TO | =} {value, | 'value'}; I do like using ALTER SYSTEM in general,

Re: ALTER SYSTEM SET command to change postgresql.conf parameters (RE: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review])

2013-06-19 Thread Amit Kapila
On Thursday, June 20, 2013 3:53 AM Tom Lane wrote: Josh Berkus j...@agliodbs.com writes: True, but can you think of a better word to mean don't edit this by hand? The file name is not nearly as important for that as putting in a header comment # Don't edit this file by hand. Currently

Re: ALTER SYSTEM SET command to change postgresql.conf parameters (RE: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review])

2013-06-19 Thread Amit Kapila
On Thursday, June 20, 2013 12:32 AM Alvaro Herrera wrote: Magnus Hagander wrote: On Jun 19, 2013 7:55 PM, Peter Eisentraut pete...@gmx.net wrote: generated_by_server.conf System.conf? alter_system.conf ? All the names proposed in this thread are as follows: Auto.conf-

Re: ALTER SYSTEM SET command to change postgresql.conf parameters (RE: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review])

2013-06-19 Thread Alvaro Herrera
Amit Kapila wrote: Currently header comment is: # Do not edit this file manually! # It will be overwritten by ALTER SYSTEM command. Kindly let me know your suggestion about the above comment in header? This seems perfect to me. -- Álvaro Herrera

Re: ALTER SYSTEM SET command to change postgresql.conf parameters (RE: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review])

2013-06-18 Thread Boszormenyi Zoltan
Hi, review below. 2013-06-13 14:35 keltezéssel, Amit Kapila írta: On Friday, June 07, 2013 9:45 AM Amit Kapila wrote: On Thursday, June 06, 2013 10:22 PM Robert Haas wrote: On Wed, Jun 5, 2013 at 7:24 AM, Amit Kapila amit.kap...@huawei.com wrote: On Monday, May 27, 2013 4:17 PM Amit Kapila

Re: ALTER SYSTEM SET command to change postgresql.conf parameters (RE: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review])

2013-06-18 Thread Boszormenyi Zoltan
2013-06-14 05:12 keltezéssel, Amit Kapila írta: On Friday, June 14, 2013 3:17 AM Josh Berkus wrote: On 06/13/2013 05:35 AM, Amit Kapila wrote: On Friday, June 07, 2013 9:45 AM Amit Kapila wrote: On Thursday, June 06, 2013 10:22 PM Robert Haas wrote: On Wed, Jun 5, 2013 at 7:24 AM, Amit

Re: ALTER SYSTEM SET command to change postgresql.conf parameters (RE: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review])

2013-06-18 Thread Amit Kapila
On Tuesday, June 18, 2013 3:26 PM Boszormenyi Zoltan wrote: Hi, review below. Thanks for the review. There are 2 options to proceed for this patch for 9.4 1. Upload the SET PERSISTENT syntax patch for coming CF by fixing existing review comments 2. Implement new syntax ALTER SYSTEM as

Re: ALTER SYSTEM SET command to change postgresql.conf parameters (RE: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review])

2013-06-18 Thread Boszormenyi Zoltan
2013-06-18 14:11 keltezéssel, Amit Kapila írta: On Tuesday, June 18, 2013 3:26 PM Boszormenyi Zoltan wrote: Hi, review below. Thanks for the review. There are 2 options to proceed for this patch for 9.4 1. Upload the SET PERSISTENT syntax patch for coming CF by fixing existing review

Re: ALTER SYSTEM SET command to change postgresql.conf parameters (RE: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review])

2013-06-18 Thread Josh Berkus
Amit, I think, the decision of name, we can leave to committer with below possibilities, as it is very difficult to build consensus on any particular name. Auto.conf System.auto.conf Postgresql.auto.conf Persistent.auto.conf Reasons for auto.conf as a choice above all of the previous:

Re: ALTER SYSTEM SET command to change postgresql.conf parameters (RE: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review])

2013-06-13 Thread Josh Berkus
On 06/13/2013 05:35 AM, Amit Kapila wrote: On Friday, June 07, 2013 9:45 AM Amit Kapila wrote: On Thursday, June 06, 2013 10:22 PM Robert Haas wrote: On Wed, Jun 5, 2013 at 7:24 AM, Amit Kapila amit.kap...@huawei.com wrote: On Monday, May 27, 2013 4:17 PM Amit Kapila wrote: On Wednesday,

Re: ALTER SYSTEM SET command to change postgresql.conf parameters (RE: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review])

2013-06-13 Thread Amit Kapila
On Friday, June 14, 2013 3:17 AM Josh Berkus wrote: On 06/13/2013 05:35 AM, Amit Kapila wrote: On Friday, June 07, 2013 9:45 AM Amit Kapila wrote: On Thursday, June 06, 2013 10:22 PM Robert Haas wrote: On Wed, Jun 5, 2013 at 7:24 AM, Amit Kapila amit.kap...@huawei.com wrote: On Monday,

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review]

2013-06-06 Thread Robert Haas
On Wed, Jun 5, 2013 at 7:24 AM, Amit Kapila amit.kap...@huawei.com wrote: On Monday, May 27, 2013 4:17 PM Amit Kapila wrote: On Wednesday, April 03, 2013 11:55 AM Amit Kapila wote: On Tuesday, April 02, 2013 9:49 PM Peter Eisentraut wrote: There are 2 options to proceed for this patch for

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review]

2013-06-06 Thread Amit Kapila
On Thursday, June 06, 2013 10:22 PM Robert Haas wrote: On Wed, Jun 5, 2013 at 7:24 AM, Amit Kapila amit.kap...@huawei.com wrote: On Monday, May 27, 2013 4:17 PM Amit Kapila wrote: On Wednesday, April 03, 2013 11:55 AM Amit Kapila wote: On Tuesday, April 02, 2013 9:49 PM Peter Eisentraut

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review]

2013-06-05 Thread Amit Kapila
On Monday, May 27, 2013 4:17 PM Amit Kapila wrote: On Wednesday, April 03, 2013 11:55 AM Amit Kapila wote: On Tuesday, April 02, 2013 9:49 PM Peter Eisentraut wrote: There are 2 options to proceed for this patch for 9.4 1. Upload the SET PERSISTENT syntax patch for coming CF by fixing

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review]

2013-04-04 Thread Amit Kapila
On Thursday, April 04, 2013 2:52 AM Robert Haas wrote: On Wed, Apr 3, 2013 at 2:54 PM, Tom Lane t...@sss.pgh.pa.us wrote: Robert Haas robertmh...@gmail.com writes: On Tue, Apr 2, 2013 at 12:19 PM, Peter Eisentraut pete...@gmx.net wrote: It's weird that SET LOCAL and SET SESSION actually

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review]

2013-04-03 Thread Amit Kapila
On Tuesday, April 02, 2013 9:49 PM Peter Eisentraut wrote: I'm going to ignore most of the discussion that led up to this and give this patch a fresh look. Thank you. + screen + SET PERSISTENT max_connections To 10; + /screen The To should probably be capitalized. Okay, shall fix it.

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review]

2013-04-03 Thread Amit Kapila
On Wednesday, April 03, 2013 2:23 AM Greg Smith wrote: On 4/1/13 5:44 AM, Amit Kapila wrote: I think in that case we can have 3 separate patches 1. Memory growth defect fix 2. Default postgresql.conf to include config directory and SET Persistent into single file implementation 3.

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review]

2013-04-03 Thread Robert Haas
On Tue, Apr 2, 2013 at 12:19 PM, Peter Eisentraut pete...@gmx.net wrote: It's weird that SET LOCAL and SET SESSION actually *set* the value, and the second key word determines how long the setting will last. SET PERSISTENT doesn't actually set the value. I predict that this will be a new

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review]

2013-04-03 Thread Tom Lane
Robert Haas robertmh...@gmail.com writes: On Tue, Apr 2, 2013 at 12:19 PM, Peter Eisentraut pete...@gmx.net wrote: It's weird that SET LOCAL and SET SESSION actually *set* the value, and the second key word determines how long the setting will last. SET PERSISTENT doesn't actually set the

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review]

2013-04-03 Thread Robert Haas
On Wed, Apr 3, 2013 at 2:54 PM, Tom Lane t...@sss.pgh.pa.us wrote: Robert Haas robertmh...@gmail.com writes: On Tue, Apr 2, 2013 at 12:19 PM, Peter Eisentraut pete...@gmx.net wrote: It's weird that SET LOCAL and SET SESSION actually *set* the value, and the second key word determines how long

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review]

2013-04-02 Thread Peter Eisentraut
I'm going to ignore most of the discussion that led up to this and give this patch a fresh look. + screen + SET PERSISTENT max_connections To 10; + /screen The To should probably be capitalized. I doubt this example actually works because changing max_connections requires a restart. Try to

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review]

2013-04-02 Thread Greg Smith
On 4/1/13 5:44 AM, Amit Kapila wrote: I think in that case we can have 3 separate patches 1. Memory growth defect fix 2. Default postgresql.conf to include config directory and SET Persistent into single file implementation 3. Rearrangement of GUC validation into validate_conf_option function.

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review]

2013-04-01 Thread Greg Smith
At this point SET PERSISTENT is looking complete enough that some parts of it might be committed. There's been a lot of useful progress in nailing down the early/obvious problems and what fundamental approach makes sense. Accepting the whole thing still seems a bit too invasive to chew on

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review]

2013-04-01 Thread Amit Kapila
On Monday, April 01, 2013 1:03 PM Greg Smith wrote: At this point SET PERSISTENT is looking complete enough that some parts of it might be committed. There's been a lot of useful progress in nailing down the early/obvious problems and what fundamental approach makes sense. Accepting the

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review]

2013-03-22 Thread Alvaro Herrera
Amit Kapila escribió: On Friday, March 22, 2013 8:57 AM Alvaro Herrera wrote: Amit Kapila escribió: I think adding new syntax change is little scary for me, not for the matter of implementation but for building consensus on syntax. I cannot but agree on that point. Sorry, I don't

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review]

2013-03-22 Thread Amit Kapila
On Friday, March 22, 2013 7:33 PM Alvaro Herrera wrote: Amit Kapila escribió: On Friday, March 22, 2013 8:57 AM Alvaro Herrera wrote: Amit Kapila escribió: I think adding new syntax change is little scary for me, not for the matter of implementation but for building consensus on

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review]

2013-03-21 Thread Robert Haas
On Tue, Mar 12, 2013 at 11:36 AM, Greg Stark st...@mit.edu wrote: On Tue, Mar 12, 2013 at 9:06 AM, Greg Smith g...@2ndquadrant.com wrote: That's jumping right over a few rounds of simpler ways to do this, and just going right to the approach we know allows adding more such options later with

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review]

2013-03-21 Thread Greg Smith
On 3/21/13 2:38 PM, Robert Haas wrote: Also, while I think that MOST people will probably want a SIGHUP right after SET PERSISTENT, I am not sure that EVERYONE will want that. If you want it and it doesn't happen automatically, you can always do it by hand. This is a fair position, and since

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review]

2013-03-21 Thread Alvaro Herrera
Greg Smith escribió: On 3/21/13 2:38 PM, Robert Haas wrote: Also, while I think that MOST people will probably want a SIGHUP right after SET PERSISTENT, I am not sure that EVERYONE will want that. If you want it and it doesn't happen automatically, you can always do it by hand. This is a

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review]

2013-03-21 Thread Amit Kapila
On Friday, March 22, 2013 12:48 AM Alvaro Herrera wrote: Greg Smith escribió: On 3/21/13 2:38 PM, Robert Haas wrote: Also, while I think that MOST people will probably want a SIGHUP right after SET PERSISTENT, I am not sure that EVERYONE will want that. If you want it and it doesn't

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review]

2013-03-21 Thread Alvaro Herrera
Amit Kapila escribió: On Friday, March 22, 2013 12:48 AM Alvaro Herrera wrote: Maybe add some syntax to prevent the SIGHUP for the rare case where that is wanted, say SET PERSISTENT (reload=off) var=val; (perhaps WITH at the end, dunno) I think adding new syntax change is

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review]

2013-03-21 Thread Greg Smith
On 3/21/13 10:39 PM, Amit Kapila wrote: I think adding new syntax change is little scary for me, not for the matter of implementation but for building consensus on syntax. Can we do it as an enhancement later? Yeah, I think the basics of this could be committed, but have later improvements

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review]

2013-03-21 Thread Amit Kapila
On Friday, March 22, 2013 8:57 AM Alvaro Herrera wrote: Amit Kapila escribió: On Friday, March 22, 2013 12:48 AM Alvaro Herrera wrote: Maybe add some syntax to prevent the SIGHUP for the rare case where that is wanted, say SET PERSISTENT (reload=off) var=val; (perhaps

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review]

2013-03-21 Thread Tom Lane
Greg Smith g...@2ndquadrant.com writes: On 3/21/13 10:39 PM, Amit Kapila wrote: I feel giving Notice after every command doesn't look good, so may be we can mention the same in documentation. I think that NOTICE after every command is the only way we'll make sure to catch every user who

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review]

2013-03-14 Thread Amit Kapila
On Wednesday, March 13, 2013 8:06 PM Andres Freund wrote: On 2013-03-13 18:52:48 +0530, Amit Kapila wrote: On Wednesday, March 13, 2013 6:44 PM Andres Freund wrote: On 2013-03-13 18:38:12 +0530, Amit Kapila wrote: On Wednesday, March 13, 2013 6:10 PM Andres Freund wrote: On

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review]

2013-03-13 Thread Amit Kapila
On Wednesday, March 13, 2013 6:10 PM Andres Freund wrote: On 2013-03-12 10:46:53 +0530, Amit Kapila wrote: Do you mean to say that because some variables can only be set after restart can lead to inconsistency, or is it because of asynchronous nature of pg_reload_conf()? As long as SET

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review]

2013-03-13 Thread Andres Freund
On 2013-03-13 18:38:12 +0530, Amit Kapila wrote: On Wednesday, March 13, 2013 6:10 PM Andres Freund wrote: On 2013-03-12 10:46:53 +0530, Amit Kapila wrote: Do you mean to say that because some variables can only be set after restart can lead to inconsistency, or is it because of

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review]

2013-03-13 Thread Amit Kapila
On Wednesday, March 13, 2013 6:44 PM Andres Freund wrote: On 2013-03-13 18:38:12 +0530, Amit Kapila wrote: On Wednesday, March 13, 2013 6:10 PM Andres Freund wrote: On 2013-03-12 10:46:53 +0530, Amit Kapila wrote: Do you mean to say that because some variables can only be set after

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review]

2013-03-13 Thread Andres Freund
On 2013-03-13 18:52:48 +0530, Amit Kapila wrote: On Wednesday, March 13, 2013 6:44 PM Andres Freund wrote: On 2013-03-13 18:38:12 +0530, Amit Kapila wrote: On Wednesday, March 13, 2013 6:10 PM Andres Freund wrote: On 2013-03-12 10:46:53 +0530, Amit Kapila wrote: Do you mean to say

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review]

2013-03-12 Thread Greg Stark
On Tue, Mar 12, 2013 at 9:06 AM, Greg Smith g...@2ndquadrant.com wrote: That's jumping right over a few rounds of simpler ways to do this, and just going right to the approach we know allows adding more such options later with minimal grammar impact. As Craig intimated, the minimal grammar

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review]

2013-03-12 Thread Tom Lane
Greg Stark st...@mit.edu writes: As Craig intimated, the minimal grammar impact would be simply BEGIN; set persistent maintenance_work_mem='2GB'; set persistent work_mem='2GB'; COMMIT; Sending the sighup at transaction end seems like a fairly safe thing to do too. It's hard to imagine it

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review]

2013-03-12 Thread Amit Kapila
On Tuesday, March 12, 2013 9:37 PM Tom Lane wrote: Greg Stark st...@mit.edu writes: As Craig intimated, the minimal grammar impact would be simply BEGIN; set persistent maintenance_work_mem='2GB'; set persistent work_mem='2GB'; COMMIT; Sending the sighup at transaction end seems

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review]

2013-03-11 Thread Amit Kapila
From: gsst...@gmail.com [mailto:gsst...@gmail.com] On Behalf Of Greg Stark Sent: Tuesday, March 12, 2013 12:50 AM To: Greg Smith Cc: Amit Kapila; Andres Freund; Boszormenyi Zoltan; pgsql- hack...@postgresql.org Subject: Re: Re: Proposal for Allow postgresql.conf values to be changed via

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review]

2013-01-26 Thread Robert Haas
On Thu, Jan 24, 2013 at 12:39 PM, Andres Freund and...@2ndquadrant.com wrote: More people seem to have voted for the single file approach but I still haven't understood why... Me neither. Having an include directory seems good, but I can't think why we'd want to clutter it up with a bajillion

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review]

2013-01-26 Thread Kevin Grittner
Robert Haas robertmh...@gmail.com wrote: Andres Freund and...@2ndquadrant.com wrote: More people seem to have voted for the single file approach but I still haven't understood why... Me neither.  Having an include directory seems good, but I can't think why we'd want to clutter it up with a

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review]

2013-01-26 Thread Tom Lane
Robert Haas robertmh...@gmail.com writes: On Thu, Jan 24, 2013 at 12:39 PM, Andres Freund and...@2ndquadrant.com wrote: More people seem to have voted for the single file approach but I still haven't understood why... Me neither. Having an include directory seems good, but I can't think

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review]

2013-01-26 Thread Craig Ringer
On 01/27/2013 01:01 AM, Tom Lane wrote: Robert Haas robertmh...@gmail.com writes: On Thu, Jan 24, 2013 at 12:39 PM, Andres Freund and...@2ndquadrant.com wrote: More people seem to have voted for the single file approach but I still haven't understood why... Me neither. Having an include

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review]

2013-01-26 Thread Robert Haas
On Sat, Jan 26, 2013 at 6:47 PM, Craig Ringer cr...@2ndquadrant.com wrote: On 01/27/2013 01:01 AM, Tom Lane wrote: Robert Haas robertmh...@gmail.com writes: On Thu, Jan 24, 2013 at 12:39 PM, Andres Freund and...@2ndquadrant.com wrote: More people seem to have voted for the single file

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review]

2013-01-26 Thread Amit kapila
On Sunday, January 27, 2013 10:07 AM Robert Haas wrote: On Sat, Jan 26, 2013 at 6:47 PM, Craig Ringer cr...@2ndquadrant.com wrote: On 01/27/2013 01:01 AM, Tom Lane wrote: Robert Haas robertmh...@gmail.com writes: On Thu, Jan 24, 2013 at 12:39 PM, Andres Freund and...@2ndquadrant.com wrote:

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review]

2013-01-25 Thread Amit Kapila
On Thursday, January 24, 2013 6:51 PM Andres Freund wrote: On 2013-01-24 18:37:29 +0530, Amit Kapila wrote: On Thursday, January 24, 2013 5:25 PM Andres Freund wrote: On 2013-01-24 16:45:42 +0530, Amit Kapila wrote: * The gram.y changes arround set_rest_(more|common) seem pretty

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review]

2013-01-24 Thread Amit Kapila
On Thursday, January 24, 2013 1:56 AM Andres Freund wrote: On 2013-01-22 12:32:07 +, Amit kapila wrote: This closes all comments raised till now for this patch. Kindly let me know if you feel something is missing? I am coming late to this patch, so bear with me if I repeat somethign

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review]

2013-01-24 Thread Amit Kapila
On Thursday, January 24, 2013 5:25 PM Andres Freund wrote: On 2013-01-24 16:45:42 +0530, Amit Kapila wrote: * The gram.y changes arround set_rest_(more|common) seem pretty confused to me. E.g. its not possible anymore to set the timezone for a function. What do you exactly mean

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review]

2013-01-24 Thread Amit Kapila
On Thursday, January 24, 2013 6:51 PM Andres Freund wrote: On 2013-01-24 18:37:29 +0530, Amit Kapila wrote: On Thursday, January 24, 2013 5:25 PM Andres Freund wrote: On 2013-01-24 16:45:42 +0530, Amit Kapila wrote: * The gram.y changes arround set_rest_(more|common) seem pretty

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review]

2013-01-24 Thread Tom Lane
Andres Freund and...@anarazel.de writes: Backend A: does SET PERSISTENT foobar =..; Backend B: does SET PERSISTENT foobar =..; Now B overwrites the config change A has made as they are all stored in the same file. Say what? I thought the plan was one setting per file, so that we don't get

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review]

2013-01-14 Thread Boszormenyi Zoltan
2013-01-14 07:47 keltezéssel, Amit kapila írta: On Sunday, January 13, 2013 2:45 PM Boszormenyi Zoltan wrote: 2013-01-13 05:49 keltezéssel, Amit kapila írta: On Sunday, January 13, 2013 12:41 AM Tom Lane wrote: Boszormenyi Zoltan z...@cybertec.at writes: No, I mean the reaper(SIGNAL_ARGS)

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review]

2013-01-14 Thread Amit kapila
On Monday, January 14, 2013 6:48 PM Boszormenyi Zoltan wrote: 2013-01-14 07:47 keltezéssel, Amit kapila írta: On Sunday, January 13, 2013 2:45 PM Boszormenyi Zoltan wrote: 2013-01-13 05:49 keltezéssel, Amit kapila írta: On Sunday, January 13, 2013 12:41 AM Tom Lane wrote: Boszormenyi Zoltan

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review]

2013-01-13 Thread Boszormenyi Zoltan
2013-01-13 05:49 keltezéssel, Amit kapila írta: On Sunday, January 13, 2013 12:41 AM Tom Lane wrote: Boszormenyi Zoltan z...@cybertec.at writes: No, I mean the reaper(SIGNAL_ARGS) function in src/backend/postmaster/postmaster.c where your patch has this: ***

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review]

2013-01-13 Thread Amit kapila
On Sunday, January 13, 2013 2:45 PM Boszormenyi Zoltan wrote: 2013-01-13 05:49 keltezéssel, Amit kapila írta: On Sunday, January 13, 2013 12:41 AM Tom Lane wrote: Boszormenyi Zoltan z...@cybertec.at writes: No, I mean the reaper(SIGNAL_ARGS) function in src/backend/postmaster/postmaster.c

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review]

2013-01-12 Thread Tom Lane
Boszormenyi Zoltan z...@cybertec.at writes: No, I mean the reaper(SIGNAL_ARGS) function in src/backend/postmaster/postmaster.c where your patch has this: *** a/src/backend/postmaster/postmaster.c --- b/src/backend/postmaster/postmaster.c *** *** 2552,2557

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review]

2013-01-12 Thread Amit kapila
On Sunday, January 13, 2013 12:41 AM Tom Lane wrote: Boszormenyi Zoltan z...@cybertec.at writes: No, I mean the reaper(SIGNAL_ARGS) function in src/backend/postmaster/postmaster.c where your patch has this: *** a/src/backend/postmaster/postmaster.c --- b/src/backend/postmaster/postmaster.c

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review]

2013-01-11 Thread Boszormenyi Zoltan
Hi, 2013-01-09 10:08 keltezéssel, Amit kapila írta: On Sunday, January 06, 2013 10:26 AM Boszormenyi Zoltan wrote: On Saturday, January 05, 2013 12:35 PM Boszormenyi Zoltan wrote: 2013-01-05 05:58 keltezéssel, Amit kapila írta: On Friday, January 04, 2013 10:57 PM Boszormenyi Zoltan wrote:

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review]

2013-01-11 Thread Amit kapila
On Friday, January 11, 2013 10:03 PM Boszormenyi Zoltan wrote: Hi, 2013-01-09 10:08 keltezéssel, Amit kapila írta: On Sunday, January 06, 2013 10:26 AM Boszormenyi Zoltan wrote: On Saturday, January 05, 2013 12:35 PM Boszormenyi Zoltan wrote: 2013-01-05 05:58 keltezéssel, Amit kapila írta:

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review]

2013-01-11 Thread Boszormenyi Zoltan
2013-01-12 06:51 keltezéssel, Amit kapila írta: On Friday, January 11, 2013 10:03 PM Boszormenyi Zoltan wrote: Hi, 2013-01-09 10:08 keltezéssel, Amit kapila írta: On Sunday, January 06, 2013 10:26 AM Boszormenyi Zoltan wrote: On Saturday, January 05, 2013 12:35 PM Boszormenyi Zoltan wrote:

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review]

2013-01-05 Thread Boszormenyi Zoltan
2013-01-05 05:58 keltezéssel, Amit kapila írta: On Friday, January 04, 2013 10:57 PM Boszormenyi Zoltan wrote: Hi, I am reviewing your patch. Thank you very much. Since you are using a constant string, it would be a little faster to use sizeof(string)-1 as it can be computed at compile-time

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review]

2013-01-05 Thread Amit kapila
On Saturday, January 05, 2013 12:35 PM Boszormenyi Zoltan wrote: 2013-01-05 05:58 keltezéssel, Amit kapila írta: On Friday, January 04, 2013 10:57 PM Boszormenyi Zoltan wrote: Hi, I am reviewing your patch. Thank you very much. Yes, you are right adding a new LWLock will avoid the use of

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review]

2013-01-04 Thread Boszormenyi Zoltan
Hi, I am reviewing your patch. 2012-12-10 13:58 keltezéssel, Amit kapila írta: On Thu, 6 Dec 2012 10:12:31 +0530 Amit Kapila wrote: On Tuesday, December 04, 2012 8:37 AM Amit Kapila wrote: On Monday, December 03, 2012 8:59 PM Tom Lane wrote: Robert Haas robertmhaas(at)gmail(dot)com writes:

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review]

2013-01-04 Thread Boszormenyi Zoltan
2013-01-04 18:27 keltezéssel, Boszormenyi Zoltan írta: One specific comment about the documentation part of the patch: *** *** 86,92 SET [ SESSION | LOCAL ] TIME ZONE { replaceable class=PARAMETERtimezone/rep applicationPL/pgSQL/application exception block. This

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review]

2013-01-04 Thread Amit kapila
On Friday, January 04, 2013 10:57 PM Boszormenyi Zoltan wrote: Hi, I am reviewing your patch. Thank you very much. Since you are using a constant string, it would be a little faster to use sizeof(string)-1 as it can be computed at compile-time and not run the strlen() all the time this

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL [review]

2013-01-04 Thread Boszormenyi Zoltan
2013-01-05 05:58 keltezéssel, Amit kapila írta: On Friday, January 04, 2013 10:57 PM Boszormenyi Zoltan wrote: Hi, I am reviewing your patch. Thank you very much. Since you are using a constant string, it would be a little faster to use sizeof(string)-1 as it can be computed at compile-time

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL

2012-12-11 Thread Amit Kapila
On Tuesday, December 11, 2012 5:25 AM Jaime Casanova wrote: On Fri, Nov 23, 2012 at 4:56 AM, Amit Kapila amit.kap...@huawei.com wrote: On Thursday, November 22, 2012 10:09 PM Fujii Masao wrote: Is it helpful to output the notice message like 'Run pg_reload_conf() or restart the server

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL

2012-12-11 Thread Tom Lane
Amit Kapila amit.kap...@huawei.com writes: On Tuesday, December 11, 2012 5:25 AM Jaime Casanova wrote: can we at least send the source file in the error message when a parameter has a wrong value? suppose you do: SET PERSISTENT shared_preload_libraries TO 'some_nonexisting_lib'; when you

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL

2012-12-10 Thread Jaime Casanova
On Fri, Nov 23, 2012 at 4:56 AM, Amit Kapila amit.kap...@huawei.com wrote: On Thursday, November 22, 2012 10:09 PM Fujii Masao wrote: Is it helpful to output the notice message like 'Run pg_reload_conf() or restart the server if you want new settings to take effect' always after SET

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL

2012-12-05 Thread Amit Kapila
On Tuesday, December 04, 2012 8:37 AM Amit Kapila wrote: On Monday, December 03, 2012 8:59 PM Tom Lane wrote: Robert Haas robertmh...@gmail.com writes: On Sat, Dec 1, 2012 at 11:45 AM, Tom Lane t...@sss.pgh.pa.us wrote: But even if we can't make that work, it's not grounds for reserving

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL

2012-12-03 Thread Amit Kapila
On Saturday, December 01, 2012 10:00 PM Tom Lane wrote: Amit Kapila amit.kap...@huawei.com writes: On Saturday, December 01, 2012 1:30 AM Tom Lane wrote: which cannot work if persistent could be a var_name, because bison has to decide whether to reduce opt_persistent to PERSISTENT or empty

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL

2012-12-03 Thread Robert Haas
On Sat, Dec 1, 2012 at 11:45 AM, Tom Lane t...@sss.pgh.pa.us wrote: I wrote: But even if we can't make that work, it's not grounds for reserving PERSISTENT. Instead I'd be inclined to forget about RESET PERSISTENT syntax and use, say, SET PERSISTENT var_name TO DEFAULT to mean that. (BTW, I

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL

2012-12-03 Thread Robert Haas
On Mon, Dec 3, 2012 at 6:38 AM, Amit Kapila amit.kap...@huawei.com wrote: On Saturday, December 01, 2012 10:00 PM Tom Lane wrote: Amit Kapila amit.kap...@huawei.com writes: On Saturday, December 01, 2012 1:30 AM Tom Lane wrote: which cannot work if persistent could be a var_name, because

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL

2012-12-03 Thread Tom Lane
Robert Haas robertmh...@gmail.com writes: On Sat, Dec 1, 2012 at 11:45 AM, Tom Lane t...@sss.pgh.pa.us wrote: But even if we can't make that work, it's not grounds for reserving PERSISTENT. Instead I'd be inclined to forget about RESET PERSISTENT syntax and use, say, SET PERSISTENT var_name

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL

2012-12-03 Thread Tom Lane
Robert Haas robertmh...@gmail.com writes: On Mon, Dec 3, 2012 at 6:38 AM, Amit Kapila amit.kap...@huawei.com wrote: opt_persistent: PERSISTENT{ $$ = TRUE; } | /*EMPTY*/%prec Op{ $$ = FALSE; } ; I am not sure if there are any problems

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL

2012-12-03 Thread Andrew Dunstan
On 12/03/2012 10:32 AM, Tom Lane wrote: Robert Haas robertmh...@gmail.com writes: On Mon, Dec 3, 2012 at 6:38 AM, Amit Kapila amit.kap...@huawei.com wrote: opt_persistent: PERSISTENT{ $$ = TRUE; } | /*EMPTY*/%prec Op{ $$ = FALSE; } ; I

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL

2012-12-03 Thread Amit Kapila
On Monday, December 03, 2012 8:59 PM Tom Lane wrote: Robert Haas robertmh...@gmail.com writes: On Sat, Dec 1, 2012 at 11:45 AM, Tom Lane t...@sss.pgh.pa.us wrote: But even if we can't make that work, it's not grounds for reserving PERSISTENT. Instead I'd be inclined to forget about RESET

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL

2012-12-03 Thread Amit Kapila
On Monday, December 03, 2012 8:50 PM Robert Haas wrote: On Sat, Dec 1, 2012 at 11:45 AM, Tom Lane t...@sss.pgh.pa.us wrote: I wrote: But even if we can't make that work, it's not grounds for reserving PERSISTENT. Instead I'd be inclined to forget about RESET PERSISTENT syntax and use,

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL

2012-12-01 Thread Amit Kapila
On Saturday, December 01, 2012 1:30 AM Tom Lane wrote: Robert Haas robertmh...@gmail.com writes: On Wed, Nov 28, 2012 at 9:47 AM, Amit kapila amit.kap...@huawei.com wrote: 5. PERSISTENT Keyword is added to the reserved keyword list. As it was giving some errors given below while parsing

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL

2012-12-01 Thread Tom Lane
Amit Kapila amit.kap...@huawei.com writes: On Saturday, December 01, 2012 1:30 AM Tom Lane wrote: But having said that, it's not apparent to me why inventing SET PERSISTENT should require reserving PERSISTENT. The problem is due to RESET PERSISTENT configuration_variable Syntax. I think the

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL

2012-12-01 Thread Tom Lane
I wrote: But even if we can't make that work, it's not grounds for reserving PERSISTENT. Instead I'd be inclined to forget about RESET PERSISTENT syntax and use, say, SET PERSISTENT var_name TO DEFAULT to mean that. (BTW, I wonder what behavior that syntax has now in your patch.) In fact,

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL

2012-12-01 Thread Amit kapila
On Saturday, December 01, 2012 10:00 PM Tom Lane wrote: Amit Kapila amit.kap...@huawei.com writes : On Saturday, December 01, 2012 1:30 AM Tom Lane wrote: But having said that, it's not apparent to me why inventing SET PERSISTENT should require reserving PERSISTENT. The problem is due to

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL

2012-12-01 Thread Amit kapila
On Saturday, December 01, 2012 10:15 PM Tom Lane wrote: I wrote: But even if we can't make that work, it's not grounds for reserving PERSISTENT. Instead I'd be inclined to forget about RESET PERSISTENT syntax and use, say, SET PERSISTENT var_name TO DEFAULT to mean that. (BTW, I wonder what

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL

2012-11-30 Thread Robert Haas
On Wed, Nov 28, 2012 at 9:47 AM, Amit kapila amit.kap...@huawei.com wrote: 5. PERSISTENT Keyword is added to the reserved keyword list. As it was giving some errors given below while parsing gram.y 15 shift/reduce conflicts . Allow me to be the first to say that any syntax for this

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL

2012-11-30 Thread Tom Lane
Robert Haas robertmh...@gmail.com writes: On Wed, Nov 28, 2012 at 9:47 AM, Amit kapila amit.kap...@huawei.com wrote: 5. PERSISTENT Keyword is added to the reserved keyword list. As it was giving some errors given below while parsing gram.y 15 shift/reduce conflicts . Allow me to be the

Re: [HACKERS] Proposal for Allow postgresql.conf values to be changed via SQL

2012-11-24 Thread Tom Lane
Amit kapila amit.kap...@huawei.com writes: On Friday, November 23, 2012 10:10 PM Fujii Masao wrote: What happens if the server crashes while SET PERSISTENT is writing the setting to the file? A partial write occurs and restart of the server would fail because of corrupted

<    1   2   3   4   >