Conteúdo do Curso
Spring Boot Backend
Spring Boot Backend
Introduction to Spring
Now we've arrived at the most exciting part - Spring Framework, which we will be using throughout the entire course. That's why it's crucial to complete this section thoroughly and study it well!
What is Spring?
At its core, the Spring Framework is essentially a dependency injection container with several convenient layers (such as database access, proxies, and MVC web infrastructure). All of this allows you to develop Java applications more quickly and efficiently.
Note
The main goal of the Spring Framework is to simplify application development by providing an infrastructure that makes complex tasks easier.
Bean to Spring
We'll cover the topic of beans at the very beginning of this section because it's extremely important.
To make a object a bean so that Spring can manage its lifecycle, we can annotate it with @Component
, @Service
, @Repository
, @Controller
(we will look at these annotations later)
Note
You'll see how simple this process is and the advantages it offers for future development.
What Are the Main Modules and Their Responsibilities?
Spring Core
is the central component of the framework, encompassing the core Spring and the IoC (Inversion of Control) container.
Spring Security
ensures the security of applications. It provides tools for authentication (verifying user identity) and authorization (determining user permissions to perform certain actions).
Spring MVC
(Model-View-Controller) is used for building web applications based on the MVC pattern. This module makes it easy to handle HTTP requests and manage the interaction between the view, controller, and model.
Spring Data
is a module that provides simplified access to databases and repositories. It offers a unified way to work with various data sources (such as SQL, NoSQL, in-memory databases).
What is Spring Boot?
Key Difference: Spring offers the core functionality and flexibility for building applications, whereas Spring Boot simplifies this process by providing automatic configuration and minimal configuration requirements.
That’s why we will be using Spring Boot throughout the course, as it is much easier to set up.
Tudo estava claro?