修复删除zk节点导致的BUG

1.x
tanghc 5 years ago
parent 222e722f75
commit 6f34e9288e
  1. 1
      sop-common/sop-gateway-common/src/main/java/com/gitee/sop/gatewaycommon/zuul/route/ZuulRouteRepository.java

@ -47,6 +47,7 @@ public class ZuulRouteRepository implements RouteRepository<ZuulTargetRoute> {
public void deleteAll(String serviceId) {
Collection<ZuulTargetRoute> values = nameVersionTargetRouteMap.values();
List<String> idList = values.stream()
.filter(zuulTargetRoute -> zuulTargetRoute.getServiceRouteInfo().getServiceId().equalsIgnoreCase(serviceId))
.map(zuulTargetRoute -> zuulTargetRoute.getRouteDefinition().getId())
.collect(Collectors.toList());

Loading…
Cancel
Save