
Build real-time REST APIs with Spring Boot for a blog app, using JWT security, Spring Data JPA and Hibernate with MySQL, and deploy on AWS.
Install and configure Java JDK 23 on Windows 11, set JAVA_HOME and PATH, verify with java -version, and run a quick hello world test using the JSL tool.
Download and install the IntelliJ Idea community edition on Windows 11, configure desktop shortcut, path variable, and associations, then launch and create your first project.
Install and set up Spring Tool Suite 4 on Windows 11, create a simple Spring Boot project with Spring Initializer, and build and test a basic REST API.
Install the Lombok library in Spring Tool Suite, configure it, and verify by building a Spring Boot project that uses Lombok annotations to reduce boilerplate.
Install MySQL server 8 and MySQL Workbench on Windows 10 by downloading the official installer, selecting custom setup, configuring root password, and connecting with Workbench to create a database.
In this lecture, you will learn what is REST, Rest Architecture, and REST Architecture Constraints.
Learn how six REST architectural constraints—client-server, statelessness, cacheability, uniform interface, layered system, and optional code on demand—shape reliable, scalable APIs.
In this lecture, you will learn REST Key Concepts - Resource, URI and Sub-resource
In this lecture, you will learn important HTTP methods
In this lecture, you will learn important HTTP Status Codes
Learn the core components of an HTTP request—the request line, headers, body, and query parameters—and how servers use them to process actions in REST APIs.
Explore the core components of HTTP responses—status line, status codes, headers, and body—and learn how Spring Boot constructs and uses them to build reliable REST APIs.
Understand payload as the actual data inside the rest api request or response body. Explore formats like json, xml form data, binary data, and files, and security and validation considerations.
Explore how a rest message serves as full http request or response exchanged between a client and server, including the request line, headers, and optional body, highlighting its stateless design.
Explore statelessness in REST APIs, where the server stores no client data between requests and the client carries authentication with JWT tokens, keeping state on the client.
Identify rest resources by describing them with data, giving each a unique id, and enabling create, read, update, and delete operations; recognize subresources like order items and blog comments.
Design clean rest urls by using nouns and plural collections, with path parameters for ids, sub-resources for relationships, shallow nesting, and query parameters for filtering and versioning.
learn how to assign http methods to rest resources: get for retrieval, post for creation, put for full updates, patch for partial updates, and delete for removal, with real-world examples.
Learn to model data with json for rest apis, design clean, consistent responses for resources, handle errors with structured json, and apply clear naming and nesting conventions.
Use plural nouns to name resources in REST APIs, starting from a collection in URLs like /users or /pizzas, to keep your API consistent, predictable, and easy to understand.
Set the content-type header when sending data and the accept header when receiving, typically with application/json, to ensure predictable data exchange and proper error handling.
Model real-world relationships with subresources to keep rest APIs clear and navigable. Use parent-child paths like /users/{id}/addresses and /products/{id}/reviews to express one-to-many relationships and many-to-many cases, maintaining precision.
Learn which http status codes to return in a rest api, from 200 and 201 to 204, 400, 401, 403, 404, 405, 500, 502, and 503.
Explore the real differences between GET and POST in REST APIs. Learn when to fetch data versus submit data, visibility of query parameters, caching, idempotency, payload limits, and security considerations.
post creates new resources at server-defined locations and is not idempotent, while put updates at a known URL and is idempotent.
Compare put and patch in rest APIs, where put performs full resource replacement and patch handles partial updates. Both can be idempotent, with patch offering smaller payloads and partial edits.
Compare http and https: https encrypts data with ssl/tls, verifies identity with certificates, and builds trust, making it essential for logins, payments, and seo.
Explore the rest vs soap comparison, detailing architecture, formats (json/xml), transport, security, and error handling, with real-world use cases for web, mobile, and enterprise systems.
Explore the key differences between rest and graphql for api development, including endpoints, data requests, and schema evolution. Assess performance, tooling, and real-world use cases to choose the right approach.
Understand rest as a server-side api design using http methods and resources. Distinguish ajax as a browser-side, asynchronous technique that fetches data without full page reloads.
Discover how Spring Boot eliminates boilerplate by auto-configuring common Spring beans, provides an embedded Tomcat server, and offers starter dependencies and externalized configuration for rapid, dependency-managed app development.
Discover how spring boot starters simplify dependencies, auto configuration reduces boilerplate, externalized configuration supports environments, and actuator offers production-ready insights, with embedded containers for jar deployment.
Create your first Spring Boot project using Spring Initializer, selecting Maven, Java 17, and Spring Web Starter, then add Spring Data JPA, MySQL driver, time lib, and Security as needed.
Explore the Spring Boot project structure, including pom.xml dependencies and the Maven plugin, and review src/main/java and resources with the main Entrypoint class, @SpringBootApplication, and application.properties.
Discover how Spring Boot starters simplify dependency management by providing single starter dependencies, such as starter web, data jpa, and security, that pull in libraries and manage versions.
Explore how the Spring Boot starter parent project provides default configurations, manages the versions of dependencies, and configures Maven plugins, while enabling overrides like Java version 17 to 19.
Spring Boot auto configuration automatically configures spring beans based on added starter dependencies, such as web and data JPA, including dispatcher servlet and data source.
Explore how spring boot auto configuration wires beans from starters, automatically configuring dispatcher servlet, data source, entity manager, and transaction manager with debug logging.
Explore how the Spring Boot application annotation combines auto configuration, component scan, and configuration to enable auto configuration, scan the base package, and register extra beans.
Explore Spring Boot REST API basics for a blog app, learning core annotations, returning JSON for beans and lists, and using ResponseEntity and request mapping for a base URL.
Create a Spring Boot project using Spring Initializr, import it into IntelliJ, and run the app with the embedded Tomcat on port 8080 to begin building real-time REST APIs.
Create a simple Spring Boot rest api using a rest controller and get mapping to return a hello world message as json at http://localhost:8080/hello-world.
Create a Spring Boot rest API that returns a Java bean as JSON. Define a student bean with id, first name, and last name, exposed via get mapping at /student.
Build a Spring Boot REST API that returns a list of students as JSON using @GetMapping, returning a List<Student> at /students, and test it on port 8080.
Learn to build a spring boot rest api that handles path variables with @PathVariable, binding URI template variables from the URL, including multiple path variables.
Explore how to build a Spring Boot REST API that extracts query parameters with @RequestParam, handling single and multiple parameters in URLs like /students/query?id=1&firstName=Ramesh&lastName=Fadatare.
Create a spring boot rest api that handles post requests to /students/create using @PostMapping and @RequestBody to map incoming json to a student object and return it with 201 created.
build a spring boot rest api that handles http put requests to update an existing student, using @putmapping, @requestbody, and @pathvariable to bind data from the request.
Create a Spring Boot REST API that handles HTTP delete requests with @DeleteMapping, binding id via @PathVariable to delete a student resource. Test with Postman and expect HTTP 200 OK.
Learn to build complete http responses in Spring Boot using ResponseEntity by configuring status codes, headers, and body, with ok() and created options for rest APIs.
Define a common base URL for all REST APIs in a Spring MVC controller by applying @RequestMapping at the class level, avoiding repetition across endpoints.
Send a client request triggers a flow from embedded Tomcat to the dispatcher servlet, handler mapping, and controller, with the HTTP message converter returning JSON or XML.
Implement a blog backend with post management, comments, categories, and JWT-based authentication, offering post listing with pagination and sorting. Expose REST APIs with validation, exception handling, and cloud deployment.
Selects the technology stack for the blog app, including Java 17+, Spring Framework with Springboard, Spring Security, Spring Data JPA with Hibernate, JWT authentication, Marvin build tool, and MySQL.
Identify key resources for a blog application—post, comment, user, and category (and potentially tags)—and design REST APIs with pagination, sorting, and JWT-secured authentication for user management.
Explore a three-layer Spring Boot architecture with controller, service, and repository layers for building REST APIs. Use DTOs and JSON with Postman to design post, comment, login, and signup resources.
Design a rest api for the post resource by detailing endpoints like get all posts, get post by id, create, update, delete, with json media type, status codes, and pagination.
Design a REST API for the comment resource by listing endpoints for retrieving, creating, updating, and deleting comments under a post, using /api/posts/{postId}/comments and status codes like 200 and 201.
Design a REST API for signup and signin using a simple table that lists method, url, status, and description, illustrating POST /api/auth/signup and POST /api/auth/siginin with 200 OK responses.
Learn how the data transfer object pattern enables efficient client-server data exchange in building real-time rest apis with spring boot, delivering a single api response for organization, departments, and employees.
Disclaimer:
"This course requires you to download Docker Desktop from the official Docker website. If you are a Udemy Business user, please check with your employer before downloading software."
In this course, you will learn how to build REAL-TIME REST APIs by developing a complete Blog application and how to deploy it on the AWS cloud.
In this course, we will follow the real-time industry-standard project development approach.
This course covers Spring Boot REST API development from scratch.
This course covers the REST API fundamentals from scratch.
Important: This course supports Spring Boot version 3+ and Spring Security version 6+.
The source code and PDF files (class notes) are available for download.
What is REST API?
REST stands for Representational State Transfer. It’s a set of rules that developers use to build APIs that work over the web, just like the websites you visit in your browser. When an API follows the rules of REST, we call it a REST API.
What is Spring Boot?
Spring Boot is an opinionated framework that helps developers build Spring-based applications quickly and easily.
The main goal of Spring Boot is to quickly create Spring-based applications without requiring developers to write the same boilerplate configuration repeatedly.
Spring Boot is a very popular framework for developing REST web services and microservices.
You will learn the following topics in this course:
Learn how to build great REST APIs for a Blog App using Spring Boot, Spring Security, JWT, Spring Data JPA (Hibernate), MySQL database
Learn REST API Fundamentals - REST API, Resource, Sub-resource, URI, HTTP methods, HTTP status codes
Learn REST API Fundamentals - How to Design REST APIs
Learn REST API Best Practices
Learn REST API Differences - GET vs POST, POST vs PUT, PUT vs PATCH, REST vs SOAP, and REST vs GraphQL
Learn the basics of Spring Boot REST API Development along with annotations
Learn how to build CRUD REST APIs for a Blog App
Learn how to build REST APIs for ONE-TO-MANY relationships in a Blog App
Learn how to build REST APIs for Pagination and sorting for a Blog App
Learn how to build a Search / Filter REST API
Learn how to build REST APIs for Login/Sign-in and Signup for a Blog App
Learn how to use Lombok
Learn how to use DTOs
Learn Spring Boot REST API exception handling
Learn Spring Boot REST API validation
Learn how to use Spring Security in the Spring Boot Blog App
Learn Spring Security In-memory and Database authentication and authorization
Learn how to secure REST APIs ( role-based security) in a Blog App
Learn how to write query methods using Spring Data JPA
Learn one-to-many and many-to-many JPA mappings
Learn how to test REST APIs using Postman REST Client
Learn What is JWT and How it Works
Learn how to configure JWT ( JSON Web Token) in Spring Security
Learn how to secure REST APIs using JWT
Learn how to use JWT with the Login API
Learn versioning REST APIs
Learn Important 4 versioning REST API strategies
Learn REST API documentation with Swagger UI
Test Spring Boot REST APIs with JWT using Swagger UI
Learn Customizing Swagger REST Documentation with Annotations
Learn how to add profiles (to deploy in different environments) Spring Boot project.
Learn Transaction Management with Spring Boot and Spring Data JPA
Learn how to deploy the Spring Boot Blog app on AWS cloud (production)
Dockering Spring Boot Application Step-by-Step
Dockering Spring Boot MySQL CRUD Application Step-by-Step
Docker Compose - Dockerizing Spring Boot MySQL CRUD Application Step-by-Step
30+ bonus videos for Spring Boot beginners
Important Spring Boot topics for interviews
Tools and Technologies used in this course:
Technologies:
Java
Spring Boot
Spring MVC
Spring Data JPA ( Hibernate)
Spring Security
JWT
Tomcat
IDE:
Intellij IDEA
Database:
MySQL database
Tools:
Swagger - API documentation
Postman - Test REST API
Maven - Build Tool
Deployment on Production:
AWS
By the end of this course, you will be able to build real-time REST APIs for any application using Spring Boot and deploy them on the AWS cloud.