Skip to content

Commit 6bccf09

Browse files
authored
feat: deprecate DYN_SYSTEM_ENABLED in favor of DYN_SYSTEM_PORT (#4082)
Signed-off-by: Keiven Chang <[email protected]> Co-authored-by: Keiven Chang <[email protected]>
1 parent d1cf3c2 commit 6bccf09

File tree

44 files changed

+111
-120
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

44 files changed

+111
-120
lines changed

components/src/dynamo/frontend/main.py

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -251,6 +251,16 @@ async def async_main():
251251
dump_config(flags.dump_config_to, flags)
252252
is_static = bool(flags.static_endpoint) # true if the string has a value
253253

254+
# Warn if DYN_SYSTEM_PORT is set (frontend doesn't use system metrics server)
255+
if os.environ.get("DYN_SYSTEM_PORT"):
256+
logger.warning(
257+
"=" * 80 + "\n"
258+
"WARNING: DYN_SYSTEM_PORT is set but NOT used by the frontend!\n"
259+
"The frontend does not expose a system metrics server.\n"
260+
"Only backend workers should set DYN_SYSTEM_PORT.\n"
261+
"Use --http-port to configure the frontend HTTP API port.\n" + "=" * 80
262+
)
263+
254264
# Configure Dynamo frontend HTTP service metrics prefix
255265
if flags.metrics_prefix is not None:
256266
prefix = flags.metrics_prefix.strip()

container/README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -357,13 +357,13 @@ python -m dynamo.frontend &
357357

358358
# 4. Start worker backend (choose one framework):
359359
# vLLM
360-
DYN_SYSTEM_ENABLED=true DYN_SYSTEM_PORT=8081 python -m dynamo.vllm --model Qwen/Qwen3-0.6B --gpu-memory-utilization 0.20 --enforce-eager --no-enable-prefix-caching --max-num-seqs 64 &
360+
DYN_SYSTEM_PORT=8081 python -m dynamo.vllm --model Qwen/Qwen3-0.6B --gpu-memory-utilization 0.20 --enforce-eager --no-enable-prefix-caching --max-num-seqs 64 &
361361

362362
# SGLang
363-
DYN_SYSTEM_ENABLED=true DYN_SYSTEM_PORT=8081 python -m dynamo.sglang --model Qwen/Qwen3-0.6B --mem-fraction-static 0.20 --max-running-requests 64 &
363+
DYN_SYSTEM_PORT=8081 python -m dynamo.sglang --model Qwen/Qwen3-0.6B --mem-fraction-static 0.20 --max-running-requests 64 &
364364

365365
# TensorRT-LLM
366-
DYN_SYSTEM_ENABLED=true DYN_SYSTEM_PORT=8081 python -m dynamo.trtllm --model Qwen/Qwen3-0.6B --free-gpu-memory-fraction 0.20 --max-num-tokens 8192 --max-batch-size 64 &
366+
DYN_SYSTEM_PORT=8081 python -m dynamo.trtllm --model Qwen/Qwen3-0.6B --free-gpu-memory-fraction 0.20 --max-num-tokens 8192 --max-batch-size 64 &
367367
```
368368

369369
**Framework-Specific GPU Memory Arguments:**

deploy/cloud/operator/docs/footer.md

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -135,9 +135,8 @@ The operator automatically injects environment variables based on component type
135135

136136
### Worker Components
137137

138-
- **`DYN_SYSTEM_ENABLED`**: `true`
138+
- **`DYN_SYSTEM_PORT`**: `9090` (automatically enables the system metrics server)
139139
- **`DYN_SYSTEM_USE_ENDPOINT_HEALTH_STATUS`**: `["generate"]`
140-
- **`DYN_SYSTEM_PORT`**: `9090`
141140

142141
### Planner Components
143142

@@ -232,4 +231,4 @@ For users who want to understand the implementation details or contribute to the
232231
- All these defaults can be overridden by explicitly specifying values in your DynamoComponentDeployment or DynamoGraphDeployment resources
233232
- User-specified probes (via `livenessProbe`, `readinessProbe`, or `startupProbe` fields) take precedence over operator defaults
234233
- For multinode deployments, some defaults are modified or removed as described above to accommodate distributed execution patterns
235-
- The `extraPodSpec.mainContainer` field can be used to override probe configurations set by the operator
234+
- The `extraPodSpec.mainContainer` field can be used to override probe configurations set by the operator

deploy/cloud/operator/internal/controller/dynamocomponentdeployment_controller_test.go

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -827,7 +827,6 @@ func TestDynamoComponentDeploymentReconciler_generateLeaderWorkerSet(t *testing.
827827
{Name: "DYN_NAMESPACE", Value: "default"},
828828
{Name: "DYN_PARENT_DGD_K8S_NAME", Value: "test-lws-deploy"},
829829
{Name: "DYN_PARENT_DGD_K8S_NAMESPACE", Value: "default"},
830-
{Name: "DYN_SYSTEM_ENABLED", Value: "true"},
831830
{Name: "DYN_SYSTEM_PORT", Value: "9090"},
832831
{Name: "DYN_SYSTEM_USE_ENDPOINT_HEALTH_STATUS", Value: "[\"generate\"]"},
833832
{Name: "TEST_ENV_FROM_DYNAMO_COMPONENT_DEPLOYMENT_SPEC", Value: "test_value_from_dynamo_component_deployment_spec"},
@@ -941,7 +940,6 @@ func TestDynamoComponentDeploymentReconciler_generateLeaderWorkerSet(t *testing.
941940
{Name: "DYN_NAMESPACE", Value: "default"},
942941
{Name: "DYN_PARENT_DGD_K8S_NAME", Value: "test-lws-deploy"},
943942
{Name: "DYN_PARENT_DGD_K8S_NAMESPACE", Value: "default"},
944-
{Name: "DYN_SYSTEM_ENABLED", Value: "true"},
945943
{Name: "DYN_SYSTEM_PORT", Value: "9090"},
946944
{Name: "DYN_SYSTEM_USE_ENDPOINT_HEALTH_STATUS", Value: "[\"generate\"]"},
947945
{Name: "TEST_ENV_FROM_DYNAMO_COMPONENT_DEPLOYMENT_SPEC", Value: "test_value_from_dynamo_component_deployment_spec"},

deploy/cloud/operator/internal/dynamo/component_worker.go

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -74,10 +74,6 @@ func (w *WorkerDefaults) GetBaseContainer(context ComponentContext) (corev1.Cont
7474
}
7575

7676
container.Env = append(container.Env, []corev1.EnvVar{
77-
{
78-
Name: "DYN_SYSTEM_ENABLED",
79-
Value: "true",
80-
},
8177
{
8278
Name: "DYN_SYSTEM_USE_ENDPOINT_HEALTH_STATUS",
8379
Value: "[\"generate\"]",

deploy/cloud/operator/internal/dynamo/graph_test.go

Lines changed: 0 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -1818,10 +1818,6 @@ func TestGenerateGrovePodCliqueSet(t *testing.T) {
18181818
Name: "DYNAMO_POD_GANG_SET_REPLICAS",
18191819
Value: "1",
18201820
},
1821-
{
1822-
Name: "DYN_SYSTEM_ENABLED",
1823-
Value: "true",
1824-
},
18251821
{
18261822
Name: "DYN_SYSTEM_PORT",
18271823
Value: "9090",
@@ -1971,10 +1967,6 @@ func TestGenerateGrovePodCliqueSet(t *testing.T) {
19711967
Name: "DYNAMO_POD_GANG_SET_REPLICAS",
19721968
Value: "1",
19731969
},
1974-
{
1975-
Name: "DYN_SYSTEM_ENABLED",
1976-
Value: "true",
1977-
},
19781970
{
19791971
Name: "DYN_SYSTEM_PORT",
19801972
Value: "9090",
@@ -2623,10 +2615,6 @@ func TestGenerateGrovePodCliqueSet(t *testing.T) {
26232615
Name: "DYNAMO_POD_GANG_SET_REPLICAS",
26242616
Value: "1",
26252617
},
2626-
{
2627-
Name: "DYN_SYSTEM_ENABLED",
2628-
Value: "true",
2629-
},
26302618
{
26312619
Name: "DYN_SYSTEM_PORT",
26322620
Value: "9090",
@@ -2763,10 +2751,6 @@ func TestGenerateGrovePodCliqueSet(t *testing.T) {
27632751
Name: "DYNAMO_POD_GANG_SET_REPLICAS",
27642752
Value: "1",
27652753
},
2766-
{
2767-
Name: "DYN_SYSTEM_ENABLED",
2768-
Value: "true",
2769-
},
27702754
{
27712755
Name: "DYN_SYSTEM_PORT",
27722756
Value: "9090",
@@ -4595,7 +4579,6 @@ func TestGenerateBasePodSpec_Worker(t *testing.T) {
45954579
{Name: "DYN_NAMESPACE", Value: ""},
45964580
{Name: "DYN_PARENT_DGD_K8S_NAME", Value: "test-deployment"},
45974581
{Name: "DYN_PARENT_DGD_K8S_NAMESPACE", Value: "default"},
4598-
{Name: "DYN_SYSTEM_ENABLED", Value: "true"},
45994582
{Name: "DYN_SYSTEM_PORT", Value: "9090"},
46004583
{Name: "DYN_SYSTEM_USE_ENDPOINT_HEALTH_STATUS", Value: "[\"generate\"]"},
46014584
},

deploy/helm/chart/templates/deployment.yaml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -113,8 +113,6 @@ spec:
113113
- name: DYN_HTTP_PORT
114114
value: "{{ $.Values.dynamoPort | default 8000 }}"
115115
{{- else if $serviceSpec.componentType | eq "worker" }}
116-
- name: DYN_SYSTEM_ENABLED
117-
value: "true"
118116
- name: DYN_SYSTEM_PORT
119117
value: "{{ $.Values.dynamoSystemPort | default 9090 }}"
120118
- name: DYN_SYSTEM_USE_ENDPOINT_HEALTH_STATUS

deploy/helm/chart/templates/grove-podgangset.yaml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -105,8 +105,6 @@ spec:
105105
- name: DYN_HTTP_PORT
106106
value: "{{ $.Values.dynamoPort | default 8000 }}"
107107
{{- else if $serviceSpec.componentType | eq "worker" }}
108-
- name: DYN_SYSTEM_ENABLED
109-
value: "true"
110108
- name: DYN_SYSTEM_PORT
111109
value: "{{ $.Values.dynamoSystemPort | default 9090 }}"
112110
- name: DYN_SYSTEM_USE_ENDPOINT_HEALTH_STATUS

deploy/metrics/prometheus.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ scrape_configs:
4141
static_configs:
4242
- targets: ['host.docker.internal:8000'] # on the "monitoring" network
4343

44-
# Launch via: DYN_SYSTEM_ENABLED=true DYN_SYSTEM_PORT=8081 dynamo.<backend> ...
44+
# Launch via: DYN_SYSTEM_PORT=8081 dynamo.<backend> ...
4545
# If you want to update the scrape_interval, you may want to also update component.rs's MAX_DELAY
4646
- job_name: 'dynamo-backend'
4747
scrape_interval: 6s

docs/backends/sglang/prometheus.md

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -43,8 +43,7 @@ To see the actual metrics available in your SGLang version:
4343
### 1. Launch SGLang with Metrics Enabled
4444

4545
```bash
46-
# Set environment variables
47-
export DYN_SYSTEM_ENABLED=true
46+
# Set system metrics port (automatically enables metrics server)
4847
export DYN_SYSTEM_PORT=8081
4948

5049
# Start SGLang worker with metrics enabled

0 commit comments

Comments
 (0)