other-languages

here be heresies and things we have to use for work
dangercoder 2019-11-25T14:33:04.016Z

I have a question regarding Java and Graphql, do you recommend any library? ping @gklijs 😉

dangercoder 2019-11-25T14:36:03.017Z

I guess https://github.com/graphql-java/graphql-java is the way to go.

gklijs 2019-11-25T14:38:45.017300Z

The spring boot one has some flaws, and you need to provide the schema in the 'javascript' way. I generated it from the lacinia implementation with some tool, but would not like it myself. Graphql-java is very verbose I heard, haven't tried it myself, and possibly with some lambda tricks you can generalize those. Want to give the kotlin one a go, since it's kind of created in collaboration with Apollo. And the kotlin one generates the schema based on annotations.

gklijs 2019-11-25T14:42:02.017500Z

https://github.com/openweb-nl/kafka-graphql-examples/blob/ge-java/GraphQL-endpoint GraphQL springboot starter example. If it's an application already using spring boot, and it has to be Java it's fine. Apart from the schema you need little code.

dangercoder 2019-11-25T14:43:26.017700Z

Thank you for the insight, very valuable! Yeah. I have to use Spring Boot and Java, no freedom when it comes to tech-stack 😕.

gklijs 2019-11-25T14:45:29.017900Z

You probably won't use subscriptions, but if you do be wary that it doesn't support queries over web socket, witch the re-graph Clojure GraphQL client defaults to.

gklijs 2019-11-25T14:48:37.018100Z

Will create a kotlin version there in a few days, and maybe a ktor (kotlin framework build for async using coroutines) if I have time for it. Also be running stress tests on the subscriptions.

⭐ 1