Distelli/graphql-apigen

Provide async generator

Opened this issue · 5 comments

With the introduction of graphql-java-async planned, it would be great if one could choose between generating blocking and non-blocking code.

Hi @bmsantos ,

How do you see this fitting into graphql-apigen? Specifically, this project generates interfaces used to implement the GraphQLObjectType's that you wire into your GraphQLSchema. So, you should be able to use the async code without any changes.

Please correct me if I'm wrong.

Thanks,
-Brian

Hi @brimworks,

To be honest, I'm yet to play with apigen but my understanding is that the interfaces for data fetching (Resolvers) will have to return Future instead of T.

I'll have to dig a wee bit deeper and play with it.

Thanks,

@brimworks, as mentioned earlier, just published a simple Vert.x project that uses the current implementation of graphql-java-async. You can find it here.

It will be used to exercise:

  1. graphql-java-async
  2. GraphQL Schema ApiGen
  3. @aschrijver implementation of Facebook's DataLoader for Vert.x

By the way, didn't have the time to go through your earlier comments/improvements/recommendations. I'll go through them as soon as possible.

Thanks

Unfortunately, the latest update is that async support isn't planned until a 4.x release :(.