Draft: WIP: new try with configTolerations
Previous attempt tried to evaluate all configurations for all zones (which resulted in important perf regression (roughly ×2).
This attempt only evaluates configTolerations and keep configurations optional (configurations are constraints not evaluated until a concrete config is added to envs: <zone>: configurations:. The impact on perf is minimal (and doesn't require huge refacto of conf to have fields defined in all contexts)
note:
-
configTolerationsshould not depends onconfigurationsto prevent evaluation cycles. - files with
TMP_prefix are temporary, they are used to bench the current implementation without big rewrite - the current POC only works for infra-stg
Eval time:
- with tolerations:
❯ time cue eval -t staging -t targeted_zones=infra-stg -e 'envs."infra-stg".configurations' > /dev/null cue eval -t staging -t targeted_zones=infra-stg -e > /dev/null 14,48s user 0,26s system 149% cpu 9,829 total - without tolerations:
❯ time cue eval -t staging -t targeted_zones=infra-stg -e 'envs."infra-stg".configurations' > /dev/null cue eval -t staging -t targeted_zones=infra-stg -e > /dev/null 13,13s user 0,33s system 146% cpu 9,169 total
Edited by Ghost User