feat(watch/discord): surface PVC, Pod, Container, Scope in embed#108
Open
pszymkowiak wants to merge 12 commits into
Open
feat(watch/discord): surface PVC, Pod, Container, Scope in embed#108pszymkowiak wants to merge 12 commits into
pszymkowiak wants to merge 12 commits into
Conversation
release: develop → main (k8s log streaming feature)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
release: develop → main (Docker build matrix native)
release: develop → main (prometheus_scrape provider)
release: develop -> main (richer Discord embed)
release: develop -> main (Pod unknown fix)
release: rich Discord embed
chore: sync develop into main (k8s monitoring stack — full Rust observability)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
chore: sync develop into main (raw resources persist)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Rust probes (disk_usage, pod_resource, tls_certs…) emit flat objects with sibling identity fields (pvc_name, pod, kind, fs_kind) that the previous embed silently dropped — operators then saw an alert with just `Node: foo` and no idea which volume or pod was the offender. Extract the common identity fields and render them as dedicated inline fields, deduplicating against `Resource` to avoid printing the same value twice. Adds a `Scope` field that combines `kind` and `fs_kind` for disk_usage rows so `node/root` vs `pvc` is unambiguous. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Why
Rust probes (
disk_usage,pod_resource,tls_certs, …) emit flat objects with sibling identity fields (pvc_name,pod,kind,fs_kind) that the current Discord embed silently dropped. Operators receiving an alert saw something like:…with no indication of which volume or pod was full. The node had two filesystems and several PVCs — operators had to open the dashboard to find that the offender was
kxn-metrics/data-kxn-pg-postgresql-0.What
Extract the common identity fields when they exist on the violation object and render them as dedicated inline fields:
PVC— frompvc_namePod— frompodorpod_nameContainer— fromcontainerorcontainer_nameScope— fromkind(+fs_kindif present), e.g.node/root,node/image,pvcEach is deduped against
Resourceto avoid printing the same value twice when only one identity field is set.After
Backwards compatible — when none of those fields exist (CIS rules on Deployments etc.) the embed is unchanged.
Test
cargo check -p kxn-clipasses. Manual smoke planned by deploying the rebuilt binary into a cluster runningdisk_usageand watching a real alert (the cluster that prompted this PR is at 88.79% on a PVC).