MCPcopy Create free account
hub / github.com/baidu/EasyFaaS / SetResource

Method SetResource

pkg/controller/rtctrl/runtimeinfo.go:56–61  ·  view source on GitHub ↗
(mem uint64, cpu int64)

Source from the content-addressed store, hash-verified

54}
55
56func (info *RuntimeInfo) SetResource(mem uint64, cpu int64) {
57 logs.V(3).Infof("update runtime %s memory size %d to %d; cpu size %d to %d", info.RuntimeID,
58 info.Resource.Memory, mem, info.Resource.MilliCPUs, cpu)
59 info.Resource.Memory = int64(mem)
60 info.Resource.MilliCPUs = cpu
61}
62
63func (info *RuntimeInfo) SetMemorySize(mem uint64) {
64 logs.V(3).Infof("update runtime %s memory size %d to %d", info.RuntimeID, info.MemorySize, mem)

Callers 2

opOccupySetMethod · 0.95
opRollbackSetMethod · 0.95

Calls 2

VFunction · 0.92
InfofMethod · 0.80

Tested by

no test coverage detected