kingamarton commented on a change in pull request #275:
URL: 
https://github.com/apache/incubator-yunikorn-core/pull/275#discussion_r644614671



##########
File path: pkg/scheduler/objects/application.go
##########
@@ -97,6 +104,13 @@ func NewApplication(siApp *si.AddApplicationRequest, ugi 
security.UserGroup, eve
        if time.Duration(0) == placeholderTimeout {
                placeholderTimeout = defaultPlaceholderTimeout
        }
+       gangSchedStyle := siApp.GetGangSchedulingStyle()
+       if gangSchedStyle != Soft && gangSchedStyle != Hard {
+               log.Logger().Info("Unknown gang scheduling style, using hard 
style as default",
+                       zap.String("gang scheduling style", gangSchedStyle))
+               gangSchedStyle = Hard
+       }

Review comment:
       Since we are already using Hard by default in our 0.10 release, if we 
change it to Soft, can break some workflows, not? I used Hard as default, to 
keep the same behaviour as before.

##########
File path: pkg/scheduler/objects/application_state.go
##########
@@ -106,6 +108,10 @@ func NewAppState() *fsm.FSM {
                                Name: FailApplication.String(),
                                Src:  []string{Failing.String()},
                                Dst:  Failed.String(),
+                       }, {
+                               Name: ResumeApplication.String(),
+                               Src:  []string{New.String(), Accepted.String()},
+                               Dst:  Resuming.String(),

Review comment:
       In all other cases (if the app is Running, Starting or Completing) we 
don't fail the application. In this case we just delete the remaining 
placeholders and let the application finish. You can see this part here: 
https://github.com/apache/incubator-yunikorn-core/blob/master/pkg/scheduler/objects/application.go#L296-L312

##########
File path: pkg/scheduler/objects/application_state.go
##########
@@ -106,6 +108,10 @@ func NewAppState() *fsm.FSM {
                                Name: FailApplication.String(),
                                Src:  []string{Failing.String()},
                                Dst:  Failed.String(),
+                       }, {
+                               Name: ResumeApplication.String(),
+                               Src:  []string{New.String(), Accepted.String()},
+                               Dst:  Resuming.String(),

Review comment:
       We don't have anymore Waiting state. It was changed to Completing, so I 
think the Soft style will have impact only for the other cases when we would 
fail the application.




-- 
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:
[email protected]


Reply via email to