František
08/13/2024, 2:31 PMFrantišek
08/14/2024, 11:23 AMfrom typing import List
from prefect import flow
from prefect.concurrency.sync import concurrency
from utils import dbt_core_operation_wrapper
@flow
def build_waze() -> List[str]:
with concurrency(names='build_waze', occupy=1, timeout_seconds=3600):
dbt_core_operation_wrapper(['dbt build --select waze'])
This created a global concurrency limit build_waze
, as seen in the screenshot. I manually activated the limit. Now after the first next run Active Slots went to 1, but:
• it stays 1 even after no flow is running
• it enabled me to do a quick run of the same flow and entered the Running state (so not preventing multiple flows to be run which is my goal)František
08/14/2024, 12:02 PMMitch Zink
08/16/2024, 2:49 AMFrantišek
08/16/2024, 7:32 AMMitch Zink
08/30/2024, 11:14 PMPrabhakar Shah
09/30/2024, 9:30 AMFrantišek
10/08/2024, 2:34 PM