Why make a data service a service registry?

:leaves: LEAF version: 3.12

:jigsaw: LEAF component(s): service-registry

Issue/Question:
The new Kubernetes backed service discovery documentation suggests that anything can be a service registry. If I generate a new LEAF 3.12 service and answer ā€˜yes’ to the question, ā€œdo you want this service to be discoverableā€ a section is added to my values.yaml

  # service registry config
  - name: DISCOVERABLE_SERVICE_LABELS # the Discovery Labels other services must have for this service to discovery them (note: for multiple, comma separate them)
    value: 'discovery.leidos-leaf.com/discoverable=true'

Currently, we have a single 3.9 service-registry that is utilized by ten or twelve services. All the discovered services end up in a Mongo collection.

It reads like the new 3.12 Kubernetes Event based (non-rest) approach makes it very easy to have any new data service become a service registry and that having multiple service registries is acceptable.

My question is what is the use-case for having multiple service registries, other than to help migrate to the new Kubernetes Event approach?

Stephen,

Good question. I think having more than one registry is an implementation side-effect of the new approach rather than an answer to any specific use case. Having said that, if I hear of any use cases, I’ll let you know.