Skip to content

Intermittent EOF Errors #1464

Open
Open
@0xrelapse

Description

@0xrelapse

Observed

Getting this error periodically via the golang clickhouse driver when connecting to the clickhouse cloud service.

read:
    github.com/ClickHouse/ch-go/proto.(*Reader).ReadFull
        /go/pkg/mod/github.com/!click!house/ch-go@v0.61.5/proto/reader.go:62
  - EOF

Here is our config (with connection details omitted):

        // nolint:exhaustruct
	conn, err := clickhouse.Open(&clickhouse.Options{
		TLS:     ...,
		Protocol: clickhouse.Native,
		Addr:     ....,
		Auth: clickhouse.Auth{
			Username: ...,
			Password: ...,
			Database: ...,
		},
		ClientInfo: clickhouse.ClientInfo{
			Products: []struct {
				Name    string
				Version string
			}{
				{Name: "....", Version: "0.1"},
			},
		},
		Compression: &clickhouse.Compression{
			Method: clickhouse.CompressionLZ4,
		},
		BlockBufferSize: 10,
		MaxOpenConns: 70,
		MaxIdleConns: 50,
	})

After this error occurs, other queries (both reads and write) also fail, all outputting the same EOF error

Because this is intermittent, it's a little hard to reproduce.

I wonder if there's a race condition in the connection lifetime cleanup routine?

Details

Environment

  • clickhouse-go version: v2.30.0
  • Interface: database/sql compatible driver
  • Go version: 1.22.10
  • Operating system: amazon-linux-2023
  • ClickHouse version: 24.8
  • Is it a ClickHouse Cloud? yes
  • ClickHouse Server non-default settings, if any: everything is default

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugcloudClickHouse Cloud related tests

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions