Documentation ¶
Index ¶
- Variables
- type ResourceManager
- func (r *ResourceManager) CreateSlice(ctx context.Context, w entity.Workload) error
- func (r *ResourceManager) GetCGroup(ctx context.Context, rxp *regexp.Regexp, fullPath bool) (string, error)
- func (r *ResourceManager) GetResources(ctx context.Context, cgroup string) (entity.CpuResource, error)
- func (r *ResourceManager) GetRootSlice(sliceType SliceType) string
- func (r *ResourceManager) RemoveSlice(ctx context.Context, path string) error
- func (r *ResourceManager) Set(ctx context.Context, path string, resources entity.CpuResource) error
- func (r *ResourceManager) SliceExists(ctx context.Context, path string) bool
- type SliceType
Constants ¶
This section is empty.
Variables ¶
View Source
var (
ErrCPUMaxFileNotFound = errors.New("cpu.max file not found")
)
Functions ¶
This section is empty.
Types ¶
type ResourceManager ¶
type ResourceManager struct { }
func New ¶
func New() *ResourceManager
func (*ResourceManager) CreateSlice ¶
func (*ResourceManager) GetResources ¶
func (r *ResourceManager) GetResources(ctx context.Context, cgroup string) (entity.CpuResource, error)
func (*ResourceManager) GetRootSlice ¶
func (r *ResourceManager) GetRootSlice(sliceType SliceType) string
func (*ResourceManager) RemoveSlice ¶
func (r *ResourceManager) RemoveSlice(ctx context.Context, path string) error
func (*ResourceManager) Set ¶
func (r *ResourceManager) Set(ctx context.Context, path string, resources entity.CpuResource) error
func (*ResourceManager) SliceExists ¶
func (r *ResourceManager) SliceExists(ctx context.Context, path string) bool
Click to show internal directories.
Click to hide internal directories.