On Sun, Jul 15, 2018 at 8:24 PM, David Rowley <david.row...@2ndquadrant.com> wrote: >> +1. In fact, maybe we ought to go a little further and have a >> relation_reopen(oid, mode) that verifies that a lock in the specified >> mode is held. > > Wouldn't it be better to just store the Relation indexed by its relid > somewhere the first time we opened it? Then just do a direct array > lookup on that rather than looking up by hashtable in syscache?
Yes, that would be better, IMHO anyway. -- Robert Haas EnterpriseDB: http://www.enterprisedb.com The Enterprise PostgreSQL Company