fix(research): normalize Compose memory limits before checking RSS
This commit is contained in:
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,10 @@
|
|||||||
|
Traceback (most recent call last):
|
||||||
|
File "<frozen runpy>", line 203, in _run_module_as_main
|
||||||
|
File "<frozen runpy>", line 88, in _run_code
|
||||||
|
File "<repository>/scripts/research_slo.py", line 631, in <module>
|
||||||
|
main()
|
||||||
|
~~~~^^
|
||||||
|
File "<repository>/scripts/research_slo.py", line 479, in main
|
||||||
|
max(s["signals"]["collector_memory"] for s in points)
|
||||||
|
< report["container_limits"]["otel"]["mem_limit"]
|
||||||
|
TypeError: '<' not supported between instances of 'float' and 'str'
|
||||||
@@ -224,7 +224,9 @@ def main():
|
|||||||
config = json.loads(compose("config", "--format", "json"))
|
config = json.loads(compose("config", "--format", "json"))
|
||||||
report["container_limits"] = {
|
report["container_limits"] = {
|
||||||
name: {
|
name: {
|
||||||
k: service[k]
|
k: int(service[k])
|
||||||
|
if k in {"mem_limit", "memswap_limit", "scale"}
|
||||||
|
else service[k]
|
||||||
for k in ["cpus", "mem_limit", "memswap_limit", "scale"]
|
for k in ["cpus", "mem_limit", "memswap_limit", "scale"]
|
||||||
if k in service
|
if k in service
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user