devicepluginserver

package
v1.2.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 19, 2022 License: GPL-3.0 Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type DevicePluginServer

type DevicePluginServer struct {
	// contains filtered or unexported fields
}

func NewDevicePluginServer

func NewDevicePluginServer(devicePaths []string, deviceGroupName string, mapSymPaths bool) *DevicePluginServer

NewDevicePluginServer returns an initialized DevicePluginServer

func (*DevicePluginServer) Allocate

Allocate is called during container creation so that the Device Plugin can run device specific operations and instruct Kubelet of the steps to make the Device available in the container

func (*DevicePluginServer) GetDevicePluginOptions

GetDevicePluginOptions returns options to be communicated with Device Manager

func (*DevicePluginServer) GetPreferredAllocation

GetPreferredAllocation returns a preferred set of devices to allocate from a list of available ones. The resulting preferred allocation is not guaranteed to be the allocation ultimately performed by the devicemanager. It is only designed to help the devicemanager make a more informed allocation decision when possible.

func (*DevicePluginServer) ListAndWatch

ListAndWatch returns a stream of List of Devices Whenever a Device state change or a Device disapears, ListAndWatch returns the new list

func (*DevicePluginServer) PreStartContainer

PreStartContainer is called, if indicated by Device Plugin during registeration phase, before each container start. Device plugin can run device specific operations such as reseting the device before making devices available to the container

func (*DevicePluginServer) Run

func (m *DevicePluginServer) Run(ctx context.Context, wg *sync.WaitGroup, errCh chan<- error)

Run makes the plugin go, plugin can be terminated using the provided context

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL