Re: Frontend/Backend protocol question.

From: "Albe Laurenz" <laurenz(dot)albe(at)wien(dot)gv(dot)at>
To: "Dmitriy Igrishin *EXTERN*" <dmitigr(at)gmail(dot)com>, <pgsql-general(at)postgresql(dot)org>
Subject: Re: Frontend/Backend protocol question.
Date: 2012-03-14 08:18:11
Message-ID: D960CB61B694CF459DCFB4B0128514C2079CEAEA@exadv11.host.magwien.gv.at
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Dmitriy Igrishin wrote:
> According to
> http://www.postgresql.org/docs/9.1/static/protocol-flow.html#AEN91458
> "is not actually necessary for the frontend to wait for
> ReadyForQuery before issuing another command".
>
> But is it necessary for frontend to wait for ReadyForQuery
> before sending Describe message? Or is it necessary to
> wait for RowDescription/NoData after sending Describe
> before sending Query or, say, Prepare?
>
> In short, is it necessary for frontend to wait for responses
> on sent messages before sending a new ones?

I agree with your interpretation. I have not tried it myself,
but I think you can just send the next message without waiting
for ReadyForQuery.

The problem is that this may not make sense: for example, if you
send Describe immediately after Parse, it may be that the Parse
fails and the Describe does something you did not intend.

Yours,
Laurenz Albe

In response to

Browse pgsql-general by date

  From Date Subject
Next Message maxxedit@gmail.com 2012-03-14 11:45:06 provide pg_get_notifications()
Previous Message Alexander Reichstadt 2012-03-14 07:59:19 Re: Ways to edit users and permissions for database