Skip to content

Commit b920bd4

Browse files
authored
Switch use-parallel-containers to be false by default (#1193)
* Switch use-parallel-containers to be false by default * update goldens
1 parent 367c838 commit b920bd4

4 files changed

Lines changed: 9 additions & 49 deletions

File tree

recipes/Workload_create_super-slicing.md

Lines changed: 5 additions & 46 deletions
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ kubectl get configmap golden-cluster-resources-configmap -o=custom-columns="Conf
3434
[XPK] Task: `Upload Container Image` is implemented by the following command not running since it is a dry run.
3535
crane mutate python:3.10 --append e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855 --platform linux/amd64 --tag gcr.io/golden-project/dry-run-runner:prefix-current --workdir /app
3636
[XPK] Deleting container image archive e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855
37-
[XPK] Temp file (608e1382aabe2b0335855e5e99876a2e67de954453ebfa4cf12eb82c966f85da) content:
37+
[XPK] Temp file (2c5ab381c0d643f8512a07d296d411413080ec652c15e8c676fd58435de5a327) content:
3838
apiVersion: jobset.x-k8s.io/v1alpha2
3939
kind: JobSet
4040
metadata:
@@ -67,13 +67,7 @@ spec:
6767
- action: FailJob
6868
onPodConditions: []
6969
onExitCodes:
70-
containerName: jax-tpu-1
71-
operator: NotIn
72-
values: [42,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,161,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,181,182,183,184,185,186,187,188,189,190,191,192,193,194,195,196,197,198,199,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255]
73-
- action: FailJob
74-
onPodConditions: []
75-
onExitCodes:
76-
containerName: jax-tpu-2
70+
containerName: jax-tpu
7771
operator: NotIn
7872
values: [42,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,161,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,181,182,183,184,185,186,187,188,189,190,191,192,193,194,195,196,197,198,199,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255]
7973
template:
@@ -101,42 +95,7 @@ spec:
10195
terminationGracePeriodSeconds: 30
10296
containers:
10397
104-
- name: jax-tpu-1
105-
image: gcr.io/golden-project/dry-run-runner:prefix-current
106-
107-
env:
108-
securityContext:
109-
privileged: true
110-
command:
111-
- bash
112-
- -c
113-
- |
114-
echo XPK Start: $(date);
115-
_sigterm() (kill -SIGTERM $! 2>/dev/null;);
116-
trap _sigterm SIGTERM;
117-
118-
(bash hello) & PID=$!;
119-
while kill -0 $PID 2>/dev/null;
120-
do sleep 5;
121-
done;
122-
wait $PID;
123-
EXIT_CODE=$?;
124-
125-
echo XPK End: $(date);
126-
echo EXIT_CODE=$EXIT_CODE;
127-
128-
129-
exit $EXIT_CODE
130-
resources:
131-
limits:
132-
google.com/tpu: 2
133-
134-
volumeMounts:
135-
- mountPath: /dev/shm
136-
name: dshm-2
137-
138-
139-
- name: jax-tpu-2
98+
- name: jax-tpu
14099
image: gcr.io/golden-project/dry-run-runner:prefix-current
141100
142101
env:
@@ -164,7 +123,7 @@ spec:
164123
exit $EXIT_CODE
165124
resources:
166125
limits:
167-
google.com/tpu: 2
126+
google.com/tpu: 4
168127
169128
volumeMounts:
170129
- mountPath: /dev/shm
@@ -184,7 +143,7 @@ spec:
184143
185144
186145
[XPK] Task: `Creating Workload` is implemented by the following command not running since it is a dry run.
187-
kubectl apply -f 608e1382aabe2b0335855e5e99876a2e67de954453ebfa4cf12eb82c966f85da
146+
kubectl apply -f 2c5ab381c0d643f8512a07d296d411413080ec652c15e8c676fd58435de5a327
188147
[XPK] Task: `GKE Dashboard List` is implemented by the following command not running since it is a dry run.
189148
gcloud monitoring dashboards list --project=golden-project --filter="displayName:'GKE - TPU Monitoring Dashboard'" --format="value(name)" --verbosity=error
190149
[XPK] Check statistics and outlier mode of GKE metrics here: https://console.cloud.google.com/monitoring/dashboards/builder/0?project=golden-project&f.rlabel.cluster_name.ClusterName=golden-cluster. To view the metric data for your workload, select golden-workload from the JobName filter on the dashboard.

src/xpk/commands/cluster_test.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -138,7 +138,7 @@ def construct_args(**kwargs: Any) -> Namespace:
138138
enable_private_endpoint=None,
139139
private_endpoint_subnetwork=None,
140140
enable_master_global_access=False,
141-
use_parallel_containers=True,
141+
use_parallel_containers=False,
142142
)
143143
args_dict.update(kwargs)
144144
return Namespace(**args_dict)

src/xpk/commands/workload_test.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -256,6 +256,7 @@ def test_workload_create_multi_container_for_tpu7x(
256256
deploy_stacktrace_sidecar=False,
257257
enable_debug_logs=False,
258258
scheduler='default-scheduler',
259+
use_parallel_containers=True,
259260
)
260261
workload_create(args)
261262

src/xpk/parser/workload.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -587,9 +587,9 @@ def add_shared_workload_create_optional_arguments(args_parsers):
587587
custom_parser.add_argument(
588588
'--use-parallel-containers',
589589
action=argparse.BooleanOptionalAction,
590-
default=True,
590+
default=False,
591591
help=(
592-
'Whether to use parallel_containers in JobSet. Enabled by default.'
592+
'Whether to use parallel_containers in JobSet. Disabled by default.'
593593
),
594594
)
595595
custom_parser.add_argument(

0 commit comments

Comments
 (0)