diff options
| author | Robert Haas <rhaas@postgresql.org> | 2015-02-02 16:23:59 -0500 |
|---|---|---|
| committer | Robert Haas <rhaas@postgresql.org> | 2015-02-02 16:23:59 -0500 |
| commit | 5d2f957f3f9dcd88384780876f535b423151f9bf (patch) | |
| tree | a857f045f8bc849ef6cb3aca570e7252e74a324b /src/include/postmaster | |
| parent | 2488eff889f83d7d6411be9a6172ff69df3f0085 (diff) | |
| download | postgresql-5d2f957f3f9dcd88384780876f535b423151f9bf.tar.gz | |
Add new function BackgroundWorkerInitializeConnectionByOid.
Sometimes it's useful for a background worker to be able to initialize
its database connection by OID rather than by name, so provide a way
to do that.
Diffstat (limited to 'src/include/postmaster')
| -rw-r--r-- | src/include/postmaster/bgworker.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/include/postmaster/bgworker.h b/src/include/postmaster/bgworker.h index 0460653b05..a81b90badc 100644 --- a/src/include/postmaster/bgworker.h +++ b/src/include/postmaster/bgworker.h @@ -130,6 +130,9 @@ extern PGDLLIMPORT BackgroundWorker *MyBgworkerEntry; */ extern void BackgroundWorkerInitializeConnection(char *dbname, char *username); +/* Just like the above, but specifying database and user by OID. */ +extern void BackgroundWorkerInitializeConnectionByOid(Oid dboid, Oid useroid); + /* Block/unblock signals in a background worker process */ extern void BackgroundWorkerBlockSignals(void); extern void BackgroundWorkerUnblockSignals(void); |
