This roadmap is designed to guide you through the fundamentals of Spring Boot and backend development, from beginner to advanced levels. Each stage is thoughtfully structured with specific goals, curated resources, and hands-on tasks to ensure practical learning.
Created and Prepared By Mohamed Zkrallah.
- Three Levels: Beginner, Intermediate, and Advanced, with a focus on building strong fundamentals before progressing to advanced topics.
- Practical Approach: Tasks are abstracted for brevity, with more details available in Notion.
- Bonuses: Bonuses are included for deeper learning. They are not optional, don’t skip them entirely, do them later if you don't have time then. Most bonuses will be already discussed in later weeks.
- AI-Assisted Learning: Feel free to use AI to explore topics further but avoid relying on it to complete tasks or write code for you.
- Time Interval: Some topics can not be finished in just one week, try to learn as much as you can and get back later.
- Self-Learning & Research: As you progress to the advanced level, expect to do more self-learning and independent research. Not everything will be spoon-fed with resources. Developing the ability to learn on your own, read documentation, and experiment with implementations is crucial.
- Quick Tip: I believe in learning by building. Build what you want to learn and learn from what you build. Do not just study theory, but implement what you have learned in a project or even a simple program.
Focus:
- Version control using Git & GitHub.
- Basic knowledge of HTML, CSS, and JavaScipt for the Front-end.
- The OSI Model, specially, the application layer and HTTP internals.
- Java programming language and OOP (Object-Oriented Programming) in Java.
- Prerequisites for Spring Boot.
- Introduction to Spring Boot and Spring MVC.
- Introduction to Database sytems and RDBMS (MySQL Server & PostgreSQL).
- Introduction to ORMs and Spring Data JPA.
Topics:
- Git basics
- GitHub
- Branches
- Commits
- Pull requests
Resources:
- Git and GitHub for Beginners (FreeCodeCamp.org)
- Git and GitHub Tutorial for Beginners (Kevin Stratvert)
- Git and Github (Big Data)
Task: Setup your GitHub account and upload your first repository.
Topics:
- HTML
- CSS
- JavaScipt
- Basic Front-end Knowledge
Resources:
- HTML5 and CSS3 (SuperSimpleDev)
- HTML5 and CSS3 (FreeCodeCamp.org)
- JavaScipt Basics (Mosh)
- Build a Simple Portfolio Front-end (WEB CIFAR)
- Build a Simple To-Do List Front-end (Web Dev Simplified)
- HTML (W3Schools)
- HTML (MDN)
- CSS (W3Schools)
- CSS (MDN)
Task: Build a simple front-end for a website of your choice (portfolio, to-do list app, blog, etc).
Topics:
- HTTP internals
- REST APIs
- Introduction to backend development
- CCNA
- OSI model
Resources:
- Network Fundamentals for Web Developers
- Cisco CCNA 200-301
- OSI Layers (Metwally Labs)
- What is a REST API?
- HTTP Internals (Zkrallah)
- HTTP (W3Schools)
- HTTP Messages (MDN)
Task:
1- Write a document explaining how a REST API works and how clients and servers communicate through HTTP.
2- Build a simple HTTP client program that performs GET, POST requests to some online fake API.
Note: Do not stop learning computer networking after this week. Computer networking is from the fundamentals of computer science, specially in backend.
Topics:
- Java syntax
- Basics of programming
- Variables
- Loops
- Conditionals
Resources:
- Java Basics Crash Course (FreeCodeCamp.org)
- Java Beginners (Playlist by Bro Code)
- Java Full Course (Bro Code)
- Java Full Course for Beginners (Mosh)
- Learn Java Programming From Scratch in Arabic (Adel Nasim)
- Java Tutorial for Beginners (Telusko)
- Java Basics (GeeksForGeeks)
- Java (W3Schools)
Task:
1- Write simple programs like calculating the sum of numbers or finding the largest number in an array.
2- Implement basic binary search in Java.
3- Try to solve some Leetcode easy questions using Java.
Bonus: Learn about Date Formatting.
Note: You should not know everything about Java for now, meaning that you don't have to watch those very long playlist to the end. Just get comfortable with the Java programming language.
Topics:
- Classes
- Objects
- Abstraction
- Inheritance
- polymorphism
- Encapsulation
Resources:
- Introduction to OOP (Mosh)
- Introduction to OOP (FreeCodeCamp.org)
- Java OOP (Caleb Curry)
- OOP in Java (Telusko)
- OOP in Java (Adel Nasim)
- Java OOP Concepts (GeeksforGeeks)
Task:
1- Create a basic student management system with classes for Student and Course.
2- Shapes Task
Bonus: Learn about Regex (Regular Expressions).
Note: Do not stop learning OOP after this week. OOP is from the fundamentals of computer science. You should be learning OOP all the time, specially in Java.
Topics:
- Maven/Gradle
- Basic file I/O
- Java collections
Resources:
- Spring Boot Build Tool Documentation
- Maven in 10 minutes
- Introduction to Maven
- Maven Tutorial (6:12~)
- Java Files (Coding With John)
- Java Collections
- Java Collections (Jakob Jenkov)
- Apache Maven Tutorial (Baeldung)
- Maven (GeeksForGeeks)
- Java Files (W3Schools)
- Java Collections (GeeksForGeeks)
- Java Collections Tutorial (GeeksForGeeks)
Task: Create a Java application to manage a library system using ArrayList.
Bonus: Learn about Java Generics and Callback functions.
Note: While it's okay to use either Maven or Gradle for both Java and Kotlin Spring Boot Projects, I recommend sticking with Maven as it's more easy to understand and work with than Gradle. Also it's more common to use Maven with Java projects and Gradle with Kotlin projects. Anyways, I recommend using Maven alawys (specially as long as you are a beginner).
Topics:
- Spring Boot overview and setup
- Basic annotations (@RestController, @GetMapping, @PostMapping)
- Spring MVC
Resources:
- Spring Documentation
- Spring Boot Documentation
- Building a RESTful Web Service
- What is Spring Boot? (Telusko)
- Spring Boot Tutorial (Amigoscode)
- The Ultimate Guide to Spring Boot (Devtiro)
- Spring Boot Tutorial Crash Course (Marco Codes)
- Spring Boot Tutorial (GeeksForGeeks)
Task: Create a simple REST API to manage books.
Bonus: Learn about MULTIPART requests.
Note: Dependency Injection, Spring JPA, and some concepts are mentioned in this tutorial but we will go through the details of them in later weeks.
Topics:
- What is a database?
- Introduction to SQL
- Introduction to PostgreSQL and MySQL Server
- Setting up the RDBMS
- Basic queries
Resources:
- Database Introduction (ByteByteGo)
- MySQL Tutorial 1 (Fireship)
- MySQL Tutorial 2 (NetworkChuck)
- PostgreSQL Tutorial (FreeCodeCamp.org)
- SQLZoo Interactive Quizes
- PostgreSQL Tutorials (Neon)
- Advanced SQL Tutorial (Mode Analytics)
Task:
1- Create a database for the book management system.
2- Try to solve some easy SQL questions on HackerRank or Leetcode.
Bonus: Learn about relationships and join statements.
Note: Do not stop learning database after this week. Database is from the the fundamentals of computer science, specially in backend.
Topics:
- Spring Data JPA ORM
- CRUD operations
- SQL and ORMs
Resources:
- Spring Boot Data Access Documentation
- Spring Data JPA Documentation
- Spring JPA Tutorial (Amigoscode)
Task: Enhance the book management system with a PostgreSQL database.
Bonus: Learn how to hot-reload a Spring Boot project.
Project: Build a Student Management System with REST APIs and PostgreSQL.
- Build a RESTful API for managing students.
- Implement the
Student
andCourse
entities. - Implement a one-to-many relationship between Students and Books.
- Implement a many-to-many relationship between Students and Courses (Bonus).
- Use Spring Boot with Spring Data JPA and PostgreSQL.
- Create a new student
POST /students
- Retrieve all students
GET /students
- Retrieve a student by ID
GET /students/{id}
- Update a student's details
PUT /students/{id}
- Delete a student
DELETE /students/{id}
- Same thing for books and courses.
- Assign a book to a student
POST /students/{studentId}/books/{bookId}
- Retrieve the student who owns a book
GET /books/{bookId}/owner
- Retrieve all books of a student
GET /students/{studentId}/books
- Remove a book from a student
DELETE /students/{studentId}/books/{bookId}
- Enroll a student in a course
POST /students/{studentId}/courses/{courseId}
- Retrieve all students in a course
GET /courses/{courseId}/students
- Retrieve all the courses of a student
GET /students/{studentId}/courses
- Remove a student from a course
DELETE /students/{studentId}/courses/{courseId}
Note: When a book or course is deleted, its association with any students should also be removed.
Focus:
- Spring Core concepts like IoC, DI, AOP, Resources, etc.
- Input validation, error handling, and testing (unit & integration).
- Middlewares and Spring Security.
- Pagination, filtering, Lombok, file uploads.
- Sending OTPs using SMTP servers and SMS.
- More about SQL databases and difference between JPA, Spring Data JPA, and Hibernate ORM.
- Introduction to NoSQL databases and MongoDB.
- Asynchronous programming, Reactive Spring Boot, Spring Data R2DBC, and Spring WebFlux.
- Caching mechanisms and Introduction to Redis cache.
- Real-time communication with WebSockets and streaming with WebRTC.
Topics:
- Inversion of Control & IoC Container
- Dependency Injection design pattern
- Beans and Bean lifecycle.
- Spring annotations (@Bean, @Component, @Configuration, etc)
Resources:
- Spring Core Documentation
- Spring IoC Documentation
- Dependency Injection (Yehia Tech)
- Spring Beans and DI (Maaike)
- Spring IoC & DI (Telusko)
- Dependency Injection in Spring Boot (Telusko)
- Autowire in Spring Boot (Telusko)
- Spring Configuration (Code Java)
- Introduction to Spring Framework (GeeksforGeeks)
Task: Apply what you understood to the Student Management System or revisit what you already did for dependency injection.
Bonus: Learn about Spring Profiles.
Topics:
- Input validation (@Valid, @NotNull, Optional<>)
- Custom exception handling (@ControllerAdvice)
- Global exception handling (@RestControllerAdvice, @ExceptionHandler)
Resources:
- Spring Exceptions Documentation
- Spring ControllerAdvice Documentation
- Spring Validation Documentation
- Spring Validation Form Input Documentation
- Java Exceptions (Coding With John)
- Validation in Spring Boot (Java Techie)
- Spring Exception Handling (CodeSnippet)
- Spring Input Validation (Fast & Simple Dev)
- Spring Validation (Baeldung)
- Spring Validation (GeeksforGeeks)
Task: Add validation to the Student Management System and create custom error messages for invalid inputs.
Bonus: Learn about CORS.
Topics:
- Unit testing with JUnit and Mockito
- Integration testing with testcontainers
- API documentation
- Swagger and Postman API
Resources:
- Spring Testing Documentation
- Spring Boot Testing Documentation
- Unit vs Int Testing Intro (Dan Vega)
- Spring Boot Unit Testing (Teddy)
- Spring Boot Testing (Amigoscode)
- Setup Swagger 2 in Spring Boot (KB Tutorials)
- Testing in Spring Boot (Baeldung)
Task: Write unit tests for services and controllers, and integration tests for the database layer.
Bonus: Learn about Postman API.
Topics:
- Spring Boot Filters
- Spring Boot Interceptors
- Lombok Annotations
- Pagination & Filtering Data
- Uploading a File with MULTIPART Requests
Resources:
- Spring Filters Documentation
- Spring Interceptors Documentation
- Spring Boot File Upload Documentation
- Spring Filter Series (Sergey Tech)
- Spring Boot Interceptors (CodeSnippet)
- Lombok Tutorial (Amigoscode)
- Spring Boot File Upload & Download (Java Techie)
- Spring Boot File Upload & Download (Telusko)
- Pagination in Spring Boot (Teddy)
- Pagination and Sorting in Spring Boot (Java Techie)
- How to Define a Spring Boot Filter (GeeksforGeeks)
- How to Define a Spring Boot Interceptor (GeeksforGeeks)
- Pagination and Sorting in Spring Data JPA (Baeldung)
- Spring Boot File Upload & Download (GeeksforGeeks)
Task:
1- Add logging feature to the students' management system using filters once and using interceptors once.
2- Add the pagination feature to the students' management system.
3- Add lombok annotations to the students' management system.
4- Create a simple Spring Boot application that allows users to upload files using multipart requests and stores them in the local file system (or database for learning purposes).
Bonus: Take a look on Firebase
and try to implement file upload & download feature using Firebase
instead of the above ways.
Note: In these resources, uploaded files are either stored in a database or saved as local files on the server. However, in most cases, this is not the best approach. Typically, uploaded files should be stored in a cloud service provider such as AWS
or Firebase
, while only the file URL is saved in the database. We will cover this in more detail during the Firebase
week.
Topics:
- Authentication vs Authorization
- Basic Authentication
- Session-based authentication
- Role-based access control
- CORS
Resources:
- Spring Security Documentation
- Spring Boot Security Documentation
- Authentication vs Authorization & Security Concepts (Java Brains)
- Spring Boot Basic Authentication (Lazy Programmer)
- Role-based Access Control (Lazy Programmer)
- Spring Security (Lazy Programmer) (start from end to start)
- Spring Security Basics (Java Brains)
- CORS in Spring (Telusko)
- session-based Authentication (Baeldung)
- Basic Authentication (Baeldung)
Task:
1- Implement basic authentication in your Spring Boot application.
- Use httpBasic() in your security configuration.
- Test the secured endpoints using Postman.
2- Implement session-based authentication.
- Configure formLogin() for session management.
- Use HttpSession to store user-specific data.
3- Configure role-based access control (e.g., allow only admins to delete resources).
4- Test the secured endpoints using Postman.
Bonus: Learn about REST Client in Spring Boot.
Note: I recommend the first part of Lazy Programmer's playlist for this week.
Topics:
- JWT (JSON Web Tokens)
- OAuth2
- Custom security configurations
Resources:
- Spring Security Documentation
- Spring Security OAuth2 Documentation
- Spring Boot Security Documentation
- Spring Security (Lazy Programmer) (start from end to start)
- Spring Security Basics (Java Brains)
- JWT & OAuth2 with Spring Security (Telusko)
- JWT Authentication (Baeldung)
Task:
1- Implement JWT-based authentication in your Spring Boot application.
- Generate and validate JWTs.
- Add a refresh token mechanism for token renewal.
2- Secure your REST APIs with role-based access using JWT.
3- Integrate OAuth2 with a provider like Google or GitHub.
4- Test the secured endpoints using Postman.
Bonus: Learn about Filters in Spring Boot.
Note: I recommend watching the second part of Lazy Programmer's playlist and Telusko's video for this week.
Topics:
- SMTP servers
- SMS messages
- OTPs (One Time Password)
Resources:
- Spring Email Documentation
- Spring Boot Email Documentation
- Send SMS in Your Spring Boot App Documentation
- Setup Gmail SMTP Server
- Sending E-mails in Spring Boot
- SMS via Twilio in Spring Boot (Amigoscode)
- Spring Email (Baeldung)
- Spring Email (GeeksForGeeks)
- Spring SMS with Twilio (GeeksForGeeks)
Task:
1- Configure a Gmail SMTP and write the email sending service.
2- Create a simple email verification service by sending an OTP to the given email.
Bonus: Learn about pagination.
Topics:
- Advanced SQL concepts
- Hibernate ORM
- Joins & relationships
- Aggregate functions
- Database Normalization
Resources:
- Hibernate Documentation
- Spring Hibernate Documentation
- Hibernate and JPA Tutorial (Marco)
- SQL Joins Animated + Practice (Anton)
- Learn SQL Joins (Decomplexify)
- Aggregate Functions in SQL (Bro Code)
- Aggregate Functions in SQL (Becoming a Data Scientist)
- Advanced Aggregate Functions in SQL (Becoming a Data Scientist)
- Database Normalization (Decomplexify)
- Advanced SQL Tutorial (Mode Analytics)
- SQL Aggregate Functions (W3Schools)
- SQLZoo Interactive Quizes
- SQL Joins (W3Schools)
- SQL Joins (GeeksForGeeks)
- Database Relationships (GeeksForGeeks)
- Aggregate Functions (W3Schools)
- Aggregate Functions (GeeksForGeeks)
- Database Normalization (GeeksForGeeks)
Task: Solve SQL problems on HackerRank or Leetcode.
Bonus: Learn how to design a database.
Note: It's important to understand the difference between JPA
, Hibernate
, and Spring Data JPA
. JPA
is a specification or an interface, Hibernate
is an implementation of this interface and an ORM, and Spring Data JPA
is a framework that relies on JPA
implementations like Hibernate
or any other implementation (but Hibernate
is the default one). While Spring Data JPA
is the most used option for ORMs and database interactions and that you will rarely need to do raw Hibernate
, it's good to understand what's happening under the hood. Do not get overwhelmed if you don't understand Hibernate
well for now, it has a complex learning curve, just do your best.
In this project, you will build the backend of an E-Commerce website using Spring Boot. The backend should expose REST APIs for managing users, products, orders, and authentication. You will also implement security features, including JWT authentication and email verification, and enhance the system with pagination, filtration, file uploads, input validation, and exception handling.
- Develop a RESTful API for an e-commerce platform.
- Implement user authentication and authorization using Spring Security & JWT.
- Implement email verification using SMTP.
- Support product pagination and filtering.
- Enable file uploads for product images.
- Implement input validation and exception handling.
- Write unit tests for key functionalities.
- Use Spring Data JPA with PostgreSQL.
- User (Can be a customer or admin)
- Product (Sold by the e-commerce platform)
- Category (Each product belongs to a category)
- Order (Contains multiple products)
- OrderItem (A product inside an order, with quantity and price)
- Cart (Each user has a shopping cart)
- Register a new user
POST /auth/register
- Verify email
GET /auth/verify-email?token={token}
- Log in
POST /auth/login
- Refresh JWT token
POST /auth/refresh-token
- Get the current user's profile
GET /users/me
- Update user details
PUT /users/{userId}
- Create a new product
POST /products
- Retrieve all products with pagination & filtering
GET /products?page={page}&size={size}&category={category}
- Retrieve a product by ID
GET /products/{productId}
- Update a product
PUT /products/{productId}
- Delete a product
DELETE /products/{productId}
- Upload product images
POST /products/{productId}/upload-image
- Create a new category
POST /categories
- Retrieve all categories
GET /categories
- Add a product to cart
POST /cart/{userId}/add/{productId}
- View cart items
GET /cart/{userId}
- Remove a product from cart
DELETE /cart/{userId}/remove/{productId}
- Place an order
POST /orders/{userId}/checkout
- Retrieve all orders of a user
GET /orders/{userId}
- Retrieve order details
GET /orders/{orderId}
Bonus: Create a simple front-end that uses your API.
Topics:
- Introduction to NoSQL Databases
- Spring Data MongoDB
- MongoDB
- Mongosh & MongoDBCompass
- Spring Data MongoDB
- Collections, Documents, CRUD operations
Resources:
- Getting Started with Spring Data MongoDB Documentation
- Getting started with MongoDB and Spring Boot Documentation
- Spring Data JPA Documentation
- Install MongoDB & mongosh on Windows (Amit Thinks)
- Complete MongoDB Tutorial (The Net Ninja)
- Switch to NoSQL, move FASTER (Devtiro)
- MongoDB in 1 Hour (Bro Code)
- MongoDB in 30 Minutes (Web Deve Simplified)
- MongoDB in Spring Boot Low-Level Tutorial (Telusko)
- MongoDB in Spring Boot Tutorial (Amigoscode) (26:23~)
- MongoDB in Spring Boot Tutorial (Programming Techie) (~15:00)
Task:
1- Build a simple CRUD application of your choice (task manager, profile manager, books manager, etc) with Spring Data MongoDB.
2- Implement pagination and sorting in MongoDB queries.
3- Implement a search feature using MongoDB’s text indexes.
Bonus: Learn about filtering data.
Note: Spring Data MongoDB
is so close to Spring Data JPA
, if you are good with Spring Data JPA
, this week would be easy for you.
Topics:
- Blocking vs Non-blocking Programming
- Reactive Programming
- Parallelism vs Concurrency
- Threads and Threading
- CompletableFuture in Java
- @Async & @EnableAsync Annotations in Spring Boot
Resources:
- Creating Asynchronous Methods in Spring Boot Documentation
- Blocking vs Non-blocking Programming (Zkrallah)
- A Theoretical Guide to Java CompletableFuture (Geekific)
- Java CompletableFuture (Lemubit)
- CompletableFuture in Java Part I (Tech Recipes)
- CompletableFuture in Java Part II (Tech Recipes)
- @Async & @EnableAsync in Spring Boot (Java Techie) (recommended)
- @Async & @EnableAsync in Spring Boot (Java Techie) (older but good version)
- CompletableFuture Guide (GeeksforGeeks)
- Parallelism vs Concurrency (GeeksforGeeks)
- CompletableFuture Guide (Baeldung)
- How To Do @Async in Spring (Baeldung)
Task:
1- Create a method that performs a long-running task asynchronously using CompletableFuture.
- Apply what you have learned using
runAsync
andsupplyAsync
. - Apply what you have learned using
thenAccept
,thenApply
, andthenRun
. - Run multiple CompletableFuture tasks in parallel and combine their results.
2- Implement a Spring Boot service with an @Async annotated method.
3- Redo the above task but this time configure a custom thread pool executor.
Bonus: Learn about Java Virtual Threads (please note that this is an advanced topic, just take a quick look).
Topics:
- Introduction to Spring WebFlux
- Non-blocking Code in Spring Boot
- Mono & Flux
- Spring WebFlux Annotation-based programming model
- Spring WebFlux Functional programming model
- Introduction to Spring Data R2DBC
Resources:
- Web on Reactive Stack Documentation
- Spring WebFlux Documentation
- Spring WebFlux Annotation-based Model Documentation
- Spring WebFlux Functional Model Documentation
- Spring Data R2DBC Documentation
- What is Spring WebFlux and When to Use It? (Defog)
- Spring WebFlux (Code With Dilip)
- Spring WebFlux (Java Techie)
- Spring Boot WebFlux CRUD Tutorial with R2DBC (Genka)
- Spring Boot WebFlux CRUD Tutorial with R2DBC (Bouali)
- Spring WebFlux Guide (Baeldung)
- Basic Introduction to Spring WebFlux (GeeksforGeeks)
Task:
1- Create a Spring WebFlux REST API:
- Set up a Spring Boot project with WebFlux.
- Create a simple reactive endpoint that returns a Mono and a Flux.
- Test the API using Postman.
2- Implement a Reactive CRUD API with WebFlux:
- Create a Product entity and a corresponding ProductController.
- Implement CRUD operations using Mono and Flux.
- Use a reactive database (PostgreSQL + R2DBC for example).
3- Spring WebFlux Functional API:
- Implement the same CRUD API using the functional programming model (instead of the annotation-based approach).
4- Create a Spring MVC REST API:
- Recreate the REST API you did in the first task using Spring MVC instead of Spring WebFlux.
- Add logs in both projects.
- Observe the thread names handling each request.
Bonus:
- Learn how to integrate Spring Security with WebFlux (
SecurityWebFilterChain
). - Explore
WebClient
as a non-blocking alternative toRestTemplate
.
Note:
- WebFlux is not always better than Spring MVC. It’s optimized for high-concurrency and real-time streaming applications.
- Use Spring WebFlux when you need to handle thousands of concurrent requests with minimal resource usage.
- If your project does not require reactive programming, sticking with Spring MVC might be a better choice.
- Spring WebFlux is a big topic, don't get overwhelmed, learn as much as you can and revisit later.
- Try to map what you've learned so far to WebFlux and explore alternative approaches for future topics to be applicable to Spring WebFlux.
Topics:
- What is caching?
- Caching in Spring Boot
- Redis cache
- Spring Data Redis
- @EnableCaching, @Cacheable, @CacheEvict, and @CachePut annotations
- Jedis and RedisTemplate
Resources:
- Spring Boot Caching Documentation
- Spring Data Redis Documentation
- Spring Redis Documentation
- Spring Data Reactive Redis Guide Documentation
- Caching Simply Explained (Simply Explained)
- How Does Caching Work on the Backend (Software Developer Diaries)
- Spring Data Redis in Spring Boot (Developer Hut)
- Redis in Spring Boot Low-Level Tutorial (Java Codeex)
- Spring Data Redis Part I (Java Techie)
- Spring Data Redis Part II (Java Techie)
- Spring Data Redis (Java Codeex)
- Spring Data Redis Tutorial (Baeldung)
- Spring Data Redis Tutorial (GeeksforGeeks)
Task:
1- Install and run a Redis server locally.
2- Integrate Redis into a Spring Boot Application:
- Create a service class with methods that fetch data (e.g., from a database or an external API).
- Annotate methods with @Cacheable to cache their results.
- Use @CacheEvict and @CachePut annotations where appropriate to manage cache entries.
Bonus: Learn about Spring Data Reactive Redis.
Note: I highly recommend reading the final two articles in the resources of this week as well as the guide documentation.
Topics:
- Raw Sockets, WebSocket, and Socket.IO
- Real-time communication
- Introduction to WebRTC
- ZegoCloud SDK
- Socket.io in Spring Boot
- SockJS & STOMP in Spring Boot
Resources:
- Raw Socket Programming Simplest Chat Service (Zkrallah)
- Socket.io Documentation
- Socket.io Wiki Documentation
- Using WebSocket to Build an Interactive Web Application Documentation
- WebSockets Tutorial with Socket.IO (FreeCodeCamp.org)
- WebSocket Tutorial with Spring Boot (Bouali)
- How Does WebRTC Work? (heyletscode)
- WebRTC in 100 Seconds and Beyond (Fireship)
- Building a Full Video Call App with ZegoCloud (Bouali)
- WebRTC Crash Course in JavaScipt (Hussein Nasser)
- Spring Boot Netty Socket.IO Example (medium)
- Spring Boot - Web Socket (GeeksforGeeks)
- WebRTC API (MDN)
- Guide to WebRTC (Baeldung)
- Introduction to WebRTC (GeeksforGeeks)
Task:
1- Implement a Real-Time Chat Application:
- Set up a Spring Boot project.
- Integrate Socket.IO to handle real-time communication.
- Create a simple chat interface where multiple users can send and receive messages instantly.
- Test the application with a basic front-end or using postman to ensure messages are transmitted in real-time.
2- Explore WebRTC Basics:
- Understand the fundamentals of WebRTC and its use cases.
- Set up a basic peer-to-peer connection between two clients using WebRTC.
- Transmit simple data (e.g., text messages) between the peers.
Bonus: Learn a little about message queues.
Note:
- In most chat services, a cloud messaging service is used to initiate the socket connection programmatically when the receiver is inactive at the moment the sender sends a message. We will discuss cloud messaging services in detail later in the
Firebase
week in the advanced level. - There aren’t many good resources on implementing
WebRTC
in Spring Boot without usingZegoCloud
, so feel free to use your preferred LLM or external resources to learn this part. If you find any useful implementations, consider contributing them to the roadmap. - Many open-source WebSocket implementations are available, with
Socket.io
being the most common. However, some companies use alternatives likePusher
orSTOMP
. For brevity, this week’s resources focus onSocket.io
, but it’s good to be aware of other implementations you might encounter in different environments.
In this project, you will build a real-time chat application using Spring WebFlux and MongoDB. The application will support private messaging between users, real-time communication using WebSockets (Socket.IO), and persistent chat history storage in MongoDB.
- Develop a fully reactive backend using Spring WebFlux.
- Use MongoDB as a NoSQL database for storing users, messages, and conversations.
- Implement WebSockets for real-time messaging.
- Implement user authentication and authorization using Spring Security & JWT.
- Implement email verification using SMTP.
- Provide REST APIs for user management and chat history retrieval.
- Implement input validation and exception handling.
- Write unit tests for key functionalities.
id
,username
,email
,password
,profilePicture
,status (online/offline)
.- Users can send and receive messages.
- Email verification required before accessing chat.
- Feel free to add any additional fields.
id
,senderId
,receiverId
,content
,timestamp
.- Messages are stored persistently in MongoDB.
- Feel free to add any additional fields.
id
,participants[]
,lastMessage
,lastUpdated
.- Stores user chat sessions for easy retrieval.
- Feel free to add any additional fields.
- Register a new user →
POST /users/register
- Verify email →
GET /users/verify?token={token}
- Login a user →
POST /users/login
- Update user profile →
PUT /users/{userId}
- Get user details →
GET /users/{userId}
- Add any missing endpoints.
- Retrieve chat history with a user →
GET /chats/{userId}
- Delete a conversation →
DELETE /chats/{userId}
- Add any missing endpoints.
- Connect to the chat →
WS /chat/connect
(JWT authentication required) - Send a message →
WS /chat/send
- Receive a message →
WS /chat/receive
- Typing indicator →
WS /chat/typing
- Mark message as read →
WS /chat/status
- Add any missing endpoints.
Focus:
- Introduction to payment Gateways.
- Firebase RTDB, Cloud Messaging, cloud Storage, Firestore, Authentication, and more.
- More SQL and NoSQL and introduction to JDBC and more about R2DBC.
- GraphQL and task scheduling.
- Introduction to Deployment and Docker.
- Introduction to Message queues.
- Introduction to Microservices architecture.
Topics:
- Payments in Spring Boot
- Stripe payment gateway
- Paypal payment
Resources:
- Stripe Official Documentation
- Stripe Payment Gateway Integration with Spring Boot (Java Techie)
- PayPal Integration with Spring Boot (Bouali)
Task:
1- Set up a Stripe account and create API keys.
2- Integrate Stripe in a Spring Boot application to process payments.
3- Implement an endpoint for handling one-time payments.
Bonus: Learn about other payment gateways and SDKs like Fawry or Paymob for example.
Note: Stripe is one of the most widely used payment gateways, but it's not the only option available. Companies can choose any payment gateway that best suits their needs. This week focuses specifically on Stripe due to its popularity and extensive documentation. Feel free to learn more about other payment gateways.
Topics:
- Graphql vs REST
- Graphql in Spring Boot
- GraphQL schemas, queries, and mutations
Resources:
- Spring for GraphQL Documentation
- Spring Boot for GraphQL Documentation
- Building a GraphQL Service Documentation
- Observing GraphQL in action Documentation
- What Is GraphQL? REST vs. GraphQL (ByteByteGo)
- GraphQL Explained in 100 Seconds (Fireship)
- Introduction to Spring GraphQL with Spring Boot (Spring Academy)
- Spring Boot and GraphQL Tutorial (Amigoscode)
- Mastering GraphQL & Spring Boot APIs (Java Techie)
- Master Graphql with Spring Boot (Daily Code Buffer)
- Spring Boot GraphQL Tutorial (Dan Vega)
- GraphQL Spring Boot (Microservices Lab)
- Getting Started with GraphQL (Baeldung)
- Integrate and Call a GraphQL API in a Spring Boot (GeeksforGeeks)
Task:
- Set up a GraphQL server using Spring Boot and Spring GraphQL.
- Define GraphQL schemas for a simple application (Users and Posts for example).
- Implement queries to fetch data and mutations to modify data.
- Integrate Spring Data JPA to fetch data from a relational database.
- Implement error handling for invalid requests.
- Test GraphQL APIs using GraphiQL or Postman.
Bonus: Learn how to avoid the N + 1
problem in Graphql and relational databases.
Note:
- I recommend watching Spring Academy's, Amigoscode's, and Java Techie's videos for integrating Graphql in Spring Boot.
- Most of the video resources mentioned above apply on the same example but each video might introduce a new idea or tool that might not have been mentioned in the the other videos.
Topics:
- Firebase as a BAAS.
- Firebase Cloud Messaging (FCM)
- Firebase Cloud Storage
- Firebase Authentication
- Firebase Firestore
- Firebase Real-Time Database (RTDB)
Resources:
- Firebase Cloud Messaging Documentation
- Firebase Cloud Storage Documentation
- Firebase Authentication Documentation
- Firebase Cloud Firestore Documentation
- Firebase Real-Time Database Documentation
- Firebase in 100 Seconds (Fireship)
- Spring Boot Firebase Notifications with FCM (Ulter)
- Spring Boot CRUD operations (TheCodeStorm)
- Ultimate Guide to Firebase Storage Integration (IOCODES)
- Connect Spring Boot REST API with Firebase (Techno Town Techie)
- Spring Boot CRUD Application (ProgrammingKnowledge)
- File uploading with Spring Boot & FCM (medium)
Task:
1- Modify the file uploading service you created before or create a new one that uses Firebase Storage instead of local storage.
2- Create a Firebase Cloud Messaging (FCM) service that sends push notifications tozz users.
3- Use Firebase Firebase or Firebase RTDB as a database in a simple CRUD application.
Bonus: Explore other Backend-as-a-Service (BaaS) providers like Supabase and compare them with Firebase. Additionally, check out alternative cloud service providers to understand their offerings.
Note:
- I recommend reading the Medium article on Firebase Storage for the file uploading service.
- Ulter's video provides a great guide on setting up Firebase FCM for push notifications.
- There aren't many video resources for Firebase RTDB, so rely on the official documentation or explore other resources online.
Topics:
- Task Scheduling
- @Scheduled and @EnableScheduling annotations
- cron
- Fixed-rate vs. fixed-delay scheduling
- Handling asynchronous scheduled tasks
Resources:
- Spring Task Scheduling Documentation
- Spring Scheduling Tasks Documentation
- Spring Boot Quartz Scheduler Documentation
- Automate Like a PRO: How to Use Scheduled in Spring Boot (Devtiro)
- Spring Boot Scheduler (Techno Town Techie)
- The @Scheduled Annotation in Spring (Baeldung)
Task:
1- Implement a basic scheduled task that runs every 10 seconds using @Scheduled.
2- Modify the task to use a cron expression to execute at a specific time of day.
3- Create a dynamic scheduling system, where tasks can be enabled/disabled based on application settings.
4- Implement an asynchronous scheduled task using @Async.
Bonus: Learn about the Decorator Design Pattern.
Note: If your application requires more control, consider Quartz Scheduler, which supports distributed job scheduling.
Topics:
- JDBC
- Spring Data JDBC
- Spring Data R2DBC
- SQL database
- Database migrations
- Transactions
- Triggers and Indexes
Resources:
- Spring Data JDBC Documentation
- Spring JDBC Documentation
- Spring Data Access with R2DBC Documentation
- Spring Boot SQL Databases Documentation
- Java Database Connectivity | JDBC (Telusko)
- Spring Boot JDBC using JdbcTemplate (Telusko)
- JDBC Client and Spring Data JDBC (Dan Vega)
- Spring Data JDBC Tutorial (Dan Vega)
- Database Migrations with Flyway in Spring Boot (Devtiro)
- Database Transactions in Spring Boot (Devtiro)
- Spring JDBC (Baeldung)
- Spring – JDBC Template (GeeksforGeeks)
- Defining Indexes in JPA (Baeldung)
Task:
1- Implement CRUD Operations using Spring JDBC (JdbcTemplate).
2- Create one or two database migrations to an old database using Flyway.
3- Solve More SQL questions on Leetcode and HackerRank.
Bonus: Learn about recursive queries and window functions in SQL.
Note:
- The "Java Database Connectivity | JDBC (Telusko)" video is for pure JDBC without Spring Boot. It helps to understand JDBC fundamentals.
- You will need to use JDBC instead of Spring Data JPA in some cases like: avoiding ORM overhead for high-performance applications, using raw SQL queries efficiently without automatic entity mapping (very useful in microservices), and when working with legacy databases that don’t fit well into JPA’s entity model
Topics:
- Advanced MongoDB queries (aggregation, indexing, transactions)
- Performance optimization with MongoDB
- Advanced Spring Data MongoDB features (custom queries, projections, auditing)
Resources:
- Getting Started with Spring Data MongoDB Documentation
- Getting started with MongoDB and Spring Boot Documentation
- Spring Data JPA Documentation
- MongoDB Documentation
- MongoDB in 1 Hour (Bro Code)
- MongoDB in 30 Minutes (Web Deve Simplified)
- MongoDB in Spring Boot Low-Level Tutorial (Telusko)
- MongoDB in Spring Boot Tutorial (Amigoscode) (26:23~)
- MongoDB in Spring Boot Tutorial (Programming Techie) (~15:00)
- Switch to NoSQL, move FASTER (Devtiro)
Task:
1- Create a MongoDB-backed Spring Boot application using Spring Data MongoDB.
2- Implement advanced CRUD operations with support for:
- Custom queries using @Query
- Pagination and Sorting
- Transactions
- Indexes
2- Use the Aggregation Framework to build advanced reporting queries (e.g. total sales per day, top products, etc.)
3- Add indexes for optimal query performance (e.g. on email, creation date).
Bonus: Explore other NoSQL databases like Cassandra, Redis, and CouchDB.
Topics:
- Virtualization vs Containarization
- Docker and Docker Compose
- Deployment
Resources:
- Docker Documentation
- Docker in 100 Seconds (Fireship)
- Docker Containers 101 (NetworkChuck)
- 18 Weird and Wonderful ways I use Docker (NetworkChuck)
- Docker and Kubernetes (Big Data)
- Intro to Docker (Typcraft)
- Docker Tutorial for Beginners (Fireship)
- Docker Tutorial for Beginners (Mosh)
- Docker Containers and Kubernetes Fundamentals (FreeCodeCamp.org)
Task:
1- Install Docker and Docker Compose on your system.
2- Pull and run basic images like ubuntu
, postgresql
, and mysql
.
3- Create your own Dockerfile for a small web server.
4- Use Docker Compose to spin up a multi-container app.
5- Explore common docker
CLI commands: ps
, images
, logs
, exec
, etc.
6- Write a document containing what you have learned about docker.
Bonus: Learn about Kubernetes.
Note: Docker is one of the most essential tools for modern backend developers. Understanding images, containers, and orchestration tools like Docker Compose is crucial for building scalable, portable applications.
Topics:
Resources:
Bonus:
Note: