Re: Problem with pg_upgrade (8.4 -> 9.0) due to ALTER DATABASE SET ROLE

Поиск
Список
Период
Сортировка
От Florian Pflug
Тема Re: Problem with pg_upgrade (8.4 -> 9.0) due to ALTER DATABASE SET ROLE
Дата
Msg-id 2628800C-D53C-4885-A089-C771A83E84BD@phlo.org
обсуждение исходный текст
Ответ на Re: Problem with pg_upgrade (8.4 -> 9.0) due to ALTER DATABASE SET ROLE  (Robert Haas <robertmhaas@gmail.com>)
Ответы Re: Problem with pg_upgrade (8.4 -> 9.0) due to ALTER DATABASE SET ROLE  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-hackers
On Dec13, 2010, at 00:16 , Robert Haas wrote:
> And in fact it strikes me that we might not have much choice about how
> to fix this.  I think we are not going to retroactively change the
> behavior of ALTER DATABASE .. SET ROLE in a released version, but yet
> we do, I think, want to make pg_upgrade work.


A simple fix is to teach pg_upgrade to issue "RESET SESSION AUTHORIZATION" immediately after connecting to a database.
Idon't see any downside of this currently - it seems that the only case where this wouldn't be a NO-OP is if someone
setROLE to to something else either per-database, per-user or both. 

Actually, I'd like to provide an option for pg_dump and pg_restore to do that too (not by default, though). If people
thinkthis is a good idea, I could come up with a patch. 

best regards,
Florian Pflug



В списке pgsql-hackers по дате отправления:

Предыдущее
От: Robert Haas
Дата:
Сообщение: Re: ALTER TABLE ... ADD FOREIGN KEY ... NOT ENFORCED
Следующее
От: Rob Wultsch
Дата:
Сообщение: Re: ALTER TABLE ... ADD FOREIGN KEY ... NOT ENFORCED