From: | Mikko Tiihonen <mikko(dot)tiihonen(at)nitorcreations(dot)com> |
---|---|
To: | pgsql-hackers(at)postgresql(dot)org |
Subject: | Add minor version to v3 protocol to allow changes without breaking backwards compatibility |
Date: | 2011-11-28 15:18:53 |
Message-ID: | 4ED3A65D.9090801@nitorcreations.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Hi,
As discussed few days ago it would be beneficial if we could change the v3 backend<->client protocol without breaking backwards compatibility.
Here is a working patch that exports a supported_binary_minor constant and a binary_minor session variable and a that can be used by clients to enable newer
features.
I also added an example usage where the array encoding for constant size elements is optimized if binary_minor version is new enough.
I have coded the client side support for binary_minor for jdbc driver and tested that it worked. But lets first discuss if this is an acceptable path forward.
On 11/25/2011 02:20 AM, Oliver Jowett wrote:
> Re list vs. always-incrementing minor version, you could just use an
> integer and set bits to represent features, which would keep it simple
> but also let clients be more selective about which features they
> implement (you could support feature 21 and 23 without supporting 22)
I decided not to use a feature flag because when features start to depend on each other we need multiple negotiation round trips until the final feature set can
be known.
If in your example above the feature 23 depends on server side on feature 22, but the client only requests 21,23. The server must inform back that combination
21,23 is reduced to 21. And if then the client can not support 21 without 23 the final feature set will not contain 21 or 23.
-Mikko
Attachment | Content-Type | Size |
---|---|---|
binary_minor.patch | text/plain | 4.7 KB |
fixed_length_array_protocol.patch | text/plain | 2.8 KB |
From | Date | Subject | |
---|---|---|---|
Next Message | Tomas Vondra | 2011-11-28 15:29:46 | Re: Patch: add timing of buffer I/O requests |
Previous Message | Greg Stark | 2011-11-28 14:40:42 | Re: Patch: add timing of buffer I/O requests |