slime-io / slime

An intelligent ServiceMesh manager based on Istio
https://slime-io.github.io/
Other
424 stars 78 forks source link

meshreg: epselector supports instance ip blacklist #414

Closed believening closed 1 year ago

believening commented 1 year ago

backgrounds

api design

usage

# example configuration:
ZookeeperSource:
  AlwaysUseSourceScopedEpSelectors: true 
  ServicedEndpointSelectors:
    "bar":
    - ExcludeIPRanges:
        IPs:
        - 1.1.1.1
  EndpointSelectors:
  - matchExpressions:
    - key: app
      operator: In
      values:
      - foo
      - bar

Using the example configuration, serviceentry will only be generated for foo and bar services, and if an instance ip of bar service is "1.1.1.1", the instance will not appear as an available ep of bar service in serviceentry.