From 6ce53557b192a6e99b12abc38da6aeb8da551c80 Mon Sep 17 00:00:00 2001 From: Alec Thomas <112640918+a-thomas-22@users.noreply.github.com> Date: Tue, 17 Dec 2024 23:23:53 -0600 Subject: [PATCH 1/4] Add block validator memory settings --- charts/nitro/Chart.yaml | 2 +- charts/nitro/ci/sepolia-values.yaml | 2 ++ charts/nitro/templates/_helpers.tpl | 4 ++++ charts/nitro/values.yaml | 5 +++++ 4 files changed, 12 insertions(+), 1 deletion(-) diff --git a/charts/nitro/Chart.yaml b/charts/nitro/Chart.yaml index fe5fbdf..ccca64b 100644 --- a/charts/nitro/Chart.yaml +++ b/charts/nitro/Chart.yaml @@ -7,6 +7,6 @@ maintainers: type: application -version: 0.6.20 +version: 0.6.21 appVersion: "v3.2.1-d81324d" diff --git a/charts/nitro/ci/sepolia-values.yaml b/charts/nitro/ci/sepolia-values.yaml index 3c07d39..6463cae 100644 --- a/charts/nitro/ci/sepolia-values.yaml +++ b/charts/nitro/ci/sepolia-values.yaml @@ -43,6 +43,8 @@ resources: env: resourceMgmtMemFreeLimit: enabled: true + blockValidatorMemFreeLimit: + enabled: true configmap: data: diff --git a/charts/nitro/templates/_helpers.tpl b/charts/nitro/templates/_helpers.tpl index ddc7728..c1a51ce 100644 --- a/charts/nitro/templates/_helpers.tpl +++ b/charts/nitro/templates/_helpers.tpl @@ -115,6 +115,10 @@ nitro args - name: {{ $envPrefix }}_NODE_RESOURCE__MGMT_MEM__FREE__LIMIT value: {{ printf "%dB" (int (mulf $valueMi ($.Values.env.resourceMgmtMemFreeLimit.multiplier | default 0.05) 1048576)) }} {{- end }} +{{- if $.Values.env.blockValidatorMemFreeLimit.enabled }} +- name: {{ $envPrefix }}_NODE_BLOCK__VALIDATOR_MEM__FREE__LIMIT + value: {{ printf "%dB" (int (mulf $valueMi ($.Values.env.blockValidatorMemFreeLimit.multiplier | default 0.05) 1048576)) }} +{{- end }} {{- end -}} {{- end -}} diff --git a/charts/nitro/values.yaml b/charts/nitro/values.yaml index dcbc13b..5254d8c 100644 --- a/charts/nitro/values.yaml +++ b/charts/nitro/values.yaml @@ -49,6 +49,8 @@ updateStrategy: ## @param env.nitro.goMemLimit.multiplier The multiplier of available memory to use for nitro ## @param env.resourceMgmtMemFreeLimit.enabled Enable nitro resource management ## @param env.resourceMgmtMemFreeLimit.multiplier The multiplier of available memory to use +## @param env.blockValidatorMemFreeLimit.enabled Enable block validator memory management +## @param env.blockValidatorMemFreeLimit.multiplier The multiplier of available memory to use env: splitvalidator: goMemLimit: @@ -61,6 +63,9 @@ env: resourceMgmtMemFreeLimit: enabled: false multiplier: 0.05 + blockValidatorMemFreeLimit: + enabled: false + multiplier: 0.05 ## @param persistence.enabled Enable persistence ## @param persistence.size Size of the persistent volume claim From 2ab7a71e88b9cf7240eb1cb4735e8b9df4de23e6 Mon Sep 17 00:00:00 2001 From: a-thomas-22 Date: Wed, 18 Dec 2024 05:25:35 +0000 Subject: [PATCH 2/4] Update README and values.schema.json for modified charts --- charts/nitro/README.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/charts/nitro/README.md b/charts/nitro/README.md index 28bc357..5d2498c 100644 --- a/charts/nitro/README.md +++ b/charts/nitro/README.md @@ -96,6 +96,8 @@ helm install xai offchainlabs/nitro -f values.yaml | `env.nitro.goMemLimit.multiplier` | The multiplier of available memory to use for nitro | `0.9` | | `env.resourceMgmtMemFreeLimit.enabled` | Enable nitro resource management | `false` | | `env.resourceMgmtMemFreeLimit.multiplier` | The multiplier of available memory to use | `0.05` | +| `env.blockValidatorMemFreeLimit.enabled` | Enable block validator memory management | `false` | +| `env.blockValidatorMemFreeLimit.multiplier` | The multiplier of available memory to use | `0.05` | | `persistence.enabled` | Enable persistence | `true` | | `persistence.size` | Size of the persistent volume claim | `500Gi` | | `persistence.storageClassName` | Storage class of the persistent volume claim | `nil` | From 05500709b52b66360d6716f175b7622bba5a980c Mon Sep 17 00:00:00 2001 From: Alec Thomas <112640918+a-thomas-22@users.noreply.github.com> Date: Tue, 17 Dec 2024 23:27:07 -0600 Subject: [PATCH 3/4] Trigger CI From 163522329b0761906a1d17f68c2f5b3aa20d0bcb Mon Sep 17 00:00:00 2001 From: Alec Thomas <112640918+a-thomas-22@users.noreply.github.com> Date: Tue, 17 Dec 2024 23:35:43 -0600 Subject: [PATCH 4/4] Update _helpers.tpl --- charts/nitro/templates/_helpers.tpl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/charts/nitro/templates/_helpers.tpl b/charts/nitro/templates/_helpers.tpl index c1a51ce..b690b4a 100644 --- a/charts/nitro/templates/_helpers.tpl +++ b/charts/nitro/templates/_helpers.tpl @@ -116,7 +116,7 @@ nitro args value: {{ printf "%dB" (int (mulf $valueMi ($.Values.env.resourceMgmtMemFreeLimit.multiplier | default 0.05) 1048576)) }} {{- end }} {{- if $.Values.env.blockValidatorMemFreeLimit.enabled }} -- name: {{ $envPrefix }}_NODE_BLOCK__VALIDATOR_MEM__FREE__LIMIT +- name: {{ $envPrefix }}_NODE_BLOCK__VALIDATOR_MEMORY__FREE__LIMIT value: {{ printf "%dB" (int (mulf $valueMi ($.Values.env.blockValidatorMemFreeLimit.multiplier | default 0.05) 1048576)) }} {{- end }} {{- end -}}