You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@yunikorn.apache.org by GitBox <gi...@apache.org> on 2022/02/18 14:29:46 UTC

[GitHub] [incubator-yunikorn-core] manirajv06 commented on a change in pull request #350: YUNIKORN-462: Streamline core to shim update on allocation change

manirajv06 commented on a change in pull request #350:
URL: https://github.com/apache/incubator-yunikorn-core/pull/350#discussion_r810048976



##########
File path: pkg/rmproxy/rmproxy.go
##########
@@ -97,14 +97,15 @@ func (rmp *RMProxy) handleUpdateResponseError(rmID string, err error) {
 func (rmp *RMProxy) processAllocationUpdateEvent(event *rmevent.RMNewAllocationsEvent) {
 	rmp.RLock()
 	defer rmp.RUnlock()
-	if len(event.Allocations) == 0 {
-		return
-	}

Review comment:
       This has been already handled in caller side. For example notifyRMNewAllocation would be called only if it is necessary. Added extra check for the same in notifyRMNewAllocation to make it more safer. Also, sending it as success if case of no allocations gives wrong impression on the caller side. Anyways, I think caller side code is good enough.




-- 
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.

To unsubscribe, e-mail: reviews-unsubscribe@yunikorn.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org