fix subscribe bug:select enable instance only. (#8629)
This commit is contained in:
parent
1a4759e7ba
commit
654462e41d
@ -70,7 +70,8 @@ public class SubscribeServiceRequestHandler extends RequestHandler<SubscribeServ
|
||||
Subscriber subscriber = new Subscriber(meta.getClientIp(), meta.getClientVersion(), app, meta.getClientIp(),
|
||||
namespaceId, groupedServiceName, 0, request.getClusters());
|
||||
ServiceInfo serviceInfo = ServiceUtil.selectInstancesWithHealthyProtection(serviceStorage.getData(service),
|
||||
metadataManager.getServiceMetadata(service).orElse(null), subscriber);
|
||||
metadataManager.getServiceMetadata(service).orElse(null), subscriber.getCluster(), false,
|
||||
true, subscriber.getIp());
|
||||
if (request.isSubscribe()) {
|
||||
clientOperationService.subscribeService(service, subscriber, meta.getConnectionId());
|
||||
NotifyCenter.publishEvent(new NamingTraceEvent.SubscribeServiceTraceEvent(System.currentTimeMillis(),
|
||||
|
Loading…
Reference in New Issue
Block a user