본문 바로가기
Back-end/Spring Boot + REST API

Spring boot - blog application (REST API)

by javapp 자바앱 2022. 6. 28.
728x90

What is REST?

The REST stands for REpresentational State Transfer

 State means data

 REpresentational means formats (such as XML, JSON, YAML, HTML, etc)

 Transfer means carry data between consumer and provider using the HTTP protocol

 

Key points about REST - REpresentational State Transfer:

• REST was originally coined by Roy Fielding, who was also the inventor of the HTTP protocol.

• A REST API is an intermediary Application Programming Interface that enables two applications to communicate with each other over HTTP, much like how servers communicate to browsers.

• The REST architectural style has quickly become very popular over the world for designing and architecting applications that can communicate.

• The need for REST APIs increased a lot with the drastic increase of mobile devices. It became logical to build REST APIs and let the web and mobile clients consume the API instead of developing separate applications.

 

REST – Architecture

 

REST Architectural Constraints

An API that has the following constraints is known as RESTful API:

Client-server architecture: The client is the front-end and the server is the backend of the service. It is important to note that both of these entities are independent of each other.

Stateless: No data should be stored on the server during the processing of the requested transfer. The state of the session should be saved at the client’s end.

Cacheable: The client should have the ability to store responses in a cache. This greatly improves the performance of the API.

Uniform Interface: This constraint indicates a generic interface to manage all the interactions between the client and server in a unified way, which simplifies and decouples the architecture.

Layered System: The server can have multiple layers for implementation. This layered architecture helps to improve scalability by enabling load balancing.

Code on Demand: This constraint is optional. This constraint indicates that the functionality of the client applications can be extended at runtime by allowing a code download from the server and executing the code.

 


What is Resource?

What is URI?

 

What is Sub-resource?

 

Important HTTP Methods

 

Important HTTP Status codes

 


 

 


 

게시물 도메인

 

 

댓글 도메인

 

 

로그인 로그아웃

This REST API design is going to help us whenever we actually develop the rest APIs.

 

Ths is a typical standard most organizations use to create a REST API design for resources.

 

 


 

 

Spring Starter Project

 

 

 

 

 

유데미에서

Building Real - Time Rest APIs with Spring Boot 강의를 들으며 정리를 할 예정입니다.

 

https://www.udemy.com/share/105eEM3@pEikaK6l4aPYag3qSBYQn50V3WBR6yxl9tJXKxTVdWXjK5_BfXKWrtDg8-uB02cJzw==/

 

Building Real-Time REST APIs with Spring Boot - Blog App

Learn building REST API’s using Spring Boot, Spring Security, JWT, Spring Data JPA, Hibernate, MySQL and Deploy on AWS

www.udemy.com

 

댓글