yangwwei commented on a change in pull request #108: [YUNIKORN-47] Support node update action URL: https://github.com/apache/incubator-yunikorn-core/pull/108#discussion_r398171387
########## File path: pkg/cache/node_info.go ########## @@ -109,6 +112,40 @@ func (ni *NodeInfo) GetCapacity() *resources.Resource { return ni.totalResource.Clone() } +func (ni *NodeInfo) SetCapacity(newCapacity *resources.Resource) { + ni.lock.Lock() + defer ni.lock.Unlock() + if resources.Equals(ni.totalResource, newCapacity) { + log.Logger().Info("skip updating capacity, not changed") Review comment: Done ---------------------------------------------------------------- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: us...@infra.apache.org With regards, Apache Git Services --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscr...@yunikorn.apache.org For additional commands, e-mail: dev-h...@yunikorn.apache.org