micronaut-projects/micronaut-graphql

Graal Support

Closed this issue · 1 comments

First of all, thanks for added GraphQL support to the Micronaut Framework.

May I know is there any plan to support Graal for the fabulous micronaut-graphql packages? As I didn't find any graphql graal tests at https://github.com/micronaut-graal-tests.

Currently, I managed to make it works with Graal by import the source code to the following location of the project:
https://github.com/limcheekin/micronaut-person/tree/graal-data-jpa-2.0.x/src/main/java/io/micronaut/configuration/graphql
with the following minimal changes:

  • Added @Introspected to the GraphQLRequestBody and GraphQLResponseBody class
  • Removed the ws package which caused runtime errors in AWS Lambda and the app don't need such functionality
  • Removed GraphiQLController class which caused build errors and not needed in production

Oh yeah, forgot to mentioned that it works with one side effect, the response come with data property nested inside specification property, for example:

{
    "specification": {
        "data": {
           .....
        }
    }
}

Hopefully the library is support Graal by simply adding the dependency to build.gradle file in the near future. 👍

Closed by #125