This message was deleted.
# ask-marvin
s
This message was deleted.
m
thought for 312.2 seconds
You can set it with the
--concurrency-limit-collision-strategy
flag on
prefect deploy
. Example (adding CANCEL_NEW to your command):
Copy code
uv run prefect deploy ./workflows/example_workflow.py:example_flow \
  --name example-deployment \
  --pool local-pool \
  --cron "* * * * *" \
  --concurrency-limit 1 \
  --concurrency-limit-collision-strategy CANCEL_NEW
Notes: - Valid strategies include at least
CANCEL_NEW
(do not queue; cancel new runs when the limit is reached). If you omit this flag, Prefect will use its default behavior (typically queueing). - You can also set this in
prefect.yaml
if you prefer config over CLI:
Copy code
deployments:
  - name: example-deployment
    entrypoint: ./workflows/example_workflow.py:example_flow
    work_pool: local-pool
    schedules:
      - cron: "* * * * *"
    concurrency_limit:
      limit: 1
      collision_strategy: CANCEL_NEW
References: - Global concurrency limits (context on strategies) - I verified the
prefect deploy
interface exposes
concurrency_limit
and
concurrency_limit_collision_strategy
options. If you want, I can paste the full
--help
output.