connect method
Establish a connection to the Redis server. The delay between connection attempts. 与Redis服务器建立连接 连接尝试之间的延迟。
Implementation
Future<void> connect() async {
// 判断当前连接状态
if (_closed) throw StateError('RedisClient has been closed.');
/// 异步等待连接完成
unawaited(_reconnect(retryAttempts: _socketOptions.retryAttempts));
/// 返回处理连接完成的状态
return _untilConnected;
}