resource

package
v0.0.0-...-964918b Latest Latest
Warning

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

Go to latest
Published: Nov 7, 2016 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ResourceManager

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

func NewManager

func NewManager() *ResourceManager

NewManager creates a new resource manager with default resource.

func (*ResourceManager) ApplyResource

func (resm *ResourceManager) ApplyResource(event *api.Event) error

ApplyResource uses to apply resource for container.

func (*ResourceManager) GetCpucontainer

func (resm *ResourceManager) GetCpucontainer() float64

GetCpucontainer func that get the default cpu for container.

func (*ResourceManager) GetCpuuser

func (resm *ResourceManager) GetCpuuser() float64

GetCpuuser func that get the default cpu for user.

func (*ResourceManager) GetMemorycontainer

func (resm *ResourceManager) GetMemorycontainer() float64

GetMemorycontainer func that get the default memory for container.

func (*ResourceManager) GetMemoryuser

func (resm *ResourceManager) GetMemoryuser() float64

GetMemoryuser func that get the default memory for user.

func (*ResourceManager) ReleaseResource

func (resm *ResourceManager) ReleaseResource(event *api.Event) error

ReleaseResource uses to add resource into db.

Jump to

Keyboard shortcuts

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