Add ControlConnectionQueryFallback option
Summary
Add an option to allow routing application queries through the control connection when node connection pools are unavailable, similar to the Python driver's ControlConnectionQueryFallback.
Background
The Python driver provides a ControlConnectionQueryFallback setting on the Cluster object with three modes:
Disabled (default) - requires a usable node pool for application queries. If none is available, the driver raises NoHostAvailable.
Fallback - still attempts to create node pools, but allows application queries to fall back to the control connection when no usable pool is available. Session startup proceeds even if all initial pool attempts fail.
SkipPoolCreation - disables node-pool creation entirely and routes all application queries through the control connection.
Current state in the Rust driver
The Rust driver's ControlConnection is used exclusively for metadata fetching and event listening. There is currently no way to route user queries through it when connection pools are unavailable, the driver will return a connection error instead.
References
Add
ControlConnectionQueryFallbackoptionSummary
Add an option to allow routing application queries through the control connection when node connection pools are unavailable, similar to the Python driver's
ControlConnectionQueryFallback.Background
The Python driver provides a
ControlConnectionQueryFallbacksetting on theClusterobject with three modes:Disabled(default) - requires a usable node pool for application queries. If none is available, the driver raisesNoHostAvailable.Fallback- still attempts to create node pools, but allows application queries to fall back to the control connection when no usable pool is available. Session startup proceeds even if all initial pool attempts fail.SkipPoolCreation- disables node-pool creation entirely and routes all application queries through the control connection.Current state in the Rust driver
The Rust driver's
ControlConnectionis used exclusively for metadata fetching and event listening. There is currently no way to route user queries through it when connection pools are unavailable, the driver will return a connection error instead.References
cassandra.cluster.ControlConnectionQueryFallback(source)