Nomad + Connect: Tag based routing
- Dominant language
- Go
- Stars
- 17k
- Forks
- 2.1k
- Avg merge
- 1d 9h
- Merged PRs (30d)
- 105
Description
Hi,
Currently while using Nomad + Connect you should specify [upstream](https://www.nomadproject.io/docs/job-specification/upstreams) and you will be able to use it later via variables interpolation to access service from that upstream.
I wonder if Nomad can support the following scenario:
We have a service with multiple instances. Half of the instances are the old version of the app and have a service tag `version=1.0` and half a new version of the app and has service tag `version=2.0`
I'd like to be able to specify tag-based filtering so the request will be sent only to instances with a specific tag match.
For example:
```
env {
COUNTING_SERVICE_URL = "http://${NOMAD_UPSTREAM_ADDR_count_api_TAGS_version_2.0}"
}
```
Not sure if that filtering has to be done by Envoy and by some additional LB inside the mesh.
Use cases are Blue\Green deployments & API incompatibilities for example.
I want to be able to make sure client_1.0 is communicating with server_1.0 only, etc.
Even better if something like regexps or comparison would be possible like `(tag: version, match_value: >=1.0)`
Contributor guide
No contributing guide indexed for this repository
Research direction
Begin with the upstream specification linked in the issue and the NOMAD_UPSTREAM_ADDR interpolation example; compare how Connect and Envoy currently select upstream instances. A complete proposal should define tag-matching semantics, including whether regex or comparisons are supported, and cover the blue/green and version-isolation cases.
Written by the indexing model from the issue text.
Assessment
- Domain
- backend, distributed-systems, networking
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 25/100