优化回调设置方式

2.7.0
648540858 2024-04-16 22:22:00 +08:00
parent 9c6765d44e
commit f357bece62
1 changed files with 2 additions and 4 deletions

View File

@ -193,12 +193,10 @@ public class RedisRpcConfig implements MessageListener {
}
private void setCallback(long key, CommonCallback<RedisRpcResponse> callback) {
if (!callbacks.containsKey(key)) {
// TODO 如果多个上级点播同一个通道会有问题
callbacks.put(key, callback);
}
}
public void removeCallback(long key) {
callbacks.remove(key);
}