-
Notifications
You must be signed in to change notification settings - Fork 142
Open
Labels
area/metadatacpp-rust-driver-p1Functionality required by cpp-rust-driverFunctionality required by cpp-rust-driverenhancementNew feature or requestNew feature or request
Milestone
Description
cpp-driver has a feature called listener callback. It allows users to register a function that will be called when some node status changes (added / removed / up / down).
As far as we can tell, it is based on events (+ sends artificial add+up events when connecting), without fully considering issues with dropped control connection.
To be able to implement this functionality in cpp-rs-driver, Rust Driver first needs to expose it.
Ultimately, we would like to have such channel exposed to user to:
- Expose more information than topology (see e.g. Provide event for the ScyllaDB schema change #1405 )
- Have "good" semantics: for example handle CC dropping and send artificial events to account for that after reconnecting. Without this, such callback is not really reliable. See Insufficient guarantees regarding ordering of events and control connection breakage. #1409
For now, it will be enough to just have a simple api guarded by cpp-rust-unstable, so that the cpp-rs-driver feature can be implemented. cpp-driver also doesn't consider the above issues, so it should not be a regression.
Metadata
Metadata
Assignees
Labels
area/metadatacpp-rust-driver-p1Functionality required by cpp-rust-driverFunctionality required by cpp-rust-driverenhancementNew feature or requestNew feature or request