Skip to content
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

restore: CQL session created out of rpc_addresses #3418

Conversation

karol-kokoszka
Copy link
Collaborator

@karol-kokoszka karol-kokoszka commented Jun 13, 2023

Fixes #3411

This PR extends docker-compose.yaml used for integration-tests to include additional network.
Scylla's listen_address belongs to second network.
Scylla's rpc_address belongs to public network.

Scylla uses rpc_address to accept CQL connections when listen_address is used for node2node communication.

Issue #3411 showed that restore procedure in scylla-manager doesn't support such a setup.
This PR addresses that by querying ScyllaAPI to get the RPC address when creating CQL session.

Integration-tests are updated to work fine on current docer-compose environment.

db.go from testutils is moved to another package testutils/db to avoid import cycle.


"Only the Best is Good Enough." - LEGO company motto

Please make sure that:

  • Code is split to commits that address a single change
  • Commit messages are informative
  • Commit titles have module prefix
  • Commit titles have issue nr. suffix

@karol-kokoszka karol-kokoszka force-pushed the fix_restore_to_support_rpc_address_other_than_listen_address branch 6 times, most recently from 28fc0ed to 7203e83 Compare June 14, 2023 08:52
pkg/service/cluster/service.go Outdated Show resolved Hide resolved
pkg/service/cluster/service.go Show resolved Hide resolved
pkg/ping/dynamoping/main_test.go Outdated Show resolved Hide resolved
pkg/service/cluster/service.go Outdated Show resolved Hide resolved
@Michal-Leszczynski
Copy link
Collaborator

I understand that this issue has been found while using restore, but changes introduced in this PR do not change it's code anywhere. So is it really a restore issue?

Shouldn't commit restore: CQL session created out of rpc_addresses have cluster prefix?

@karol-kokoszka
Copy link
Collaborator Author

@Michal-Leszczynski it's not really the restore issue, but restore is affected the most.

@karol-kokoszka karol-kokoszka force-pushed the fix_restore_to_support_rpc_address_other_than_listen_address branch 2 times, most recently from 01e673b to 171d20b Compare June 14, 2023 15:21
@karol-kokoszka karol-kokoszka force-pushed the fix_restore_to_support_rpc_address_other_than_listen_address branch from 171d20b to a688f7b Compare June 14, 2023 15:24
@karol-kokoszka karol-kokoszka force-pushed the fix_restore_to_support_rpc_address_other_than_listen_address branch from a688f7b to f2833e7 Compare June 15, 2023 09:09
@karol-kokoszka karol-kokoszka force-pushed the fix_restore_to_support_rpc_address_other_than_listen_address branch from f2833e7 to 0e59135 Compare June 15, 2023 09:14
@karol-kokoszka karol-kokoszka merged commit b0b1f63 into master Jun 15, 2023
@karol-kokoszka karol-kokoszka deleted the fix_restore_to_support_rpc_address_other_than_listen_address branch June 15, 2023 09:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Issues when rpc_address != listen_address - Scylla Manager 3.1
2 participants