publish method
Publish message to a channel
await redis.publish('chat', 'hello')
Implementation
Future<void> publish(String channel, String message) async {
if (redisClientType == RedisType.subscriber) {
throw Exception('cannot subscribe and publish on same connection');
}
redisClientType = RedisType.publisher;
await sendCommand(<String>['PUBLISH', channel, message]);
}