Skip to content

Commit

Permalink
Fix GameServerAllocation preferred documentation
Browse files Browse the repository at this point in the history
There was a bug in the reference docs that read that the `required`
check was applied to all queries, including the preferred check.

This is not the case - each label selector is independent.

Fixing this in the documentation.
  • Loading branch information
markmandel committed Mar 17, 2021
1 parent e660be7 commit 5614be2
Showing 1 changed file with 10 additions and 8 deletions.
18 changes: 10 additions & 8 deletions site/content/en/docs/Reference/gameserverallocation.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,8 @@ spec:
game: my-game
matchExpressions:
- {key: tier, operator: In, values: [cache]}
# ordered list of preferred allocations out of the `required` set.
# An ordered list of preferred GameServer label selectors
# that are optional to be fulfilled, but will be searched before the `required` selector.
# If the first selector is not matched, the selection attempts the second selector, and so on.
# This is useful for things like smoke testing of new game servers.
# This also support `matchExpressions`
Expand Down Expand Up @@ -55,13 +56,14 @@ name for the `GameServerAllocation` is generated when the `GameServerAllocation`

The `spec` field is the actual `GameServerAllocation` specification and it is composed as follow:

- `required` is a [label selector](https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/)
(matchLabels and/or matchExpressions) from which to choose GameServers from.
GameServers still have the hard requirement to be `Ready` to be allocated from
- `preferred` is an order list of [label selectors](https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/)
out of the `required` set.
If the first selector is not matched, the selection attempts the second selector, and so on.
This is useful for things like smoke testing of new game servers.
- `required` is a [label selector](https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/)
(matchLabels and/or matchExpressions) from which to choose GameServers from.
GameServers still have the hard requirement to be `Ready` to be allocated from
- `preferred` is an ordered list of preferred
[label selectors](https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/)
that are _optional_ to be fulfilled, but will be searched before the `required` selector.
If the first selector is not matched, the selection attempts the second selector, and so on.
This is useful for things like smoke testing of new game servers.
- `scheduling` defines how GameServers are organised across the cluster, in this case specifically when allocating
`GameServers` for usage.
"Packed" (default) is aimed at dynamic Kubernetes clusters, such as cloud providers, wherein we want to bin pack
Expand Down

0 comments on commit 5614be2

Please sign in to comment.