scylladb / gocql

Package gocql implements a fast and robust ScyllaDB client for the Go programming language.
https://docs.scylladb.com/stable/using-scylla/drivers/cql-drivers/scylla-go-driver.html
BSD 3-Clause "New" or "Revised" License
181 stars 57 forks source link

Fix setting up connection to non-IP sockets #178

Closed sylwiaszunejko closed 3 months ago

sylwiaszunejko commented 4 months ago

Before the fix using a custom Dialer which connects to unix socket would fail: https://github.com/scylladb/scylla-manager/issues/3831#issuecomment-2106877132.

This PR makes the code default to the defaultPort in case unix socket is used and we cannot get tcp address by conn.conn.RemoteAddr().(*net.TCPAddr). I also added test for that.

Fixes: https://github.com/scylladb/gocql/issues/175

sylwiaszunejko commented 4 months ago

I am not sure how to access maintenance socket (cql.m). Mounting directories seem to not work properly (permission denied). I could use some advice here how to solve it.

sylwiaszunejko commented 4 months ago

v2.

@avelanarius @Michal-Leszczynski

sylwiaszunejko commented 4 months ago

v3: I changed the scylla version to 6.0.0 and now CI works.

sylwiaszunejko commented 4 months ago

@avelanarius Could you take a look?

sylwiaszunejko commented 3 months ago

@avelanarius ping

sylwiaszunejko commented 3 months ago

@avelanarius @roydahan Could you look at it?