+ if (!goaway_reported && PQgoAwayReceived(pset.db))
+ {
+ pg_log_info("Server sent GoAway, requesting disconnect when convenient.");
+ goaway_reported = true;
+ }

Shouldn't this variable be reset in pqDropServerData?

+    It is possible for NoticeResponse, ParameterStatus and GoAway
messages to be
     interspersed between CopyData messages; frontends must handle these cases,

The patch currently doesn't actually do this, did you add this as
future proofing?


> I thought some more about this, but ultimately, the payloads you suggest
> only seem useful if a client has something inbetween "disconnect hard
> now" and "disconnect when the connection is unused"

Couldn't a client optimize the reconnect time if it knows about the
deadline? If it knows that it still has 10 minutes before the server
kicks it out, it might choose to finish a 3-4 minute task, reconnect,
and then continue.


Reply via email to