Skip to content

fix(e2e): retry localdns restart in cold-start validator#8649

Open
jingwenw15 wants to merge 1 commit into
mainfrom
jingwenwu/localdns-coldstart-restart-retry-pr
Open

fix(e2e): retry localdns restart in cold-start validator#8649
jingwenw15 wants to merge 1 commit into
mainfrom
jingwenwu/localdns-coldstart-restart-retry-pr

Conversation

@jingwenw15
Copy link
Copy Markdown
Member

What this PR does / why we need it:

Which issue(s) this PR fixes:

Fixes #

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Note

Copilot was unable to run its full agentic suite in this review.

Adds a bounded-retry wrapper around systemctl restart localdns in the localdns cold-start validator to reduce test flakiness from transient restart failures during async systemd/network cleanup.

Changes:

  • Introduce restart_localdns_with_retry helper with logging and bounded retries.
  • Replace direct systemctl restart localdns calls with the retry helper across the cold-start validation flow.

Comment thread e2e/validators.go
local retry_delay=5
local attempt rc=0

for attempt in $(seq 1 "$max_attempts"); do
Comment thread e2e/validators.go
Comment on lines +1996 to +1997
rc=$?
echo "WARNING: localdns restart failed on attempt ${attempt}/${max_attempts} (${reason})"
Comment thread e2e/validators.go
echo "$1" | grep -qE '^[0-9]+\.[0-9]+\.[0-9]+\.[0-9]+$'
}

# Helper: restart localdns with bounded retries.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants