This is an example application that demonstrate how to add GraphQL to your existing JAX-RS Application.
This application use these libraries:
Simple CRUD Application that can create, update, delete and get a membership. Every membership has a owner. The application use JPA to persist the Object in a DB. "Business Logic" is in the Membership Service (EJB) and the JAX-RS API in MembershipRestApi.
Added annotations and MembershipGraphQLApi to expose API as GraphQL.
Get the source:
git clone https://github.com/phillip-kruger/membership.git cd membership
This demo runs on Thorntail, OpenLiberty and Payara-micro. Build and start:
mvn clean install -Pthorntail
mvn clean install -Popenliberty
mvn clean install -Ppayara
The server is now up and running with some test data populated (see resources/META-INF/load.sql)
- Front page : http://localhost:8080/membership/
- Swagger UI : http://localhost:8080/membership/rest/openapi-ui/
- GraphiQL : http://localhost:8080/membership/graph/graphiql/