Skip to content

[9.4] (backport #15206) Fix flaky Windows event log test.#15324

Open
mergify[bot] wants to merge 1 commit into
9.4from
mergify/bp/9.4/pr-15206
Open

[9.4] (backport #15206) Fix flaky Windows event log test.#15324
mergify[bot] wants to merge 1 commit into
9.4from
mergify/bp/9.4/pr-15206

Conversation

@mergify

@mergify mergify Bot commented Jul 3, 2026

Copy link
Copy Markdown
Contributor

What does this PR do?

Fixes TestEventLogFile for Windows. The duplicate agent.monitoring key was re-enabling metrics.

Why is it important?

Removes flakiness in the CI.

Checklist

  • I have read and understood the pull request guidelines of this project.
  • My code follows the style guidelines of this project
  • I have commented my code, particularly in hard-to-understand areas
  • [ ] I have made corresponding changes to the documentation
  • [ ] I have made corresponding change to the default configuration files
  • I have added tests that prove my fix is effective or that my feature works
  • [ ] I have added an entry in ./changelog/fragments using the changelog tool
  • I have added an integration test or an E2E test

Disruptive User Impact

None

Related issues


This is an automatic backport of pull request #15206 done by [Mergify](https://mergify.com).

@mergify mergify Bot added the backport label Jul 3, 2026
@mergify mergify Bot requested a review from a team as a code owner July 3, 2026 01:25
@mergify mergify Bot requested review from swiatekm and ycombinator and removed request for a team July 3, 2026 01:25
@github-actions github-actions Bot added Team:Elastic-Agent-Control-Plane Label for the Agent Control Plane team skip-changelog labels Jul 3, 2026
@infra-vault-gh-plugin-prod

Copy link
Copy Markdown

Pinging @elastic/elastic-agent-control-plane (Team:Elastic-Agent-Control-Plane)

@infra-vault-gh-plugin-prod

Copy link
Copy Markdown

@github-actions

This comment has been minimized.

@github-actions

github-actions Bot commented Jul 3, 2026

Copy link
Copy Markdown
Contributor

TL;DR

The prefetched Buildkite console log for linux:amd64:tier1:sudo:default only contains the job tail, so I cannot identify all 18 failed assertions from the available data. The only concrete failed-test clues in the log are uploaded diagnostics for TestLoggingFilePathChangedViaFleet and TestInstallFailureCleanup; TestLoggingFilePathChangedViaFleet already has an open flaky-test issue: #15149.

Remediation

  • Retry the failed Buildkite step if this is blocking the backport; the available evidence points to integration-test flakiness/incomplete log data rather than the changed TestEventLogFile code.
  • If the retry fails, inspect/download build/default_sudo_Linux_6.17.0-1016-gcp_x86_64.integration.xml or build/default_sudo_Linux_6.17.0-1016-gcp_x86_64.integration.out.json from the failed job artifacts to get the exact failed test cases and stack traces.
Investigation details

Root Cause

The precise root cause is not available in the prefetched log. The log starts near the end of the test run and only reports the aggregate result:

DONE 170 tests, 120 skipped, 18 failures in 1930.051s
Integration tests failed

It also shows artifact uploads for:

build/default_sudo_Linux_6.17.0-1016-gcp_x86_64.integration.out.json
build/default_sudo_Linux_6.17.0-1016-gcp_x86_64.integration.xml
build/diagnostics/TestInstallFailureCleanup-...-ProcessDump-install.json
build/diagnostics/TestLoggingFilePathChangedViaFleet-...-diagnostics.zip
build/diagnostics/TestLoggingFilePathChangedViaFleet-...-ProcessDump-cleanup.json

The PR changes only testing/integration/ess/event_logging_test.go, merging the duplicate agent.monitoring config block. The changed config at testing/integration/ess/event_logging_test.go:55-66 matches the documented remediation for closed flaky-test issue #15203. I did not find evidence in the available Linux job tail that TestEventLogFile is the failing test in this run.

Evidence

Verification

  • Read the prefetched Buildkite event and failure summary.
  • Read the saved job log at /tmp/gh-aw/buildkite-logs/elastic-agent-linuxamd64tier1sudodefault.txt.
  • Checked PR metadata, changed files, and existing PR comments; no prior detective comment with the same analysis was present.
  • Attempted to fetch the uploaded Buildkite/GCS artifacts, but they returned 403 from this environment, so the individual failure stack traces remain unavailable here.

Follow-up

If a retry reproduces the failure, use the uploaded JUnit/JSON report artifacts above as the source of truth before changing this backport.


What is this? | From workflow: PR Buildkite Detective

Give us feedback! React with 🚀 if perfect, 👍 if helpful, 👎 if not.

@mergify

mergify Bot commented Jul 6, 2026

Copy link
Copy Markdown
Contributor Author

This pull request has not been merged yet. Could you please review and merge it @blakerouse? 🙏

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant