Skip to content

feifeiq/graphql-java

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

44 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

graphql-java

This is a GraphQL Java implementation based on the specification and the JavaScript reference implementation.

It's an early version, but the query parser should be near 100%.

The execution part is WIP, and validation, error handling and more is still missing.

How to use it

Schema definition

A complex schema (stolen from the js reference implementation): StarWarsSchema

Query

For how to define a simple schema and execute queries: GraphQL Test

Details

graphql-java is based on the same idea as the reference implementation: It assumes nothing about the persistence technology. Instead hooks/callbacks are provided to fetch the data.

The implementation is in Java 7, but the tests are in Groovy and Spock.

The query parsing is done with ANTLR. The grammar is here.

Feedback

I would appreciate any feedback via Twitter @andimarek or Pull request/Issue.

About

GraphQL Java implementation

Resources

License

Code of conduct

Stars

Watchers

Forks

Packages

 
 
 

Contributors

Languages

  • Java 62.2%
  • Groovy 37.5%
  • Other 0.3%