Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Async cluster connection: Improve handling of missing connections (re…
…dis-rs#968) * aio::ClusterConnection: Report missing connections. This change should ensure that if a connection wasn't found, after redirecting to node, or when no random connection is available, then the cluster connection will refresh slots. * Add sleep to refresh slots action. * Cancel redirects after disconnects. If a redirected request reaches a disconnected node, the redirection will be cancelled, and the routing will revert to the original routing. * Move OperationTarget to Err side of result, and reduce generics. OperationTarget is used only on errors, so it should be in the `Err` case only. The added generics were used to hide a single type. * Handle disconnect from all nodes. If the async cluster connection completely disconnects from all nodes in the server, it will try again to connect to the inital nodes that were provided upon creation. This prevents a situation where the client removes connections incrementally, until the connection map is completely empty, and there are no connections to refresh slots on.
- Loading branch information