Re: [PATCH] Send numeric version to clients

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: [PATCH] Send numeric version to clients
Дата
Msg-id 21063.1472478162@sss.pgh.pa.us
обсуждение исходный текст
Ответ на [PATCH] Send numeric version to clients  (Craig Ringer <craig@2ndquadrant.com>)
Ответы Re: [PATCH] Send numeric version to clients  (Robert Haas <robertmhaas@gmail.com>)
Список pgsql-hackers
Craig Ringer <craig@2ndquadrant.com> writes:
> The same sort of problems apply to network clients, but network
> clients don't currently get that option because we only send
> server_version on the wire in the startup packet. We don't send
> server_version_num.

> It'll be immediately useful to have this since clients can test for
> it, use it if there, and fall back to their old version parsing code
> if there's no server_version_num.

I think that this would merely create an attractive nuisance: people
would be very likely to omit the "fallback" code and thereby build
clients that fail for no very good reason on pre-v10 servers.  As a
demonstration that that's not a hypothetical risk, I assert that
that's exactly what you propose telling them to do:

> Version 10.0 is the perfect time to
> do this since many clients will need to update their version handling
> anyway, and we can just tell them to use server_version_num now.

Sure, it'd be great if we'd done it like this to start with.  But that
ship sailed long ago, and redefining how clients ought to determine
server version at this point is just a bad idea.

I'm also fairly dubious that this is a large problem; surely most
C-coded clients use libpq, for instance, and we already solved this
for them in PQserverVersion.  Or if they aren't using PQserverVersion,
why not?
        regards, tom lane



В списке pgsql-hackers по дате отправления:

Предыдущее
От: "Daniel Verite"
Дата:
Сообщение: Re: Renaming of pg_xlog and pg_clog
Следующее
От: Fujii Masao
Дата:
Сообщение: Re: Quorum commit for multiple synchronous replication.