pub async fn pubsub_connect(
    host: impl Into<String>,
    port: u16
) -> Result<PubsubConnection, Error>
Expand description

Used for Redis’s PUBSUB functionality.

Returns a future that resolves to a PubsubConnection. The future will only resolve once the connection is established; after the intial establishment, if the connection drops for any reason (e.g. Redis server being restarted), the connection will attempt re-connect, however any subscriptions will need to be re-subscribed.