Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/mehdi-reza/graphql

GraphQL quick starter using quarkus and vertx-web-graphql
https://github.com/mehdi-reza/graphql

graalvm graphql quarkus vertx

Last synced: 16 days ago
JSON representation

GraphQL quick starter using quarkus and vertx-web-graphql

Awesome Lists containing this project

README

        

= graphql =

== Main components ==

==== GraphQLProducer.java ====
This sets up graphql by parsing the schema and binding wirings for data fetchers.

==== Routes.java ====

This enables graphql route to run queries (GET and POST). It also enables GraphiQL, hit your browser at http://localhost:8080/graphiql/

==== Fetchers ====

Two fetchers Profile and Wallet fetchers are defined in example.graphql.fetchers which are used in runtime wirings.

===== Launch =====
----
mvn clean package quarkus:dev
----

===== Run a query =====
----
curl -d'{profile{id name wallets{id name}}}' -H'Content-Type: application/graphql' -H'Accept: application/json' http://localhost:8080/graphql
----

----
{"data":{"profile":{"id":"1","name":"Mehdi Raza","wallets":[{"id":"1","name":"JAZZ"},{"id":"1","name":"EasyPaisa"}]}}}
----