On 2012-12-27 18:44:57 -0500, Tom Lane wrote: > Andres Freund <and...@2ndquadrant.com> writes: > > I am still worried about the following scenario in the EXEC_BACKEND case: > > > 1) postmaster starts > > 2) reads config > > 3) executes _PG_init for shared_preload_libraries > > 4) library 'abc' gets config value 'abc.num_workers = 2' and registers as > > many workers > > 5) some time goes by, workers, backends start > > 6) abc.num_workers gets changed to 3, SIGHUP > > This is broken whether it's EXEC_BACKEND or not: you don't get to change > anything that determines the number of workers post-startup. > num_workers should have been declared PGC_POSTMASTER.
Well, the problem is, a shared library can't do that afaics. abc.num_workers would be using custom_variable_classes (well, whatever its called now, that it doesn't need to be configured). There is no predefined 'num_workers' variable or anything like it in the patch, but I guess some of the module authors will come of up with configuration variables like that. I personally want e.g. 'bdr.databases = 'a, b, c' which obviously has the same problem... Greetings, Andres Freund -- Andres Freund http://www.2ndQuadrant.com/ PostgreSQL Development, 24x7 Support, Training & Services -- Sent via pgsql-hackers mailing list (firstname.lastname@example.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers