eclipse / microprofile-graphql

microprofile-graphql
Apache License 2.0
98 stars 40 forks source link

// // Copyright (c) 2020 Contributors to the Eclipse Foundation // // See the NOTICE file(s) distributed with this work for additional // information regarding copyright ownership. // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to in writing, software // distributed under the License is distributed on an "AS IS" BASIS, // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. // image:https://github.com/eclipse/microprofile-graphql/workflows/Build/badge.svg[link="https://github.com/eclipse/microprofile-graphql/actions"] image:https://javadoc.io/badge2/org.eclipse.microprofile.graphql/microprofile-graphql-api/javadoc.svg[link="https://javadoc.io/doc/org.eclipse.microprofile.graphql/microprofile-graphql-api"] image:https://badges.gitter.im/eclipse/microprofile-graphql.svg[link="https://gitter.im/eclipse/microprofile-graphql"]

= Microprofile GraphQL Specification

Read the https://download.eclipse.org/microprofile/microprofile-graphql-2.0/microprofile-graphql-spec-2.0.html[MicroProfile GraphQL 2.0] Specification

== Structure

This project consist of 3 parts:

Implementations can decide to implement only the Server, or only the Client, or both.

== Use this in your project to depend on both the server and client API:

[source,xml,numbered]

org.eclipse.microprofile.graphql microprofile-graphql-api 1.0.3

== About GraphQL is an open-source data query and manipulation language for APIs, and a runtime for fulfilling queries with existing data. It provides an alternative, though not necessarily a replacement for REST.

GraphQL was developed internally by Facebook in 2012 before being publicly released in 2015.

On 7 November 2018, the GraphQL project was moved from Facebook to the newly-established https://www.linuxfoundation.org/press-release/2018/11/intent_to_form_graphql/[GraphQL foundation], hosted by the non-profit Linux Foundation. This is a significant milestone in terms of industry and community adoption.
GraphQL is used by many large and small customers including Atlassian, Coursera, Facebook, GitHub, PayPal, Twitter, and https://graphql.org/users/[many more].

== Why GraphQL The main reasons developers might want to use GraphQL are:

== Why MicroProfile

The official purpose of MicroProfile is to optimize Enterprise Java for a microservices architecture and delivers application portability across multiple MicroProfile runtimes. GraphQL is already widely used in Microservices architectures as the API Endpoint. As noted in the Known java libraries section, there are several Java-based GraphQL libraries available, but none with the reach of the MicroProfile community. GraphQL continues to grow in popularity, and as such there should be a specification for GraphQL development in Java. MicroProfile is the optimal place to host that standard as it is open, ideally suited for incubating technologies, and has broad reach both in terms of the user community and vendor support.

== What GraphQL is not

This specification will focus on making it easy for developers to create a GraphQL Service/Endpoint and publish it as an API. Where the data comes from (NoSQL, Relational DB, another service, etc.) is not the concern of this Proposed Specification.

== Implementations

== Acknowledgements

This API and specification would not be possible without the enormous assistance from the https://github.com/leangen/graphql-spqr[GraphQL SPQR project].

== Contributing

Do you want to contribute to this project? link:CONTRIBUTING.adoc[Find out how you can help here].