Documentation ¶
Index ¶
- func Create(wl *wltypes.RDTWorkLoad) error
- func Delete(wl *wltypes.RDTWorkLoad) error
- func DeleteByID(request *restful.Request, response *restful.Response)
- func Enforce(w *wltypes.RDTWorkLoad) error
- func Get(request *restful.Request, response *restful.Response)
- func GetAll() ([]wltypes.RDTWorkLoad, error)
- func GetByID(request *restful.Request, response *restful.Response)
- func GetByUUID(uuid string) (result wltypes.RDTWorkLoad, err error)
- func GetWorkloadByID(id string) (result wltypes.RDTWorkLoad, err error)
- func Init() error
- func NewWorkload(request *restful.Request, response *restful.Response)
- func Patch(request *restful.Request, response *restful.Response)
- func Register(prefix string, container *restful.Container)
- func Release(w *wltypes.RDTWorkLoad) error
- func Update(w, patched *wltypes.RDTWorkLoad) error
- func Validate(w *wltypes.RDTWorkLoad) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Create ¶
func Create(wl *wltypes.RDTWorkLoad) error
Create function creates workload in data base
func Delete ¶
func Delete(wl *wltypes.RDTWorkLoad) error
Delete function deletes workload from data base
func DeleteByID ¶
func DeleteByID(request *restful.Request, response *restful.Response)
DeleteByID handles DELETE /v1/workloads/{id}
func Enforce ¶
func Enforce(w *wltypes.RDTWorkLoad) error
Enforce a user request workload based on defined policy
func Get ¶
func Get(request *restful.Request, response *restful.Response)
Get handles GET /v1/workloads
func GetByID ¶
func GetByID(request *restful.Request, response *restful.Response)
GetByID handle GET /v1/workloads/{id}
func GetByUUID ¶
func GetByUUID(uuid string) (result wltypes.RDTWorkLoad, err error)
GetByUUID function gets workload from database by UUID (OpenStack instance identifier)
func GetWorkloadByID ¶
func GetWorkloadByID(id string) (result wltypes.RDTWorkLoad, err error)
GetWorkloadByID function gets workload from data base by ID
func Init ¶
func Init() error
Init responsible for database creation this function should be exported to give possibility to use DB for example by Openstack without need of registering workload module
func NewWorkload ¶
func NewWorkload(request *restful.Request, response *restful.Response)
NewWorkload handle POST /v1/workloads sample POST request data body : '{ "core_ids" : ["1","2"], "policy": "gold" }' body : '{ "task_ids" : ["123"], "policy" : "silver" }' body : '{ "core_ids" : ["123"], "rdt" : { "cache" : { "max" : 4, "min": 2 } } }
func Patch ¶
func Patch(request *restful.Request, response *restful.Response)
Patch handles PATCH /v1/workloads/{id}
func Register ¶
func Register(prefix string, container *restful.Container)
Register add handlers for /v1/workloads endpoint
func Validate ¶
func Validate(w *wltypes.RDTWorkLoad) error
Validate the request workload object is validated.
Types ¶
This section is empty.