-
Notifications
You must be signed in to change notification settings - Fork 109
Description
Disclaimer: this may/does have some overlap with #58. This is merely to start spit balling ideas on how we would even accomplish this or what specific feature set we would want to accomplish upon implementation.
Enhancement/Feature Request:
(as discussed in slack) It would be great if we could have hierarchical registration within Swarm. I have a application that is using Swarm but is distributed geographically among many DC (data centers) both internally and with various public cloud providers. These Swarm clusters are independent and I have to wire them together external to Swarm currently.
Basically what I am thinking is that you can ask a top level Swarm for a process name, it tells me what DC it's in and I start talk to that DC/process. Ideally, you'd also be able to direct process creation to a specific DC as well (this is where #58 starts coming into play).
I'm aware that process groups are a thing in Swarm but afaik there is no way to say "This process group belongs to this/these node(s)". So Doing something like hierarchical registration starts to bring that into the picture. You could say "I want to have a new process created and manged by Swarm in DC2, on nodes 'labeled' with, or has the 'role' 'web' within DC2, and made a part of the 'UI' process group". Rather ambitious but a very nice feature to have.
+-----------+
| |
| |
+------+ Top Level +------+
| | | |
| | | |
| +-----------+ |
| |
| |
| |
+-----v-----+ +-----v-----+
| | | |
| | | |
+-----------+ DC1 | | DC2 +-----------+
| | | | | |
| | | | | |
| +---+-------+ +-----+-----+ |
| | | |
+---+ +---+ +---+ +--+ +--+ +--+ +--+ +--+ +--+ +---+ +---+
| | | |
| | | |
+-----v-----+ +------v-------+ +-----v-----+ +--------v-----+
|Node1 "web"| |Node2 "engine"| |Node1 "web"| |Node2 "engine"|
+-----------+ +--------------+ +--+------+-+ +--------------+
| |
+--v-+ +--v--+
| UI | | API |
+----+ +-----+