I'm new to Prefect. I've a scenario and I cant seem to find a way in prefect to do it.
I've 3 flows - A, B, C all running on their own schedules. Flow B and C have an indirect dependency on A (the latest run of A should be completed and not failed). I was trying to check the status of the latest flow run using FlowRunView (which takes in flow_run_id as parameter) inside Flow B and C. Is there an api to get the latest flow_run_id for a flow (using its name)?
Is there any other workaround?
k
Kevin Kho
09/14/2021, 6:16 PM
Hey @Vasudevan Balakrishnan, there’s not a built-in way to do this. You need to use the GraphQL API to get a flow_id that matches the name and project, and then get the latest flow run. It seems it would be easier if A triggered B and C?
v
Vasudevan Balakrishnan
09/14/2021, 6:34 PM
thanks @Kevin Kho i've been able to use the graphql api to get the information. unfortunately we have other constraints due to which we can't trigger B / C from A.
Bring your towel and join one of the fastest growing data communities. Welcome to our second-generation open source orchestration platform, a completely rethought approach to dataflow automation.