-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #80 from onmetal/scope_region
Add region field to `Scope` resource
- Loading branch information
Showing
4 changed files
with
34 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,4 +3,5 @@ kind: Scope | |
metadata: | ||
name: scope-sample | ||
spec: | ||
#region: frankfurt1 | ||
description: yolo |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
# Why certain design decisions have been made | ||
|
||
## Namespace replication | ||
|
||
Namespaces should be replicated from the user facing (global API) to the | ||
corresponding region specific API machinery based on the regional notion of the | ||
namespace. This is determined by the `region` field in the scope definition | ||
|
||
```yaml | ||
apiVersion: core.onmetal.de/v1alpha1 | ||
kind: Scope | ||
metadata: | ||
name: scope-sample | ||
spec: | ||
region: frankfurt1 | ||
description: "my scope" | ||
``` | ||
In case the `region` field is empty, as it is an optional field, the namespace will | ||
be synced down to all infrastructure clusters. | ||
|
||
The idea of keeping track of how many regional objects are in a particular namespace | ||
has been dismissed, as it is hard to track how many of those objects are inside a namespace, | ||
especially since this has to be done in the `parant` hierarchy as well. | ||
|
||
As a result of this descission the `region` field on all given objects must be immutable. |