<#3109 [FlyteCTL Feature] Schedule ergonomics> Iss...
# flyte-github
c
#3109 [FlyteCTL Feature] Schedule ergonomics Issue created by wild-endeavor # Improve scheduled workflow handling ## Poor UX currently There's a few ux issues around how scheduled workflows are handled today. • When you register a new launch plan with a schedule, it doesn't become active without manual intervention. And there's no easy way to set this (like a
--set-active
or some option). • When a user deletes a launch plan from code, and the user doesn't manually deactivate the launch plan, it will continue to run. There's also no way to query "old" launch plans. As background info: For a given project, domain, and launch plan name, only one version can be "active" at any given time. Activating one version will deactivate the others. ## New flytectl commands Both of these can be addressed through flytectl. Proposal is to add some new commands (not attached to the names of the commands here, just as examples)
activate-latest [--remove-old]
For all workflows, find the latest version. For each workflow at said version, activate all launchplans. This will automatically deactivate all other versions. If the
remove-old
switch is specified, then launch plans pointing to each workflow, but do not have a version matching the workflow's latest version, will also be deactivated.
activate --version <v>
Activate all launch plans for a project/domain at a given version if it exists.
deactivate-all
Deactivate all launch plans across a project domain. I think this is helpful for ensuring that nothing is ## Docs We also need to improve documentation around how handling of schedules should work in prod. ## Misc ### Are you sure this issue hasn't been raised already? • Yes ### Have you read the Code of Conduct? • Yes flyteorg/flyte