forked from googleforgames/agones
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Prioritise Allocation from Nodes with Allocated/Ready GameServers
One of the first parts for Node autoscaling (googleforgames#368) - make sure we essentially bin pack our allocated game servers. This change makes allocation first prioritise allocation from `Nodes` that already have the most `Allocated` `GameServers`, and then in the case of a tie, to the `Nodes` that have the most `Ready` `GameServers`. This sets us up for the next part, such that when we scale down a Fleet, it removes `GameServers` from `Nodes` that have the least `GameServers` on them.
- Loading branch information
1 parent
d6858e2
commit 4cbaf3e
Showing
12 changed files
with
445 additions
and
33 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
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,53 @@ | ||
# Scheduling and Autoscaling | ||
|
||
⚠️⚠️⚠️ **This is currently a development feature and has not been released** ⚠️⚠️⚠️ | ||
|
||
> Autoscaling is currently ongoing work within Agones. The work you see here is just the beginning. | ||
Scheduling and autoscaling tend to go hand in hand, as where in the cluster `GameServers` are provisioned | ||
tends to impact how to autoscale fleets up and down (or if you would even want to) | ||
|
||
## Fleet Autoscaling | ||
|
||
Fleet autoscaling is currently the only type of autoscaling that exists in Agones. It is also only available as a simple | ||
buffer autoscaling strategy. Have a look at the [Create a Fleet Autoscaler](create_fleetautoscaler.md) quickstart, | ||
and the [Fleet Autoscaler Specification](fleetautoscaler_spec.md) for details. | ||
|
||
Node scaling, and more sophisticated fleet autoscaling will be coming in future releases ([design](https://github.com/GoogleCloudPlatform/agones/issues/368)) | ||
|
||
## Fleet Allocation Scheduling | ||
|
||
There are two scheduling strategies for fleets - each designed for different types of Kubernetes Environments. | ||
|
||
### Packed | ||
|
||
This is the *default* Fleet scheduling strategy. It is designed for dynamic Kubernetes environments, wherein you wish | ||
to scale up and down as load increases or decreases, such as in a Cloud environment where you are paying | ||
for the infrastructure you use. | ||
|
||
It attempts to _pack_ as much as possible into the smallest set of nodes, to make | ||
scaling infrastructure down as easy as possible. | ||
|
||
Currently, Allocation scheduling is the only aspect this strategy affects, but in future releases it will | ||
also affect `GameServer` `Pod` scheduling, and `Fleet` scale down scheduling as well. | ||
|
||
#### Allocation Scheduling | ||
|
||
Under the "Packed" strategy, allocation will prioritise allocating `GameServers` to nodes that are running on | ||
Nodes that already have allocated `GameServers` running on them. | ||
|
||
### Distributed | ||
|
||
This Fleet scheduling strategy is designed for static Kubernetes environments, such as when you are running Kubernetes | ||
on bare metal, and the cluster size rarely changes, if at all. | ||
|
||
This attempts to distribute the load across the entire cluster as much as possible, to take advantage of the static | ||
size of the cluster. | ||
|
||
Currently, the only thing the scheduling strategy affects is Allocation scheduling, but in future releases it will | ||
also affect `GameServer` `Pod` scheduling, and `Fleet` scaledown scheduling as well. | ||
|
||
#### Allocation Scheduling | ||
|
||
Under the "Distributed" strategy, allocation will prioritise allocating `GameSerers` to nodes that have the least | ||
number of allocated `GameServers` on them. |
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
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
Oops, something went wrong.