sub.unsubscribe
不会删除频道,那么我该如何删除频道呢?
我尝试了channel.close()
或者channel.quit()
但是都没有成功!
代码:
let roomChannelName = room_${roomId}_server;
let sub = redis.createClient(redisConfig);
const channel = this.scServer.exchange.channel(roomChannelName);
sub.unsubscribe(roomChannelName);
this.scServer.exchange.destroyChannel(roomChannelName)