From acbe8a8730cd77908a51be128443c9f03d19904c Mon Sep 17 00:00:00 2001 From: "James E. Blair" Date: Thu, 27 Jun 2024 06:56:59 -0700 Subject: [PATCH] Add lock expiration delays to quick-start Recent runs of the quick-start job have started to fail and the apparent cause is that podman may shut down the ZK pod before the Zuul components have had a chance to release their locks. This can cause the scheduler to need to wait for lock expiration before starting the gerrit event stream, which in turn may cause it to miss important events in the job. To correct this, add a 30 second delay between stopping and starting the containers. When humans run through this sequence, they are likely to be slow enough not to observe this condition, so we only need to fix this in the test playbook (not the actual tutorial instructions). Change-Id: I806d33237058fa6f0a7c7cc22ceec47242cb4ad1 --- playbooks/tutorial/admin.yaml | 6 ++++++ playbooks/tutorial/tracing.yaml | 6 ++++++ 2 files changed, 12 insertions(+) diff --git a/playbooks/tutorial/admin.yaml b/playbooks/tutorial/admin.yaml index 7a5eec166c..1fdb22023a 100644 --- a/playbooks/tutorial/admin.yaml +++ b/playbooks/tutorial/admin.yaml @@ -55,6 +55,12 @@ until: result.status == 200 and result.json["zuul_version"] is defined changed_when: false +# In case ZK is shutdown first, allow the locks to expire. +- name: Delay for ZK lock expiration + wait_for: + timeout: 30 + delegate_to: localhost + - name: Verify Keycloak authentication is available uri: url: http://localhost:9000/api/tenant/example-tenant/info diff --git a/playbooks/tutorial/tracing.yaml b/playbooks/tutorial/tracing.yaml index f3b95d19c3..5c0bca4ad7 100644 --- a/playbooks/tutorial/tracing.yaml +++ b/playbooks/tutorial/tracing.yaml @@ -55,6 +55,12 @@ until: result.status == 200 and result.json["zuul_version"] is defined changed_when: false +# In case ZK is shutdown first, allow the locks to expire. +- name: Delay for ZK lock expiration + wait_for: + timeout: 30 + delegate_to: localhost + - name: Verify that old builds are available uri: url: "http://localhost:9000/api/tenant/example-tenant/builds"