-
Notifications
You must be signed in to change notification settings - Fork 59
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix setting up connection to non-IP sockets #178
Conversation
I am not sure how to access maintenance socket ( |
2a3722a
to
a87184a
Compare
v2.
|
docker-compose.yml
Outdated
@@ -2,7 +2,7 @@ version: "3.7" | |||
|
|||
services: | |||
node_1: | |||
image: ${SCYLLA_IMAGE} | |||
image: scylladb/scylla-nightly |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is bad idea, this CICD needs to be stable.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think that scylla-enterprise-nightly:latest-enterprise
is more stable and still allows for testing the newest release without changing docker tags in every PR.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
before this PR you could test it by SCYLLA_VERSION=scylla-enterprise-nightly:latest-enterpris ./integration.sh
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is perfect example of why you should not run cicd on nightly builds:
https://github.com/scylladb/gocql/actions/runs/9346882983/job/25722658483?pr=186
It is failing because image is broken, now you either ignore pipeline failure, or wait till working image is published.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I will create separate PR to use newer version of SCYLLA_IMAGE for all of the nodes and I will bump scylla version in github workflows
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You can use "latest" tag which is the latest release we have (Not RC) in (scylladb/scylla not nightly).
testdata/recreate/table_golden.cql
Outdated
@@ -42,7 +42,7 @@ CREATE TABLE gocqlx_table.monkeyspecies ( | |||
AND max_index_interval = 2048 | |||
AND memtable_flush_period_in_ms = 0 | |||
AND min_index_interval = 128 | |||
AND read_repair_chance = 1 | |||
AND read_repair_chance = 0 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could you please clarify how this is related to the PR?
0f066e8
to
b9620cb
Compare
v3: |
@avelanarius Could you take a look? |
if err != nil { | ||
panic(fmt.Sprintf("unable to create session: %v", err)) | ||
} | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Shouldn't you ran a query to make sure session is operational ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I could add it, but I thought it was not necessary cause the issue was discovered without it
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
True, but you know, lot's of things happening between session creation and query being executed, aren't we need to make sure that whole thing is working ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I have added the queries
b9620cb
to
cdcabe3
Compare
@avelanarius ping |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Beside force_schema_commit_log
issue, look greate.
@@ -8,5 +8,4 @@ client_encryption_options: | |||
keyfile: /etc/scylla/db.key | |||
truststore: /etc/scylla/ca.crt | |||
require_client_auth: true | |||
# when using 5.4.x we have to specify force_schema_commit_log option | |||
force_schema_commit_log: true |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Have you deleted it intentionaly, since it is used by dirver-matrix I do not recommend deleting it
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think it was only necessary to specify it in 5.4.x. In the 6.0 it should be enabled be default
@avelanarius @roydahan Could you look at it? |
keyfile: /etc/scylla/db.key | ||
truststore: /etc/scylla/ca.crt | ||
require_client_auth: true | ||
# when using 5.4.x we have to specify force_schema_commit_log option | ||
force_schema_commit_log: true | ||
maintenance_socket: workdir |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The addition of maintenance_socket
here is not related to the commit description. Why is it here?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You are right it should be in the second commit
control_integration_test.go
Outdated
err = createTable(sess, `DROP KEYSPACE IF EXISTS `+keyspace) | ||
if err != nil { | ||
t.Fatal("unable to drop keyspace:", err) | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'd say: "unable to drop keyspace if exists", because otherwise the message would imply unconditional dropping of a keyspace, and such could fail due to e.g. lack of such keyspace defined.
Remove {dclocal_,}read_repair_chance options from tests as they are deprecated in scylladb/scylladb#18087. Remove `tablets` and `consistent-topology-feature` experimental flags as they are not longer experimental.
cdcabe3
to
76878db
Compare
Before the fix using a custom Dialer which connects to unix socket would fail: scylladb/scylla-manager#3831 (comment).
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: #175