Re: [HACKERS] Proposal for async support in libpq

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: [HACKERS] Proposal for async support in libpq
Дата
Msg-id 19809.892842677@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: [HACKERS] Proposal for async support in libpq  (Bruce Momjian <maillist@candle.pha.pa.us>)
Ответы Re: [HACKERS] Proposal for async support in libpq
Re: [HACKERS] Proposal for async support in libpq
Список pgsql-hackers
Bruce Momjian <maillist@candle.pha.pa.us> writes:
> This all looks good.  Another thing we really need it to be able to
> cancel queries.  This would be a big win, and looks like it could fit
> into the scheme here.

I thought about proposing a PQcancelAsync that would cancel the active
query-in-progress.  But that would require support on the backend side,
and I am far from competent to make it happen.  (libpq is simple enough
that I'm not afraid to rewrite it, but making major mods to the backend
is another story.  I just got here this week...)

If anyone who does know what they're doing is willing to make the
necessary backend mods, I'm all for it.  The libpq side would be
easy enough.

How would such cancellation interact with transactions, btw?  Would
you expect it to roll back only the current command, or abort the
whole transaction?  We'd also have to consider corner cases, like
when the backend has already finished the query by the time it gets
the cancel request.

            regards, tom lane

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

Предыдущее
От: Bruce Momjian
Дата:
Сообщение: Re: [HACKERS] Proposal for async support in libpq
Следующее
От: Bruce Momjian
Дата:
Сообщение: Re: [HACKERS] Proposal for async support in libpq