Hello, I am using `AirbyteTriggerSyncOperator` to ...
# help-api-cli-orchestration
s
Hello, I am using
AirbyteTriggerSyncOperator
to trigger sync of my airbyte jobs using airfow. I want to trigger these tasks inside a dag conditionally. I.e. if a condition is false then I want to skip this task which triggers a sync job and move on with the rest of the DAG How do I do it?
m
Hello @Shubham probably this question is better to ask directly in the Airflow community. But here are some instructions: https://stackoverflow.com/questions/43678408/how-to-create-a-conditional-task-in-airflow
s
hi @Marcos Marx (Airbyte) thanks for the response. I was able to figure it out. For anyone else looking for the same, wrap the operator inside a python function and if the condition is not met then raise
AirflowSkipException
. Don't forget to add appropriate trigger rules for the downstream tasks