Skip to content

🐛 fix: collect operator pod logs across restarts and rolling updates - #2848

Merged
openshift-merge-bot[bot] merged 1 commit into
operator-framework:mainfrom
pedjak:pre-serial-logs
Aug 5, 2026
Merged

🐛 fix: collect operator pod logs across restarts and rolling updates#2848
openshift-merge-bot[bot] merged 1 commit into
operator-framework:mainfrom
pedjak:pre-serial-logs

Conversation

@pedjak

@pedjak pedjak commented Aug 4, 2026

Copy link
Copy Markdown
Contributor

Description

The experimental-e2e CI job runs parallel tests then serial tests on the same kind cluster. Serial tests (HA, TLS, proxy scenarios) patch operator-controller and catalogd Deployments, triggering rolling updates that delete the original pods. The support bundle is collected only at the end (on failure), so it only captures replacement pod logs — parallel test failure logs are lost.

Since Kubernetes does not support retaining logs from deleted pods (kubernetes#123279), the only way to preserve them is to collect logs before the pods are removed.

This PR deploys Fluent Bit (gated on ARTIFACT_PATH) to continuously tail olmv1-system container logs to a persistent directory on the node filesystem. A copyFromHost collector in the support bundle spec extracts these persisted logs into the operator-logs/ directory, preserving the complete log history across all pod generations including deleted and restarted instances.

Changes

  • testdata/fluentbit/values.yaml — Minimal Fluent Bit Helm values: tails only olmv1-system pod logs, writes to /var/log/fluentbit/output/<namespace>/<pod>.<container>
  • Makefile — New fluentbit-% target (parallel with prometheus-%), added as dependency of e2e-run-%
  • test/e2e/support-bundle.yaml — Added copyFromHost collector to extract persisted logs from nodes

Reviewer Checklist

  • API Go Documentation
  • Tests: Unit Tests (and E2E Tests, if appropriate)
  • Comprehensive Commit Messages
  • Links to related GitHub Issue(s)

Copilot AI lite review requested due to automatic review settings August 4, 2026 16:43
@openshift-ci
openshift-ci Bot requested a review from grokspawn August 4, 2026 16:43
@netlify

netlify Bot commented Aug 4, 2026

Copy link
Copy Markdown

Deploy Preview for olmv1 ready!

Name Link
🔨 Latest commit 1ab2d61
🔍 Latest deploy log https://app.netlify.com/projects/olmv1/deploys/6a7225368041db00093260ed
😎 Deploy Preview https://deploy-preview-2848--olmv1.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.
🤖 Make changes Run an agent on this branch

To edit notification comments on pull requests, go to your Netlify project configuration.

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

This PR improves e2e failure diagnostics by persisting olmv1-system workload logs on the KIND node filesystem so logs survive pod restarts/rollouts, then packaging those persisted logs into the support-bundle collected on failure.

Changes:

  • Add a Fluent Bit Helm values file to tail container logs and write them to a hostPath-backed directory.
  • Extend the e2e support-bundle spec to copy persisted Fluent Bit output from nodes into the bundle.
  • Update the Makefile to deploy Fluent Bit (gated on ARTIFACT_PATH) as part of e2e-run-%.

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 2 comments.

File Description
testdata/fluentbit/values.yaml Introduces Fluent Bit configuration/hostPath mounts to persist logs on node disks during e2e.
test/e2e/support-bundle.yaml Adds a copyFromHost collector to include persisted node logs in the failure support-bundle.
Makefile Adds fluentbit-% Helm deployment target and wires it into e2e-run-%.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment on lines +18 to +22
inputs: |
[INPUT]
Name tail
Path /var/log/containers/*_olmv1-system_*.log
multiline.parser cri
Comment thread test/e2e/support-bundle.yaml
Serial tests (HA, TLS, proxy scenarios) patch operator-controller and
catalogd Deployments, triggering rolling updates that delete the
original pods. The support bundle collected at the end only captures
replacement pod logs, so parallel test failure logs are lost.

Deploy Fluent Bit (gated on ARTIFACT_PATH) to continuously persist
olmv1-system container logs to the node filesystem. A copyFromHost
collector in the support bundle extracts these persisted logs into the
operator-logs/ directory, preserving the complete log history across
all pod generations including deleted and restarted instances.

Co-Authored-By: Claude <noreply@anthropic.com>
Copilot AI review requested due to automatic review settings August 4, 2026 17:45

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 3 out of 3 changed files in this pull request and generated no new comments.

Comment thread Makefile
@pedjak
pedjak requested a review from tmshort August 4, 2026 22:16
@tmshort

tmshort commented Aug 5, 2026

Copy link
Copy Markdown
Contributor

/approve

@openshift-ci openshift-ci Bot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Aug 5, 2026

@rashmigottipati rashmigottipati left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

solid improvement. thanks @pedjak

/lgtm

@openshift-ci openshift-ci Bot added the lgtm Indicates that a PR is ready to be merged. label Aug 5, 2026
@openshift-ci

openshift-ci Bot commented Aug 5, 2026

Copy link
Copy Markdown

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: rashmigottipati, tmshort

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@openshift-merge-bot
openshift-merge-bot Bot merged commit fee8cc2 into operator-framework:main Aug 5, 2026
24 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

approved Indicates a PR has been approved by an approver from all required OWNERS files. lgtm Indicates that a PR is ready to be merged.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants