Re: Backend protocol wanted features

Поиск
Список
Период
Сортировка
От Sehrope Sarkuni
Тема Re: Backend protocol wanted features
Дата
Msg-id CAH7T-aqYH4fCcG81Gtsx+ppBOaSU6FGaKsR_BO8850WR_0A2Jg@mail.gmail.com
обсуждение исходный текст
Ответ на Re: Backend protocol wanted features  (Álvaro Hernández Tortosa <aht@8Kdata.com>)
Список pgsql-jdbc
On Tue, Jan 5, 2016 at 7:45 PM, Álvaro Hernández Tortosa <aht@8kdata.com> wrote:
There are other parts of the protocol that require a separate connection. Those I don't like either, but it's not unheard of. Maybe the solution is different: that LD may be consumed within the same connection (if that would be possible).

Why not use the existing LISTEN/NOTIFY infrastructure for this? If there were a reserved namespace (ex: pg_% or pg_schema_%) then the existing protocol could be used to listen for schema changes.

There would still need to be backend support for publishing those changes but it'd be backwards compatible in both directions; it wouldn't break existing clients and a modern client that issued a LISTEN for those changes could work with an older backend that doesn't support it (it just won't receive any notifications).

Full support for something like this would require well defined message types to indicate what changed. For an initial version it might be easier to just have a "something changed" message without the specifics of which relations where impacted. A client could invalidate all prepared statements associated with the connection.

Just my 2 cents...

Regards,
-- Sehrope Sarkuni
Founder & CEO | JackDB, Inc. | https://www.jackdb.com/

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

Предыдущее
От: Álvaro Hernández Tortosa
Дата:
Сообщение: Re:
Следующее
От: Pavel Raiskup
Дата:
Сообщение: Re: [pgjdbc] Implement JDBC specs via pre-processor step (#435)