Тёмный

TAMIL REST VS GRAPHQL DIFFERENCE | Explain REST API vs GraphQL | InterviewDOT 

Interview DOT
Подписаться 39 тыс.
Просмотров 2,6 тыс.
50% 1

Click here - / @interviewdot to get notifications. REST VS GRAPHQL DIFFERENCE
REST stands for REpresentational State Transfer, API for Application Programming Interface. This means a programming interface that is based on the paradigms and behavior of the World Wide Web (WWW) and describes an approach for communication between client and server in networks.
The architectural approach known as REST (or also ReST) describes how distributed systems can communicate with each other. In this sense, a REST API is an alternative to other interfaces such as SOAP or WSDL. However, REST itself is neither a protocol nor a standard. Implementations of the architecture characterized as “RESTful” use standardized methods such as HTTP / S, URI, JSON or XML.
Six architectural principles
REST does not specify in detail how compliant services are implemented in detail. Rather, the approach requires the following six architectural principles ("constraints"):
Client-server model : REST requires a client-server model, i.e. wants to see the user interface separate from the data management. On the one hand, this should make it easier for clients to port to different platforms; Simplified server components, on the other hand, should scale particularly well.
Statelessness : Client and server must communicate with each other stateless. This means: Every request from a client contains all the information a server needs; Servers themselves cannot use a saved context. This constraint thus improves visibility, reliability and scalability. For this, however, REST accepts disadvantages in network performance; In addition, servers lose control over consistent behavior of the client app.
Caching : To improve network efficiency, clients can also save responses sent by the server and use them again later for requests of the same type. Accordingly, the information must be labeled as “cacheable” or “non-cacheable”. The advantages of more responsive applications with higher efficiency and scalability are bought with the risk that clients access stale data from the cache.
Uniform interface : The components of REST-compliant services use a uniform, general interface that is decoupled from the implemented service. The goal of the whole thing is a simplified architecture and increased visibility of interactions. In return, one accepts a lower efficiency if information is brought into a standardized format - and not adapted to the needs of special applications.
Layered system : REST uses multilayer, hierarchical systems ("Layered System") - each component can only see directly adjacent layers. This allows, for example, encapsulation of legacy applications. Intermediaries acting as load balancers can also improve scalability. The disadvantages of this constraint are additional overhead and increased latencies.
Code-On-Demand : This constraint requires that the functions of clients can be expanded via reloadable and executable program parts - for example in the form of applets or scripts. However, as an optional constraint, this condition can be deactivated in certain contexts.
Implementation via HTTP
In practice, the REST paradigm is preferably implemented using HTTP / S. Services are addressed via URL / URI. The HTTP methods (GET, POST, PUT, ...) specify which operation a service should perform.
GET | POST | PATCH | DELETE - REST in practice
Since the World Wide Web already provides the infrastructure necessary for REST, you can already try your hand at using a browser with the appropriate interfaces. A possible introduction to this is provided by the Fake Online REST API for Testing and Prototyping available at jsonplaceholder... .
The solution allows access to a number of related data sets. The desired resource and any parameters are appended to the URL after the slash. The resources offered include 100 posts, 500 comments, 100 albums, 5,000 photos, 200 todo lists and 10 users. The supported HTTP methods are:
GET - requests data from the server
POST - transmits data to the server
PUT / PATCH - change existing data on the server
DELETE - deletes existing data on the server
GraphQL is a query language for your API, and a server-side runtime for executing queries by using a type system you define for your data. GraphQL isn't tied to any specific database or storage engine and is instead backed by your existing code and data.

Опубликовано:

 

7 сен 2024

Поделиться:

Ссылка:

Скачать:

Готовим ссылку...

Добавить в:

Мой плейлист
Посмотреть позже
Комментарии : 13   
@king-power
@king-power 2 года назад
super bro
@InterviewDOT
@InterviewDOT 2 года назад
Thanks a million for valuable feedback, if you not yet subscribed kindly subscribe to InterviewDOT channel for latest software updates - happy learning - InterviewDOT
@sudharsananr3574
@sudharsananr3574 5 месяцев назад
Nice explain about Graphql , Plz make video about mutation, query and subscription workflow .
@InterviewDOT
@InterviewDOT 5 месяцев назад
Thanks a million for the feedback , happy learning , InterviewDOT
@padmanabanparthiban
@padmanabanparthiban 5 лет назад
excellent..
@InterviewDOT
@InterviewDOT 5 лет назад
Dear Padmanaban Parthiban, Thanks a lot for your valuable feedback, Happy that it helped you, InterviewDOT
@vigneshj1086
@vigneshj1086 6 лет назад
Nice bro Can u Upload more videos About GrapQl?
@InterviewDOT
@InterviewDOT 6 лет назад
Thanks a lot for your valuable feedback- Happy Learning
@gnanaoli7890
@gnanaoli7890 4 года назад
Can you provide any example graphql with mysql using postman rest api
@InterviewDOT
@InterviewDOT 4 года назад
Thanks for the request, sure will make it and upload - InterviewDOT
@abiakhil69
@abiakhil69 4 года назад
Super bro
@InterviewDOT
@InterviewDOT 4 года назад
Dear Abi Akhil, Thanks a lot for your awesome feedback, I am really happy that helped you, happy learning - InterviewDOT
Далее
GraphQL vs REST: what you need to know
10:11
Просмотров 17 тыс.
APIs Explained | Real World Examples
11:36
Просмотров 507 тыс.
GraphQL vs REST: Which is Better for APIs?
7:31
Просмотров 198 тыс.
gRPC vs REST - KEY differences and performance TEST
7:02
What is an API and how do you design it? 🗒️✅
15:26
🔴 What is Redis? - Tamil | Random Tech Talks
12:05
What Is GraphQL? REST vs. GraphQL
5:15
Просмотров 397 тыс.