-
Notifications
You must be signed in to change notification settings - Fork 16
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 #983 from openedx/cag/autoscaling
feat: add autoscaling values for ralph and superset
- Loading branch information
Showing
4 changed files
with
68 additions
and
0 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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -4,3 +4,4 @@ black | |
pyinstaller | ||
pylint | ||
twine | ||
git+https://github.com/edunext/[email protected] |
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,51 @@ | ||
"""Filters usage.""" | ||
|
||
from tutorpod_autoscaling.hooks import ( # pylint: disable=import-error | ||
AUTOSCALING_CONFIG, | ||
) | ||
|
||
|
||
@AUTOSCALING_CONFIG.add() | ||
def add_aspects_autoscaling(autoscaling_config): | ||
"""Add autoscaling values for Aspects services.""" | ||
autoscaling_config.update( | ||
{ | ||
"ralph": { | ||
"enable_hpa": True, | ||
"memory_request": "300Mi", | ||
"cpu_request": 0.25, | ||
"memory_limit": "600Mi", | ||
"cpu_limit": 1, | ||
"min_replicas": 1, | ||
"max_replicas": 10, | ||
"avg_cpu": 80, | ||
"avg_memory": "", | ||
"enable_vpa": False, | ||
}, | ||
"superset": { | ||
"enable_hpa": True, | ||
"memory_request": "500Mi", | ||
"cpu_request": 0.25, | ||
"memory_limit": "1000Mi", | ||
"cpu_limit": 1, | ||
"min_replicas": 1, | ||
"max_replicas": 10, | ||
"avg_cpu": 80, | ||
"avg_memory": "", | ||
"enable_vpa": False, | ||
}, | ||
"superset-worker": { | ||
"enable_hpa": True, | ||
"memory_request": "600Mi", | ||
"cpu_request": 0.25, | ||
"memory_limit": "1500Mi", | ||
"cpu_limit": 1, | ||
"min_replicas": 1, | ||
"max_replicas": 10, | ||
"avg_cpu": 80, | ||
"avg_memory": "", | ||
"enable_vpa": False, | ||
}, | ||
} | ||
) | ||
return autoscaling_config |
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