-
Notifications
You must be signed in to change notification settings - Fork 778
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 #3 from indexjoseph/api-changes
add API changes for scheduled autoscalers
- Loading branch information
Showing
27 changed files
with
3,193 additions
and
13 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,104 @@ | ||
# Copyright 2023 Google LLC All Rights Reserved. | ||
# | ||
# Licensed under the Apache License, Version 2.0 (the "License"); | ||
# you may not use this file except in compliance with the License. | ||
# You may obtain a copy of the License at | ||
# | ||
# http://www.apache.org/licenses/LICENSE-2.0 | ||
# | ||
# Unless required by applicable law or agreed to in writing, software | ||
# distributed under the License is distributed on an "AS IS" BASIS, | ||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
# See the License for the specific language governing permissions and | ||
# limitations under the License. | ||
|
||
# | ||
# [Stage:Alpha] | ||
# [FeatureFlag:ScheduledAutoscaler] | ||
# Example of a FleetAutoscaler - This is used to scale a fleet on a schedule, | ||
# allowing for different policies to be applied at different times. | ||
# | ||
|
||
# | ||
# For a full reference and details: https://agones.dev/site/docs/reference/fleetautoscaler/ | ||
# | ||
apiVersion: autoscaling.agones.dev/v1 | ||
kind: FleetAutoscaler | ||
metadata: | ||
name: chain-fleet-autoscaler | ||
spec: | ||
policy: | ||
type: Chain # Chain based policy for autoscaling. | ||
chain: | ||
# Id of chain entry. | ||
# Optional. | ||
- uid: "weekday" | ||
type: Schedule # Schedule based condition. | ||
schedule: | ||
# Timezone to be used for the schedule. | ||
timezone: "America/New_York" | ||
between: | ||
# The policy becomes eligible for application starting on | ||
# Feb 20, 2024 at 4:04 PM. | ||
# Optional. | ||
start: "2024-02-19 16:04:00" | ||
# The policy becomes ineligible for application on | ||
# Feb 23, 2024 at 4:04 PM. | ||
# Optional. | ||
end: "2024-02-23 16:04:00" # optional | ||
activePeriod: | ||
# Start applying the bufferSize everyday at 1:00 AM | ||
# (Only eligible starting on Feb 20, 2024 at 4:04 PM.) | ||
# Optional. | ||
startCron: "0 1 * * 0" | ||
# Only apply the bufferSize for this 5 hours | ||
# Optional. | ||
duration: "5h" | ||
# Policy to be applied when the condition is met. | ||
# Required. | ||
policy: | ||
type: Buffer | ||
buffer: | ||
bufferSize: 50 | ||
minReplicas: 100 | ||
maxReplicas: 2000 | ||
# Id of chain entry. | ||
# Optional. | ||
- uid: "weekend" | ||
type: Schedule | ||
schedule: | ||
# Timezone to be used for the schedule. | ||
timezone: "America/New_York" | ||
between: | ||
# The policy becomes eligible for application starting on | ||
# Feb 24, 2024 at 4:05 PM. | ||
# Optional. | ||
start: "2024-02-24 16:05:00" | ||
start: "2024-02-26 16:05:00" | ||
activePeriod: | ||
# Start applying the bufferSize everyday at 1:00 AM | ||
# (Only eligible starting on Feb 24, 2024 at 4:05 PM.) | ||
# Optional. | ||
startCron: "0 1 * * 0" | ||
# Only apply the bufferSize for this 7 hours | ||
# Optional. | ||
duration: "7h" | ||
# Policy to be applied when the condition is met. | ||
# Required. | ||
policy: | ||
type: Counter | ||
counter: | ||
key: rooms | ||
bufferSize: 10 | ||
minCapacity: 500 | ||
maxCapacity: 1000 | ||
# Id of chain entry. | ||
- uid: "default" | ||
# Policy will always be applied when no other policy is applicable. | ||
# Required. | ||
policy: | ||
type: Buffer | ||
buffer: | ||
bufferSize: 5 | ||
minReplicas: 100 | ||
maxReplicas: 2000 |
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.