database shutdown with persistent client connections - Mailing list pgsql-general

From g.hintermayer@inode.at (Gerhard Hintermayer)
Subject database shutdown with persistent client connections
Date
Msg-id bd4db85f.0207302347.10c3627a@posting.google.com
Whole thread Raw
Responses Re: database shutdown with persistent client connections
List pgsql-general
I have a database server with multiple databases (~5) and some
persistent connections using the pgtcl interface.
If I want to shutdown the database server (smart mode) my persistant
connections prevent the postmaster from shuting down (as documented),
if I user fast mode, the shutdown get's done, but without any
notification to the clients. An error is only triggered, if I issue
sql commands, but unfortunately some applications send  commands at a
very low rate, but i'd like to get the shutdown information
immediatly.
using LISTEN gives me an error message immediately when issuing the
shutdown

> FATAL 1:  This connection has been terminated by the administrator.
>no connection to the server

obviously there seems to be some notification, but I do not know it's
name :-(

I thought of sending notifications by hand before invoking "pg_ctl
stop -m fast" but I don't want to reinvent the wheel.

Is there a notification sen't out in either smart or fast shutdown
mode ?

Gerhard

pgsql-general by date:

Previous
From: Bruce Momjian
Date:
Subject: Re: [GENERAL] Have been accepted as a writer for "The Register"
Next
From: Jean-Christian Imbeault
Date:
Subject: Dataypes: performance differences?