diff options
author | Tom Lane | 2005-04-14 20:03:27 +0000 |
---|---|---|
committer | Tom Lane | 2005-04-14 20:03:27 +0000 |
commit | 5abc360d6c468b01971330a567d43a428cd0beda (patch) | |
tree | e7e8931cc67896c837039a916236168628c3d757 /src/backend/commands/async.c | |
parent | 5e236b7caf7d09351e07f1847738fcf38fd587f8 (diff) |
Completion of project to use fixed OIDs for all system catalogs and
indexes. Replace all heap_openr and index_openr calls by heap_open
and index_open. Remove runtime lookups of catalog OID numbers in
various places. Remove relcache's support for looking up system
catalogs by name. Bulky but mostly very boring patch ...
Diffstat (limited to 'src/backend/commands/async.c')
-rw-r--r-- | src/backend/commands/async.c | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/src/backend/commands/async.c b/src/backend/commands/async.c index 60d84750ba..30506b0e08 100644 --- a/src/backend/commands/async.c +++ b/src/backend/commands/async.c @@ -79,7 +79,6 @@ #include <netinet/in.h> #include "access/heapam.h" -#include "catalog/catname.h" #include "catalog/pg_listener.h" #include "commands/async.h" #include "libpq/libpq.h" @@ -205,7 +204,7 @@ Async_Listen(char *relname, int pid) if (Trace_notify) elog(DEBUG1, "Async_Listen(%s,%d)", relname, pid); - lRel = heap_openr(ListenerRelationName, ExclusiveLock); + lRel = heap_open(ListenerRelationId, ExclusiveLock); /* Detect whether we are already listening on this relname */ scan = heap_beginscan(lRel, SnapshotNow, 0, NULL); @@ -299,7 +298,7 @@ Async_Unlisten(char *relname, int pid) if (Trace_notify) elog(DEBUG1, "Async_Unlisten(%s,%d)", relname, pid); - lRel = heap_openr(ListenerRelationName, ExclusiveLock); + lRel = heap_open(ListenerRelationId, ExclusiveLock); scan = heap_beginscan(lRel, SnapshotNow, 0, NULL); while ((tuple = heap_getnext(scan, ForwardScanDirection)) != NULL) @@ -357,7 +356,7 @@ Async_UnlistenAll(void) if (Trace_notify) elog(DEBUG1, "Async_UnlistenAll"); - lRel = heap_openr(ListenerRelationName, ExclusiveLock); + lRel = heap_open(ListenerRelationId, ExclusiveLock); tdesc = RelationGetDescr(lRel); /* Find and delete all entries with my listenerPID */ @@ -466,7 +465,7 @@ AtCommit_Notify(void) value[0] = value[1] = value[2] = (Datum) 0; value[Anum_pg_listener_notify - 1] = Int32GetDatum(MyProcPid); - lRel = heap_openr(ListenerRelationName, ExclusiveLock); + lRel = heap_open(ListenerRelationId, ExclusiveLock); tdesc = RelationGetDescr(lRel); scan = heap_beginscan(lRel, SnapshotNow, 0, NULL); @@ -902,7 +901,7 @@ ProcessIncomingNotify(void) StartTransactionCommand(); - lRel = heap_openr(ListenerRelationName, ExclusiveLock); + lRel = heap_open(ListenerRelationId, ExclusiveLock); tdesc = RelationGetDescr(lRel); /* Scan only entries with my listenerPID */ |