jsonstruct

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: Feb 21, 2022 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Overview

Package jsonstruct describe how data is serialized to json in communication between gpuserver and gpuserver-ds .

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ContainerResourcesDetail

type ContainerResourcesDetail struct {
	Name       string     `json:"container_name,omitempty"`
	DeviceInfo []*GpuInfo `json:"device_info,omitempty"`
}

type GpuInfo

type GpuInfo struct {
	DeviceId string `json:"device_id,omitempty"`
	Brand    string `json:"device_brand,omitempty"`
	Model    string `json:"device_model,omitempty"`
	BusId    string `json:"device_busid,omitempty"`
	NodeName string `json:"device_node,omitempty"`
}

type NodeGpuInfo

type NodeGpuInfo struct {
	NodeName string                 `json:"device_node,omitempty"`
	GpuInfos map[string]*GpuInfo    `json:"device_infos,omitempty"`
	Models   map[string]sets.String `json:"device_models,omitempty"`
	// Used in gpuserver to record the time message received by the gpuserver
	ReportTime time.Time `json:"report_time,omitempty"`
}

type PodResourceUpdate

type PodResourceUpdate struct {
	PodResourcesSYNC []*PodResourcesDetail //we don't have to tell the add and update
	PodResourcesDEL  []*podresourcesapi.PodResources
	NodeName         string
}

type PodResourcesDetail

type PodResourcesDetail struct {
	*podresourcesapi.PodResources
	ContainerDevices *[]*ContainerResourcesDetail `json:"containers_device,omitempty"`
}

Jump to

Keyboard shortcuts

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