From 1cc0a40274e0e23aa22800a91fae2659c816766c Mon Sep 17 00:00:00 2001 From: Philip O'Toole Date: Sun, 22 May 2022 22:59:17 -0400 Subject: [PATCH 1/2] More fixes for https://github.com/rqlite/rqlite/issues/1029 --- cluster/client.go | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/cluster/client.go b/cluster/client.go index 652d7a20..1fc4bcd0 100644 --- a/cluster/client.go +++ b/cluster/client.go @@ -106,6 +106,7 @@ func (c *Client) GetNodeAPIAddr(nodeAddr string, timeout time.Duration) (string, } _, err = io.ReadFull(conn, b) if err != nil { + handleConnError(conn) return "", err } sz := binary.LittleEndian.Uint16(b[0:]) @@ -118,6 +119,7 @@ func (c *Client) GetNodeAPIAddr(nodeAddr string, timeout time.Duration) (string, } _, err = io.ReadFull(conn, p) if err != nil { + handleConnError(conn) return "", err } @@ -260,6 +262,7 @@ func (c *Client) Query(qr *command.QueryRequest, nodeAddr string, timeout time.D // Read length of response. _, err = io.ReadFull(conn, b) if err != nil { + handleConnError(conn) return nil, err } sz := binary.LittleEndian.Uint32(b[0:]) @@ -268,6 +271,7 @@ func (c *Client) Query(qr *command.QueryRequest, nodeAddr string, timeout time.D p = make([]byte, sz) _, err = io.ReadFull(conn, p) if err != nil { + handleConnError(conn) return nil, err } From 6dbe7feca5d1f93b899774a6f586bed12bd3b0f2 Mon Sep 17 00:00:00 2001 From: Philip O'Toole Date: Sun, 22 May 2022 23:00:16 -0400 Subject: [PATCH 2/2] CHANGELOG --- CHANGELOG.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 9cde2626..623a4d5b 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,7 +5,7 @@ ### Implementation changes and bug fixes - [PR #1027](https://github.com/rqlite/rqlite/pull/1027): go mod (dependencies) updates, including upgrading SQLite to 3.38.5. -- [PR #1030](https://github.com/rqlite/rqlite/pull/1030): Handle more connection errors. Fixes [issue #1029](https://github.com/rqlite/rqlite/issues/1029). +- [PR #1030](https://github.com/rqlite/rqlite/pull/1030), [PR #1032](https://github.com/rqlite/rqlite/pull/1032): Handle more connection errors. Fixes [issue #1029](https://github.com/rqlite/rqlite/issues/1029). ## 7.4.0 (May 10th 2022) With this release rqlite supports restoring a node from an actual SQLite file, which is very much faster than restoring using the SQL dump representation of the same SQLite database.