Skip to content

Port improvements v2 - #185

Draft
danpawlik wants to merge 2 commits into
infrawatch:stable-1.5from
danpawlik:port-improvements-v2
Draft

Port improvements v2#185
danpawlik wants to merge 2 commits into
infrawatch:stable-1.5from
danpawlik:port-improvements-v2

Conversation

@danpawlik

Copy link
Copy Markdown
Member

f766243 Fix resource exhaustion and nil-deref in alertmanager plugin (#183)
c273f19 Exclude dummy transport plugins from production container image (#184)

danpawlik and others added 2 commits August 14, 2026 14:10
Dockerfile hard-coded PRODUCTION_BUILD=false, causing dummy plugins
(dummy-alertmanager, dummy-events, dummy-metrics, dummy-logs) to ship
in release images.

Set PRODUCTION_BUILD=true in Dockerfile so OMIT_TRANSPORTS applies.
Also add '//go:build !production' tag to all dummy plugins as defense-in-depth.
Pass -tags production in build.sh when PRODUCTION_BUILD=true.

Related-To: OSPRH-33326

Assisted-By: Claude Opus 4.6 <noreply@anthropic.com>
Signed-off-by: Daniel Pawlik <dpawlik@redhat.com>
(cherry picked from commit 8acf3c9)
…tch#183)

Replace unbounded per-event goroutine spawning with a fixed worker pool
to prevent memory/fd exhaustion when the Alertmanager endpoint is slow
or unreachable. Share a single http.Client with a 10s timeout instead of
creating a new zero-timeout client per request. Add early returns on
request creation errors to prevent nil-pointer dereference. Close the
response body on all paths to prevent TCP connection leaks.

Assisted-By: Claude-Code claude-opus-4-6
(cherry picked from commit 4671bbf)
@danpawlik
danpawlik requested review from vkmc and vyzigold August 14, 2026 12:14
@danpawlik
danpawlik marked this pull request as draft August 14, 2026 12:14
@danpawlik

Copy link
Copy Markdown
Member Author

Waiting #184 to be merged

@vyzigold vyzigold 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.

lgtm assuming 184 merges first

@centosinfra-prod-github-app

Copy link
Copy Markdown

Build failed (check pipeline). Post recheck (without leading slash)
to rerun all jobs. Make sure the failure cause has been resolved before
you rerun jobs.

https://gateway-cloud-softwarefactory.apps.ocp.cloud.ci.centos.org/zuul/t/rdoproject.org/buildset/54285c12876c4ae498bd20bf5bc50348

✔️ stf-crc-ocp_418-local_build SUCCESS in 57m 01s
✔️ stf-crc-ocp_420-local_build SUCCESS in 54m 27s
stf-crc-ocp_418-local_build-index_deploy NODE_FAILURE Node(set) request 100-0000170417 failed in 0s
✔️ stf-crc-ocp_420-local_build-index_deploy SUCCESS in 52m 33s
✔️ stf-crc-ocp_418-nightly_bundles-index_deploy SUCCESS in 48m 05s
✔️ stf-crc-ocp_420-nightly_bundles-index_deploy SUCCESS in 44m 58s
stf-crc-ocp_418-catalog_deploy NODE_FAILURE Node(set) request 100-0000170421 failed in 0s
✔️ stf-crc-ocp_420-catalog_deploy SUCCESS in 42m 44s

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

Labels

None yet

Development

Successfully merging this pull request may close these issues.

2 participants