Re: ClientRead on ROLLABACK - Mailing list pgsql-hackers

From Tom Lane
Subject Re: ClientRead on ROLLABACK
Date
Msg-id 1735502.1719501698@sss.pgh.pa.us
Whole thread Raw
In response to ClientRead on ROLLABACK  (Simone Giusso <simonedevs@gmail.com>)
Responses Re: ClientRead on ROLLABACK
List pgsql-hackers
Simone Giusso <simonedevs@gmail.com> writes:
> I have a question regarding postgresql waiting for the client. I queried
> the pg_stat_activity because I noticed a connection that had not been
> released for days!!! I saw that the wait_event was ClientRead and the query
> was ROLLBACK. What the server is waiting for from the client?

You are misunderstanding that display.  If the wait state is ClientRead
then the server has nothing to do and is awaiting a fresh SQL command
from the client.  The query that's shown is the last-executed query.
(We used to show "<IDLE>" in the query column in this state, but that
was deemed less helpful than the current behavior.)

> So I ended up in a situation where both client and server were reading from
> the socket :(. I'm not sure why. Something went wrong between client and
> server, network problems?

Yeah, a dropped packet could explain this perhaps.

            regards, tom lane



pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: Custom type's modifiers
Next
From: Jelte Fennema-Nio
Date:
Subject: Re: ClientRead on ROLLABACK