Hi All, Been searching around for a solution to this but wondering if anyone has similar use cases and any advice on what they are doing to solve this.
We use prefect a lot for managing DBT operations, essentially an ECS task that executes a DBT job on snowflake. for the most part it works well - except for a few instances
We have cases where a job takes longer to execute, for one reason or another, than the time allotted before the next scheduled run.. in this case, we can have many instances of the same run begin to pile up, and that leads to a lot of manual management we would like to avoid.. so basically cancel a scheduled run if there is an instance of it that still is not in the completed state.
In a similar vein of flow management, we may have 1-off dbt runs, and if one of these is executed manually, we want to be able to pause these sets of cron jobs until this 1-off run is finished.
This would really tidy up our infra so excited to hear about solutions to this!
The only other minor issue we are dealing with is a cancelled DBT run does not actually cancel the underlying snowflake queries, so wondering what strategies people have for more graceful exits in the event of cancels. Right now we have to rely on manually cancelling those queries in snowflake themselves
Thanks in advance!