Posts

GraphQL Vs REST comparison

Image
GraphQL is a good replacement for REST API for very obvious reasons. Let us have a look at the reasons and analyze the advantages of GraphQL. REST GraphQL Multiple end points Single end point Overfetching and underfetching issues are present. Overfetching and underfetching issues are resolved The endpoint need to be well documented and published before they can be consumed The endpoints and possible queries and mutations are available through a playground. They can be tested before the UI can fire the queries  Let us understand the issues and the way in which they are resolved in GraphQL. Let us take the example of scientific experiments. Lets create one such experiment.  REST Paradigm: Create Experiment Endpoint The end point is required to be exposed to create the experiment. It is a HTTP POST request http://localhost:8080/experiment/create    Get List of Ex...