From: Pavel Stehule on 21 May 2010 11:10 2010/5/21 Robert Haas <robertmhaas(a)gmail.com>: > On Sat, Apr 24, 2010 at 6:53 PM, Robert Haas <robertmhaas(a)gmail.com> > wrote (in reply to Tom Lane): >>Â If we create, e.g. pg_shared_class and >> pg_shared_attribute, then we can un-nail the catalogs you just nailed >> to make the authentication process able to work without selecting a >> database. > > Actually, there's another way we could do this. Â Instead of creating > pg_shared_class and pg_shared_attribute and moving all of the catalog > entries for the shared relations into those tables, we could consider > leaving the catalog entries in the unshared copies of pg_class, > pg_attribute, etc. and DUPLICATING them in a shared catalog which > would only be used prior to selecting a database. Â Once we selected a > database we'd switch to using the database-specific pg_class et al. > Obviously that's a little grotty but it might (?) be easier, and > possibly a step along the way. > I did it - just on syscache level - but there are problem with refresh. I though about some special pseudo persistent data pages attached to possible any table with temp data. Then you don't need modify any on higher level, you don't need new catalog entries, etc .. Regards Pavel Stehule > -- > Robert Haas > EnterpriseDB: http://www.enterprisedb.com > The Enterprise Postgres Company > > -- > Sent via pgsql-hackers mailing list (pgsql-hackers(a)postgresql.org) > To make changes to your subscription: > http://www.postgresql.org/mailpref/pgsql-hackers > -- Sent via pgsql-hackers mailing list (pgsql-hackers(a)postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers
From: Robert Haas on 21 May 2010 17:37 On Fri, May 21, 2010 at 11:10 AM, Pavel Stehule <pavel.stehule(a)gmail.com> wrote: > 2010/5/21 Robert Haas <robertmhaas(a)gmail.com>: >> On Sat, Apr 24, 2010 at 6:53 PM, Robert Haas <robertmhaas(a)gmail.com> >> wrote (in reply to Tom Lane): >>> If we create, e.g. pg_shared_class and >>> pg_shared_attribute, then we can un-nail the catalogs you just nailed >>> to make the authentication process able to work without selecting a >>> database. >> >> Actually, there's another way we could do this. Instead of creating >> pg_shared_class and pg_shared_attribute and moving all of the catalog >> entries for the shared relations into those tables, we could consider >> leaving the catalog entries in the unshared copies of pg_class, >> pg_attribute, etc. and DUPLICATING them in a shared catalog which >> would only be used prior to selecting a database. Once we selected a >> database we'd switch to using the database-specific pg_class et al. >> Obviously that's a little grotty but it might (?) be easier, and >> possibly a step along the way. >> > > I did it - just on syscache level - but there are problem with > refresh. I though about some special pseudo persistent data pages > attached to possible any table with temp data. Then you don't need > modify any on higher level, you don't need new catalog entries, etc .. I don't think we're talking about the same thing. -- Robert Haas EnterpriseDB: http://www.enterprisedb.com The Enterprise Postgres Company -- Sent via pgsql-hackers mailing list (pgsql-hackers(a)postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers
From: Alvaro Herrera on 24 May 2010 16:23 Excerpts from Robert Haas's message of vie may 21 10:20:38 -0400 2010: > Actually, there's another way we could do this. Instead of creating > pg_shared_class and pg_shared_attribute and moving all of the catalog > entries for the shared relations into those tables, we could consider > leaving the catalog entries in the unshared copies of pg_class, > pg_attribute, etc. and DUPLICATING them in a shared catalog which > would only be used prior to selecting a database. Once we selected a > database we'd switch to using the database-specific pg_class et al. > Obviously that's a little grotty but it might (?) be easier, and > possibly a step along the way. Uh, how does this work when you change the entries for shared relations in a database-specific pg_class? Keeping everything in sync seems hard, if not impossible. -- Álvaro Herrera <alvherre(a)alvh.no-ip.org> -- Sent via pgsql-hackers mailing list (pgsql-hackers(a)postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers
From: Robert Haas on 24 May 2010 17:18 On Mon, May 24, 2010 at 4:23 PM, Alvaro Herrera <alvherre(a)alvh.no-ip.org> wrote: > Excerpts from Robert Haas's message of vie may 21 10:20:38 -0400 2010: > >> Actually, there's another way we could do this. Instead of creating >> pg_shared_class and pg_shared_attribute and moving all of the catalog >> entries for the shared relations into those tables, we could consider >> leaving the catalog entries in the unshared copies of pg_class, >> pg_attribute, etc. and DUPLICATING them in a shared catalog which >> would only be used prior to selecting a database. Once we selected a >> database we'd switch to using the database-specific pg_class et al. >> Obviously that's a little grotty but it might (?) be easier, and >> possibly a step along the way. > > Uh, how does this work when you change the entries for shared relations > in a database-specific pg_class? Keeping everything in sync seems hard, > if not impossible. Well, I might be missing something here, but pg_class already IS database-specific. If you change anything very significant about a shared rel in one copy of pg_class today, you're toast, IIUC. This proposal doesn't make that any better, but I don't think it makes it any worse either. -- Robert Haas EnterpriseDB: http://www.enterprisedb.com The Enterprise Postgres Company -- Sent via pgsql-hackers mailing list (pgsql-hackers(a)postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers
From: Alvaro Herrera on 24 May 2010 17:37
Excerpts from Robert Haas's message of lun may 24 17:18:21 -0400 2010: > On Mon, May 24, 2010 at 4:23 PM, Alvaro Herrera <alvherre(a)alvh.no-ip.org> wrote: > > Excerpts from Robert Haas's message of vie may 21 10:20:38 -0400 2010: > > Uh, how does this work when you change the entries for shared relations > > in a database-specific pg_class? Keeping everything in sync seems hard, > > if not impossible. > > Well, I might be missing something here, but pg_class already IS > database-specific. If you change anything very significant about a > shared rel in one copy of pg_class today, you're toast, IIUC. This > proposal doesn't make that any better, but I don't think it makes it > any worse either. I thought the whole point of this exercise was precisely to avoid this sort of problem. -- Álvaro Herrera <alvherre(a)alvh.no-ip.org> -- Sent via pgsql-hackers mailing list (pgsql-hackers(a)postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers |