pgsql: Provide for forward compatibility with future minor protocolver
От | Robert Haas |
---|---|
Тема | pgsql: Provide for forward compatibility with future minor protocolver |
Дата | |
Msg-id | E1eHEWB-0005Q5-4u@gemulon.postgresql.org обсуждение исходный текст |
Список | pgsql-committers |
Provide for forward compatibility with future minor protocol versions. Previously, any attempt to request a 3.x protocol version other than 3.0 would lead to a hard connection failure, which made the minor protocol version really no different from the major protocol version and precluded gentle protocol version breaks. Instead, when the client requests a 3.x protocol version where x is greater than 0, send the new NegotiateProtocolVersion message to convey that we support only 3.0. This makes it possible to introduce new minor protocol versions without requiring a connection retry when the server is older. In addition, if the startup packet includes name/value pairs where the name starts with "_pq_.", assume that those are protocol options, not GUCs. Include those we don't support (i.e. all of them, at present) in the NegotiateProtocolVersion message so that the client knows they were not understood. This makes it possible for the client to request previously-unsupported features without bumping the protocol version at all; the client can tell from the server's response whether the option was understood. It will take some time before servers that support these new facilities become common in the wild; to speed things up and make things easier for a future 3.1 protocol version, back-patch to all supported releases. Robert Haas and Badrul Chowdhury Discussion: http://postgr.es/m/BN6PR21MB0772FFA0CBD298B76017744CD1730@BN6PR21MB0772.namprd21.prod.outlook.com Discussion: http://postgr.es/m/30788.1498672033@sss.pgh.pa.us Branch ------ REL9_4_STABLE Details ------- https://git.postgresql.org/pg/commitdiff/294136d42230467b1f5496693aac847ce2199e64 Modified Files -------------- doc/src/sgml/protocol.sgml | 116 ++++++++++++++++++++++++++++++++---- src/backend/postmaster/postmaster.c | 58 ++++++++++++++++-- 2 files changed, 158 insertions(+), 16 deletions(-)
В списке pgsql-committers по дате отправления: