njnu-seafish commented on PR #18663:
URL: 
https://github.com/apache/dolphinscheduler/pull/18663#issuecomment-5806489536

   > After the offline workflow definition is started regularly, it will 
trigger the scheduled task, which conflicts with the current logic. Please 
discuss and reach a consensus before modifying the logic of this block. I'll 
close this PR for now.
   
   
   Thanks for the review and for closing the PR.
   
   Let me clarify the design intent so we can align on the right direction.
   
   
   The change only relaxes the check in insertSchedule (create schedule). It 
does not bypass the guard on going online. The full path is:
   
   insertSchedule persists the schedule with releaseState = OFFLINE and only 
saves it to DB — no Quartz job is registered, so nothing gets scheduled.
   
   Before a schedule can actually fire, the user must go online it via 
onlineScheduler → doOnlineScheduler. That path still keeps the workflow-level 
check:
   
   > if (!ReleaseState.ONLINE.equals(workflowDefinition.getReleaseState())) {
   >     throw new ServiceException(Status.WORKFLOW_DEFINITION_NOT_RELEASE, 
workflowDefinition.getName());
   > }
   
   So an offline workflow definition can never have its schedule online and 
trigger execution.
   


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

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to