Backend Concepts

Client and Server Model

Client & Server Model

A client requests something to the server. After doing the computation, the server will send the response.

Request Types

HTTP stands for Hypertext Transfer Protocol

create the new data on the server (submit)

read the data on the server (fetch)

update the old data on the server (after editing, update)

delete the data present on the server (deleting the whole data)

Idempotent

Idempotent means it can be retried or executed multiple times without causing unintended side effects.

GET, PUT, & DELETE are idempotent.

Idempotent HTTP Requests vs Unsafe HTTP Requests

Middleware

A middleware is just a function that can modify the incoming data. it is called middleware because it stands in middle of the request and response. so, it’s just a step that the requests goes through while it’s been processed.