Skip to content

feat(checkpoint): hold the dra-driver-nvidia-gpu kubelet plugin state - #3

Closed
fishmans-agent wants to merge 3 commits into
Project-HAMi:masterfrom
fishing-agents:nvidia-upstream
Closed

fishmans-agent wants to merge 3 commits into
Project-HAMi:masterfrom
fishing-agents:nvidia-upstream

Conversation

@fishmans-agent

Copy link
Copy Markdown
Contributor

What type of PR is this?

/kind feature

What this PR does / why we need it:

Adds the checkpoint state of the two kubelet plugins of kubernetes-sigs/dra-driver-nvidia-gpu that v1 couldn't hold, so that driver can move from the kubelet checkpointmanager to dra-lib (kubernetes-sigs/dra-driver-nvidia-gpu#1666).

  • GPU plugin: Device.ShareID and Device.Metadata, per device group timeSliceApplied and mpsApplied, pciBusID of NVIDIA devices and parentPCIBusID of MIG partitions.
  • ComputeDomain plugin: IMEX channel and daemon devices with their id, computeDomain and type per group, and PrepareAborted claims with abortedAt.
  • the legacy reader reads every checkpointmanager layout both plugins wrote: V1+V2, V1 only, and the ComputeDomain 25.3.0-rc.2 layout. Fixtures are written by the plugins' own checkpointmanager code.

All new fields are optional, so existing v1 files stay valid. Three commits: GPU state, ComputeDomain state, changelog.

Which issue(s) this PR fixes:

Needed for kubernetes-sigs/dra-driver-nvidia-gpu#1666.

Special notes for your reviewer:

Build, vet, unit tests and the generated-code check pass locally. Release as v0.2.0 after merge.

Does this PR introduce a user-facing change?:

api/checkpoint/v1 holds the GPU and ComputeDomain kubelet plugin state of dra-driver-nvidia-gpu, and the legacy reader migrates its checkpointmanager files.

AI Disclosure: Prepared with an AI assistant, reviewed by me.

The GPU kubelet plugin of dra-driver-nvidia-gpu persists more than v1
could hold: per group timeSliceApplied and mpsApplied (unset means the
checkpoint predates them), the PCI bus ID of vfio devices and of the
parent of a MIG device, and the ShareID and Metadata of the kubelet
device. Add them to the v1 types and read them from the legacy format.

Tests read checkpoints written by the plugin's checkpointmanager code,
in the V1+V2 and V1-only layouts.

Signed-off-by: Reza Jelveh <fishmangit@dynamia.ai>
The ComputeDomain kubelet plugin of dra-driver-nvidia-gpu persists the
IMEX channel and daemon devices with their IDs, the ComputeDomain and
config type of each group, and PrepareAborted claims with the time they
were aborted. Add them to the v1 types.

Read all three layouts the plugin ever wrote: V1+V2, V1 only, and the
25.3.0-rc.2 one, whose v1 claims are lists of device groups with the
kubelet proto device. Tests read checkpoints written by the plugin's
checkpointmanager code.

Signed-off-by: Reza Jelveh <fishmangit@dynamia.ai>
Signed-off-by: Reza Jelveh <fishmangit@dynamia.ai>
@hami-robot

hami-robot Bot commented Dec 1, 2026

Copy link
Copy Markdown

@fishmans-agent: The label(s) kind/feature cannot be applied, because the repository doesn't have them.

Details

In response to this:

What type of PR is this?

/kind feature

What this PR does / why we need it:

Adds the checkpoint state of the two kubelet plugins of kubernetes-sigs/dra-driver-nvidia-gpu that v1 couldn't hold, so that driver can move from the kubelet checkpointmanager to dra-lib (kubernetes-sigs/dra-driver-nvidia-gpu#1666).

  • GPU plugin: Device.ShareID and Device.Metadata, per device group timeSliceApplied and mpsApplied, pciBusID of NVIDIA devices and parentPCIBusID of MIG partitions.
  • ComputeDomain plugin: IMEX channel and daemon devices with their id, computeDomain and type per group, and PrepareAborted claims with abortedAt.
  • the legacy reader reads every checkpointmanager layout both plugins wrote: V1+V2, V1 only, and the ComputeDomain 25.3.0-rc.2 layout. Fixtures are written by the plugins' own checkpointmanager code.

All new fields are optional, so existing v1 files stay valid. Three commits: GPU state, ComputeDomain state, changelog.

Which issue(s) this PR fixes:

Needed for kubernetes-sigs/dra-driver-nvidia-gpu#1666.

Special notes for your reviewer:

Build, vet, unit tests and the generated-code check pass locally. Release as v0.2.0 after merge.

Does this PR introduce a user-facing change?:

api/checkpoint/v1 holds the GPU and ComputeDomain kubelet plugin state of dra-driver-nvidia-gpu, and the legacy reader migrates its checkpointmanager files.

AI Disclosure: Prepared with an AI assistant, reviewed by me.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository.

@hami-robot
hami-robot Bot requested a review from fishman December 1, 2026 18:52
@hami-robot

hami-robot Bot commented Dec 1, 2026

Copy link
Copy Markdown

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: fishmans-agent
Once this PR has been reviewed and has the lgtm label, please assign fishman for approval. For more information see the Kubernetes Code Review Process.

The full list of commands accepted by this bot can be found 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

@coderabbitai

coderabbitai Bot commented Dec 1, 2026

Copy link
Copy Markdown

Important

  • Trigger review

This repository does not receive automatic reviews because it has fewer than 10 stars.

Run configuration

  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: Organization UI
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: ad8b1c7b-db4f-4c57-a043-baea1f786e30
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

Share

@fishmans-agent

Copy link
Copy Markdown
Contributor Author

Superseded by #8. Its three commits are included unchanged, and the checkpoint v2 work is added on top. Closing in favour of that PR.

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