From: | Oliver Jowett <oliver(at)opencloud(dot)com> |
---|---|
To: | Donald Fraser <postgres(at)kiwi-fraser(dot)net> |
Cc: | "[JDBC]" <pgsql-jdbc(at)postgresql(dot)org>, "[ADMIN]" <pgsql-admin(at)postgresql(dot)org> |
Subject: | Re: [JDBC] Missing documentation for error code: 80S01 |
Date: | 2011-04-13 10:30:17 |
Message-ID: | BANLkTimwwzsxhq36T4k7jNUexPEiyeVz_w@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-admin pgsql-bugs pgsql-jdbc |
On 13 April 2011 21:57, Donald Fraser <postgres(at)kiwi-fraser(dot)net> wrote:
> Technically yes. When performing a read on the socket you get -1 indicating
> EOF or remote socket closed. You don't get an IO error.
> The difficult part is what was the client doing when the server closes the
> socket?
> If the client wasn't doing anything then the next likely action a client
> would perform is to execute a query which would involve writing to the
> socket first and in this case you will get a broken pipe IO exception,
> rather than remote socket closed.
> If the client had already executed a query and was attempting to read
> response data then you get remote socket closed.
>
> I would like to propose that when a "remote socket closed" is detected that
> the JDBC driver uses a different error code to the one used for IO
> exceptions.
If the server is shut down mid-query, doesn't the backend complete the
current query cycle before closing the connection?
i.e. we'd see ErrorResponse, ReadyForQuery, and return control to the
app before seeing EOF anyway?
The protocol spec is a bit vague there.
Oliver
From | Date | Subject | |
---|---|---|---|
Next Message | Donald Fraser | 2011-04-13 10:52:13 | Re: [JDBC] Missing documentation for error code: 80S01 |
Previous Message | Donald Fraser | 2011-04-13 09:57:05 | Re: Missing documentation for error code: 80S01 |
From | Date | Subject | |
---|---|---|---|
Next Message | Donald Fraser | 2011-04-13 10:52:13 | Re: [JDBC] Missing documentation for error code: 80S01 |
Previous Message | Donald Fraser | 2011-04-13 09:57:05 | Re: Missing documentation for error code: 80S01 |
From | Date | Subject | |
---|---|---|---|
Next Message | Donald Fraser | 2011-04-13 10:52:13 | Re: [JDBC] Missing documentation for error code: 80S01 |
Previous Message | Donald Fraser | 2011-04-13 09:57:05 | Re: Missing documentation for error code: 80S01 |