Hello,
I have a question regarding Prefect2.0. My team was using Prefect1.0 earlier and had been using the Graph QL functionality. Do we have this functionality in Prefect 2.0 as well?
✅ 1
s
Stéphan Taljaard
07/26/2022, 1:44 PM
Hi. The GraphQL API has been swapped out for a REST API
🦜 1
🙏 1
d
Divya
07/26/2022, 2:31 PM
Thank you for getting back @Stéphan Taljaard! If possible can you please provide the documentation for the same?
Thank you sharing the documentation. Will go through!
s
Sebastian
07/27/2022, 9:38 AM
Out of curiosity, what was the motivation for abandoning GraphQL in favour of REST?
t
Taylor Curran
07/27/2022, 1:16 PM
Hi @Sebastian 🙂
Our CTO Chris White did a great job of answering this question live the other day.
Here's a link to the timestamp▾
of that recording.
In summary
• Lots of people were unfamiliar with GraphQL and asking for RestAPI
• For Prefect Server specifically, because we chose to use GraphQL, that’s the reason why Prefect Server is so heavy - we needed the query schema off of the database (which is what Hasura does)
• For our business logic, we had all of our mutations defined in Python code
• Those are two separate GraphQL schemas so we had to stitch them together
• All of this resulted in a very large, heavy container that was Prefect Server
• REST is very lightweight and allows us to automatically pull in Prefect flows into the UI even if they ran before the UI was launched
• Finally, GraphQL is very hard to manage when exposing publicly to a high volume of usage
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.