Skip to content

feat: enforce snapshot CPU compatibility - #69

Merged
CMGS merged 4 commits into
mainfrom
feat/snapshot-cpu-compatibility
Aug 11, 2026
Merged

feat: enforce snapshot CPU compatibility#69
CMGS merged 4 commits into
mainfrom
feat/snapshot-cpu-compatibility

Conversation

@tonicmuroq

@tonicmuroq tonicmuroq commented Aug 11, 2026

Copy link
Copy Markdown
Contributor

Summary

  • publish VK_SNAPSHOT_CPU_CLASS as the node's snapshot CPU compatibility label
  • reject classified pods on incompatible or unclassified hosts during create, wake/update, and startup reconciliation
  • preserve legacy behavior for pods without a compatibility class

Uses the merged snapshot compatibility contract from cocoon-common#16.

Test plan

  • go mod tidy
  • make test

Publish each node's configured snapshot CPU class and reject classified pods on incompatible hosts across create, wake, and startup reconciliation. Pin the merged cocoon-common contract.
@tonicmuroq
tonicmuroq force-pushed the feat/snapshot-cpu-compatibility branch from a1e35c7 to 96d8a15 Compare August 11, 2026 07:51
CMGS added 3 commits August 11, 2026 19:34
- move assertPodSnapshotCompatibility to compatibility.go beside its test
- drop the stale-label delete: nodeutil builds the node template fresh
  each start, so the branch was unreachable
- inline VK_SNAPSHOT_CPU_CLASS validation; IsValidLabelValue accepts
  empty, making the wrapper and its empty-check redundant
- re-assert node labels inside the endpoint patch loop: v-k only patches
  the status subresource after node creation, so a re-stamped or cleared
  snapshot CPU class never reached an existing node object
- skip compatibility enforcement for Succeeded/Failed pods so a leftover
  terminal pod cannot block node registration
Mirrors the unconditional UpdateStatus below; the maps diff guard only
saved one idempotent write per process start at the cost of an import,
a clone per attempt, and a second nested retry path.
@CMGS
CMGS merged commit a7893ac into main Aug 11, 2026
2 checks passed
@CMGS
CMGS deleted the feat/snapshot-cpu-compatibility branch August 11, 2026 12:07
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