Skip to content

Commit

Permalink
fix: get DRA plugin name from the resource handle
Browse files Browse the repository at this point in the history
DRA manager used controller plugin name as a Kubelet plugin name.
This worked only for setups with the same controller and plugin
names and one Kubelet plugin.

For the setup with multiple Kubelet plugins it breaks with the error
`Failed to prepare dynamic resources" err="failed to get DRA Plugin
client for plugin name <controller plugin name>: plugin name
<controller plugin name> not found in the list of registered DRA
plugins`

Getting Kubelet plugin name from the resource handle should fix
this issue.
  • Loading branch information
bart0sh committed May 2, 2024
1 parent cbcdd4f commit 58e008c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pkg/kubelet/cm/dra/manager.go
Original file line number Diff line number Diff line change
Expand Up @@ -225,7 +225,7 @@ func (m *ManagerImpl) PrepareResources(pod *v1.Pod) error {
for _, resourceHandle := range claimInfo.ResourceHandles {
// If no DriverName is provided in the resourceHandle, we
// use the DriverName from the status
pluginName := claimInfo.DriverName
pluginName := resourceHandle.DriverName
if pluginName == "" {
pluginName = claimInfo.DriverName
}
Expand Down

0 comments on commit 58e008c

Please sign in to comment.