Hi, On 2013-08-01 15:40:22 +0100, Greg Stark wrote: > Why isn't it enough to just dump out all variables with a source of alter > system to a text file? You can either have a single global lock around that > operation or write it to a new file and move it into place.
It saves you from several complications: * No need to iterate over all GUCs, figuring out which come from which source, when writing out the file. * Less logic required when writing out a value, since you have an acceptable input ready. * No need to make sure the autogenerated file is written out in the same order when adding/changing a setting (to make sure you can diff/version control it sensibly) * No locking necessary, without locking concurrent changes can vanish. * Way easier to delete a setting if it ends up stopping postgres from starting. Greetings, Andres Freund PS: .oO(quoting?) -- Andres Freund http://www.2ndQuadrant.com/ PostgreSQL Development, 24x7 Support, Training & Services -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers