What is the appropriate way to create an aggregate...
# ask-community
c
What is the appropriate way to create an aggregate flow, such that flow A runs when the aggregate flow kicks off, flow B runs at 9pm, and Flow C runs once A and B are complete?
Flow B doesn't wait for the scheduled start time
z
Hm. From looking at the code, the scheduled start time should definitely be passed to the created flow run. If you look at the states of the flow run created for B can you see the Scheduled state’s start time?
c
Looking in our prefect server (self hosted), I couldn't find Flow B start time in the schematic. Where should I be looking for that state?
z
Oh I see, you haven’t passed
wait=True
to
StartFlowRun
so the task to create the flow run for B is running and finishing although all that has happened is that the flow run has been scheduled
You should be able to see the flow run for B under its flow page. There should also be an artifact linking to the flow run on the main flow’s page
c
hmm. I see the task for Flow B under the Aggregate Flow page -> run instance. If I go t the Flow Page for B, it doesn't show the artifact linking to the aggregate flow. Also I don't see a subflow running in the project overview, even though it is, only the agg flow shows up
Not sure it matters, but we are on 0.15.3
k
A bit confused. What do you mean by artifact? You should definitely see if though in the project overview. Do you not see it even if you refresh?
Ah yeah I think there will be nothing linking it to the parent flow. The parent flow will have logs that link to the subflow. The subflow just knows it was triggered. For Orion (Prefect 2.0) though, we will be making this experience a lot better. You could rename the flow runs to make it more explicit
c
Yeah, it doesn't show up in the overview. That's fine if it's not linked. I'm really just trying to figure out how to have flow B respect the scheduled start time, even though it was kicked off from an aggregating flow