Hey community,
Trying to write a graphql query that I can specify the
project
and the
flow name
and get a list of currently active flows and their state ( running, or complete etc ).
Is this possible ?
Cant seem to find anything for the use case...
k
Kevin Kho
08/05/2021, 1:30 AM
I think something like:
Copy code
query{
flow (where:{project: {name: {_eq: "test"}},
name:{_eq: "test"}}){
project {
id
name
}
name
flow_runs{
id
name
state
}
}
}
might work?
b
Ben Muller
08/05/2021, 1:33 AM
that is on the right track, but seems to show all versions of the flow, can we just get most recent?
k
Kevin Kho
08/05/2021, 1:36 AM
Add
archived: {_eq: false}}
b
Ben Muller
08/05/2021, 1:38 AM
in the where clause?
k
Kevin Kho
08/05/2021, 1:39 AM
Yes exactly
Kevin Kho
08/05/2021, 1:39 AM
Copy code
query{
flow (where:{project: {name: {_eq: "test"}},
name:{_eq: "test"},
archived: {_eq: false}}){
project {
id
name
}
name
archived
flow_runs{
id
name
state
}
}
}
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.