
Learn how to design Spring Boot microservices with JPA persistence, implement REST microservices, secure them with JWT authentication, and build a single-page application using AJAX and JavaScript.
Compare monolithic and microservice architectures by splitting into dedicated customer, product, and order services for independent deployment with multiple technologies, aligned to the single responsibility principle.
Compare war and fat jar deployments for Spring Boot, detailing war archives with deployment descriptor and container hosting, versus fat jars with embedded servers powering two major services on ports.
Explore how Spring implements dependency injection, contrast constructor-based instantiation with Autowired, and use POJO, configuration, and component annotations like Controller, Service, and Repository to manage objects.
Learn the model-view-controller pattern in Spring Boot microservices, detailing the model with data classes and user entities, the controller handling requests, and json responses serialized by Jackson.
Explore how HTTP requests flow between client and server, including methods like GET and POST, and how cookies and JSON Web Tokens manage authentication across requests.
Learn how to use Maven to manage dependencies, compile code, run tests, and produce artifacts for Spring Boot microservices with JPA.
Explore how to bootstrap a Spring Boot microservice project with Spring Initializr, select dependencies, generate, open, and run the app to see it on a local port.
Create new packages for a spring boot microservice, including controllers, services, and utilities, and define the first pojo user entity with Lombok-generated constructors and fields.
Define an in-memory user entity mapped to a database table using JPA annotations, including email and name columns, with email constrained as unique, within a Spring Boot microservices context.
Apply JSR-303 validation to spring boot jpa pojo mapped to the users table, ensuring email, name, and password are present and valid during data binding.
Create a second JPA POJO entity with six attributes, including an id with generated value, a description, priority, and a user foreign key, plus constructors, getters, and setters.
Create a dao interface for the first pojo to access and manage user data with jpa, defining methods to save, find by email, and query annotations.
Create the dao interface for the second pojo and implement standard jpa repository methods, including finding a user by email, while focusing on the naming strategy to generate queries.
Develop an EncryptionUtils class to encrypt passwords before storing them. Implement encrypt and streamEncrypted methods using a secret key and wire it into Spring for encryption before database insertion.
Learn to implement CommandLineRunner in a Spring Boot app to populate the database at startup, using in-memory options and Spring-wired dependencies.
Seed the H2 database at startup by creating users and todos with encrypted passwords, using a JPA repository, auto-generated IDs, and non-null fields.
Fill the H2 database by creating and persisting users with encrypted passwords. Leverage Spring components to inject and save user data.
Run the spring boot app as Tomcat starts, connects to the H2 database, and logs inserted data; then apply data binding validation and add a controller to save a user.
Develop a Spring Framework validator by implementing the Validator interface, validate an object with a priority field (high or low), and use it concretely in a Spring Boot microservice context.
Create a Spring controller to manage http requests and return responses. Configure the view resolver bean to map string results from controller methods to views or pages.
Create a Spring Boot REST controller that returns a Java object representing a user, demonstrating how to fetch a user via the API.
Expose a REST controller that returns a user POJO with email, name, and password serialized as JSON using Jackson, enabling direct, type-safe responses.
Explore simple data binding in Spring Boot microservices by binding HTTP request data to objects via a controller, testing with Postman, and noting upcoming validation with Spring validator.
Explore how to bind data using JSR-303 validation in Spring Boot microservices with JPA, applying validation annotations to fields like description and priority, and handling validation error messages.
Learn how to bind data using jsr-303 validation and BindingResult in Spring Boot, handle validation errors, customize messages, and manage error display in forms.
Implement Spring validators in a data binding workflow within Spring Boot microservices, use binding result to handle errors, and manage priority settings (high or low) during validation.
Explore data binding with JSR-303 and Spring validation, handle binding results, and manage error messages using validators to ensure server-side validation and user feedback.
Learn to craft http responses in Spring Boot microservices with JPA using ResponseEntity to control status, headers, and a defined response body for lists, single items, or errors.
Explore the JsonResponseBody class and learn to map Java objects to JSON with Jackson, build a response body, and return it with ResponseEntity in Spring Boot microservices.
Learn to implement a JWT utility in Spring Boot microservices: add the library, build a utility class, and generate, validate, and extract JWTs from HTTP requests.
Define and throw custom exceptions in Spring Boot microservices with JPA, including a user not found in database and a login required exception, with constructors passing messages to the superclass.
Explore a layered spring boot microservices structure with a controller, service, and data access layers using an H2 database. Implement a centralized exception propagation and logging strategy.
Define the login service interface and implement user retrieval from the database, returning an optional user and throwing exceptions for not-found cases. Enable jwt authentication in a spring boot microservice.
Implement the login service methods using Spring Boot and JPA, handling user lookup with Optional, validating encrypted password, and throwing exceptions on invalid emails or passwords.
Implement the remaining login service methods, validate and generate JWTs from requests, and handle missing or invalid tokens with try-catch or exception propagation in Spring Boot with JPA.
Implement a to-do service for a user, handling email-based identification and saving tasks. Continue building the API repository and implement the rest of the service.
Implement a RestController that handles login requests by reading email and password, delegates to a login service, and returns success or failure messages with exception handling and wired interfaces.
Implement rest controller logic to fetch a user by request parameters, validate credentials, construct a json response body, and return appropriate http statuses with a dedicated response model.
Implement rest controller in spring boot microservices with jpa, handling request and response, validating user data, using try-catch for exceptions, logging, and returning success or error messages.
Continue implementing the RestController by validating JWTs in the header, extracting user email from user data, and returning a JSON response while handling bad requests and expired token exceptions.
Implement a RestController method to create a new to-do, validate input with binding results, and return appropriate success or error responses with HTTP status.
Continue implementing the rest controller by validating a present, non-expired token, returning an integer status in the response, and saving relevant data to the database.
Implement the RestController method, defining success and failure messages and returning a JSON response with proper status codes. Log requests, manage exceptions, and validate the request flow.
Test a Spring Boot microservice with Postman by sending post requests for login, validating responses, and performing create, read, and delete operations against the database.
Develop the statistics microservice in the Spring Boot Microservices with JPA course, set up an in-memory database, and define a latest statistics table to persist priority data.
Create a MySQL database and a Spring Boot microservice, set up a web interface, define a table with an auto-increment primary key, and generate a JPA initializer.
Adjust the pom.xml to pin a specific library version and update application.properties for JPA, illustrating how spring boot microservices leverage java to modify the database structure.
Create the package structure for the project, then define a new JPA entity that maps to the corresponding database table as a POJO.
Learn to map a pojo to a database table by aligning description, date, and email fields with columns, and configure persistence and entity behavior in spring boot jpa microservices.
define a StatisticsDao interface that extends the JPA repository, crafting a query to fetch the last 10 items by a user's email using Spring.
Learn to build a JSON response body in a Spring Boot microservice, implement a statistics service, and pass through request headers to return a structured server response.
Explore how the statistics service in a Spring Boot microservices architecture uses JWT in headers, calls to other microservices, and data transformation to calculate and persist statistics.
Learn how to use RestTemplate to send HTTP requests in Spring Boot microservices with JPA, handling headers, streams, and responses.
Implement the statistics service in a Spring Boot microservices context, focusing on get statistics, managing priority levels (low and high), and updating counters for display on the screen.
Implement statistics service part 2 using Spring Boot with JPA, persisting statistics to the database, calculating metrics like crime rate, and emailing results.
Implement the controller to handle a name and email request, returning a response, and delegating to a service. Create a loosely coupled flow by wiring service calls and JWT.
Test spring boot microservices with postman by ensuring the MySQL database runs, sending requests with get and post methods, and passing the JWT in the request body.
Learn how microservices communicate, test with Postman, and build a small single-page interface using JavaScript libraries, guided by core resources and documentation.
Explain the html structure for a login and todo management interface, including sign in, sign out, a todo creation form, and tables for todos and statistics controlled by javascript.
Explain how the JavaScript structure handles login via JWT cookies, uses AJAX calls in a single page application, and updates tables and forms on success or error.
Test how a page works within a Spring Boot microservice, navigate resources, assemble the page into the service, and validate statistics via the controller to enable cross-origin requests.
Improve a Spring Boot microservices interface by separating JavaScript from the cms, creating a dedicated JavaScript folder, adding actions.js, fixing bugs, and retesting the page and database updates.
Conclude the course by building Spring Boot microservices with JPA that interact via REST controllers and connect a single-page application.
This course is a practical course which explains how to realise a microservice infrastructure in order to realise a full-stack web application composed by a "framework-less" Single Page Application and two restful Spring Boot microservices interacting with each other and with two different databases thanks to the implementation of the JPA (Java Persistence Api).
You'll have the basis to generate fastly a microservice infrastructure, to organise your application using different layers according to the "SOLID" principle and following the MVC pattern.
You will have the instrument to organise your communication protocols using simple and effective rules, to implement restful web services which communicate with Json Messages.
This is course has the same topic of the italian course Sviluppo Web a Microservizi con Java Spring Boot e Ajax" so it can easily considered as its English version. The example developed is different but with the same topics: microservices, Spring Boot, JPA and Rest calls.