GraphQL vs Spring: What are the differences?
GraphQL: A data query language and runtime. GraphQL is a data query language and runtime designed and used at Facebook to request and deliver data to mobile and web apps since 2012; Spring: Provides a comprehensive programming and configuration model for modern Java-based enterprise applications. A key element of Spring is infrastructural support at the application level: Spring focuses on the "plumbing" of enterprise applications so that teams can focus on application-level business logic, without unnecessary ties to specific deployment environments.
GraphQL can be classified as a tool in the "Query Languages" category, while Spring is grouped under "Frameworks (Full Stack)".
"Schemas defined by the requests made by the user", "Will replace RESTful interfaces" and "The future of API's" are the key factors why developers consider GraphQL; whereas "Java", "Open source" and "Great community" are the primary reasons why Spring is favored.
GraphQL and Spring are both open source tools. Spring with 30.6K GitHub stars and 19.6K forks on GitHub appears to be more popular than GraphQL with 11.7K GitHub stars and 753 GitHub forks.
Facebook, Instagram, and Twitter are some of the popular companies that use GraphQL, whereas Spring is used by MIT, Zillow, and Intuit. GraphQL has a broader approval, being mentioned in 559 company stacks & 748 developers stacks; compared to Spring, which is listed in 319 company stacks and 184 developer stacks.
What is GraphQL?
What is Spring?
Need advice about which tool to choose?Ask the StackShare community!
Sign up to add, upvote and see more prosMake informed product decisions
Sign up to get full access to all the companiesMake informed product decisions
Sign up to get full access to all the tool integrationsMake informed product decisions
Spring is another gift rained down by the gods of Open Source Software (a.k.a. Pivotal Labs in this particular case) that just makes sense on all levels.
From Spring Boot, to SpringMVC, the configuration architecture & profile paradigm, Spring Cloud expandability, to the ease with which one can deploy Spring applets as microservices within Docker is an absolute joy.
The core of the application use Spring Stack, to provide services and structure like:
- Self contained application with spring boot
- And many others.
GraphQL will be used as the public API for the data persistence layer. It communicates nicely with all other languages and can provide API responses in the format specified in the request.
그냥 간단한 MVC 웹 프레임 워크 인줄 알았는데 정말 모듈화가 잘 되있고, 사용하다보면 개발자에게 정말 편리하게 만들어 놓았다. vaildation 부분은 따로 처리 할 수 있고, 파라미터 담는 변수와 디폴트 값을 인자로 설정해 주는 부분도 참 좋은 것 같다. 또 spring-data 는 jpa 활용해 빠르게 개발하는데 유용하다.
Applied GraphQL in a side-project I'm currently working on. Using the Apollo GraphQL implementation for both server-side and React client.
- SpringFramework 중 MVC , AOP 등의 라이브러리를 활용하여 웹 어플리케이션 프로젝트 구성
공통 로직 구현 및 보안 처리 가능
Spring5에서 지원하는 함수형 프로그래밍 경험 있음
From Magento 2.3 GraphQL is provider by a core implementation, this is used to implement PWA frontend.
Used Spring Boot and its ORM to interacting with database server for web application development.