English | MP4 | AVC 1280×720 | AAC 44KHz 2ch | 38.5 Hours | 17.1 GB
Learn to Master Spring Boot Microservices with Spring Cloud and Docker
Microservices are all the buzz in the industry right now.
Building a microservice is not just a matter of using RESTFul APIs.
Microservices are much MUCH more than that.
In this course you will learn that Microservices are an architectural style. The allow companies to achieve massive scale while maintaining a high degree of flexibility.
This course goes beyond simple RESTful APIs and explores microservices as an architectural style.
Traditionally, large enterprise class applications were developed as large monolithic applications.
The Spring Framework started as an alternative to J2EE (now JEE) for building these large monolithic enterprise applications.
As the industry evolved to favor microservices over monoliths, the Spring Framework and Spring Boot evolved also.
The Spring Framework gives you a battle-tested enterprise grade framework for building applications.
Spring Boot and Spring Cloud are tools specifically for the development of microservices using the Spring Framework.
Microservices present a unique set of challenges over monoliths. Spring Boot and Spring Cloud help you overcome these changes.
What are these challenges that microservices have, which traditional monoliths do not?
Is it okay for microservices to share databases?
How do you coordinate business logic across a series of microservices?
How do you manage transactions across serval microservices with different databases?
To explain these questions, in this course you get to explore a traditional Spring Boot monolith type of application. (Along the style of Spring Pet Clinic).
We will then re-create this monolithic application using a set of microservices.
You get to see, step by step how to build 3 different microservices.
Microservices are much more than just having a set of RESTFul APIs. Microservices frequently use asynchronous messaging systems, which is fully covered.
While the Spring Framework and Spring Boot are the tools you use to construct Microservices, Spring Cloud provides the tools to deploy microservices.
You get to see the latest tools in Spring Cloud for deploying Spring Boot Microservices into a distributed (or cloud) environment.
In 2018, Netflix announced several core projects to Spring Cloud were entering maintenance mode. Meaning no new development would be done on these projects.
Thus, in December of 2018, the Spring Cloud Team recommended several key replacements:
Previous Replacement
Hystrix –> Resliience4J
Ribbon –> Spring Cloud Load Balancer
Zuul 1 –> Spring Cloud Gateway
Archaius 1 –> Spring Cloud Config
Therefore, the recommend replacements are covered in this course.
Covered in this Course
In this course you will learn:
- Develop RESTful Services using Spring MVC
- Consume RESTFul Services with Spring RestTemplate
- How to use Project Lombok
- How to use MapStruct
- Spring Data JPA with Hibernate
- Configuration of Spring Boot for MySQL and H2
- How to use and configure Jackson for processing JSON with Spring Boot
- Data validation with Spring Boot and Hibernate Validator
- Documentation and testing of Spring Boot microservices using Spring RESTdocs
- Standardizing dependencies using Apache Maven
- Spring Application Events
- Using JMS Messaging using Apache ActiveMQ Artemis
- The microservice Saga Pattern
- How to use Spring State Machine for coordinating Sagas
- Integration Testing using Spring Boot and JUnit 5
- Using WireMock with JUnit 5
- How to use Awaitily in your Integration Tests
- The API Gateway pattern using Spring Cloud Gateway
- Load Balanced Routes using Netflix Ribbon / Spring Cloud Loadbalancer
- Service Registration using Netflix Eureka
- Service Discovery with Netflix Eureka
- Service Discovery using Spring Cloud OpenFeign
- Circuit Breaker Pattern using Reslience4J and Hystrix / Spring Cloud OpenFeign
- Manage configuration with Spring Cloud Config
- Distributed tracing with Spring Cloud Sleuth and Zipkin
- Securing Spring Cloud with Spring Security
- Use Docker to create images for your Spring Boot applications
- Push your Docker Images to Docker Hub
- Configure Logback with Logstash for JSON logging output
- Using Docker Compose to start and stop your microservices
- Use ELK stack (Elasticsearch, Logstash, Kibana) for consolidated Logging
- Provision virtual machines in the cloud for Eureka, Apache ActiveMQ Artemis, Spring Cloud Config, Zipkin, Elasticsearch, and Kibana.
- Provision MySQL databases using Digital Ocean.
- Create Docker Droplets (aka Virtual Machines) in Digital Ocean
- Deploy Spring Cloud Config in the the cloud with Eureka
- Create a Docker Swarm Cluster for Spring Boot Microservices
Table of Contents
Spring Boot Microservices Introduction
1 Welcome to Spring Boot Microservices!
2 What you will build in the Spring Boot Microservices Course
3 Getting the Most out of this Course
4 Setting up your Development Environment
5 Slack Group for Spring Boot Microservices with Spring Cloud B2G
6 Is your IDE Free Like A Puppy
7 Free 120 Day IntelliJ IDEA Trial!
Introduction to Microservices
8 Introduction to Intro to Microservices Section
9 The Traditional Monolith Application
10 What are Microservices
11 What is the Cloud
12 Adopting Microservices in Your Organization
13 Microservice Architecture and Design
14 Factor Applications
15 Introduction to Microservices Conclusion
Introduction to Restful Web Services
16 Introduction
17 HTTP Protocol
18 HTTP Request Methods
19 Beginners Guide to REST
20 Richardson Maturity Model
21 Spring Framework and RESTFul Services
22 Conclusion
Spring MVC Rest Services
23 Introduction
24 Spring Boot Development Tools
25 HTTP PUT with Spring MVC
26 Spring MVC @RequestBody Annotation
27 HTTP DELETE with Spring MVC
28 Assignment – HTTP Operations with Spring MVC
29 Assignment Review
30 API Versioning
31 API Versioning Example
32 API Versioning and Source Control
33 Introducing SFG Beer Works
34 LC Beer Service – Initial Spring Boot Project Creation
35 LC Beer Service – Data Model
36 LC Beer Service – Beer Controller
37 LC Beer Service – JUnit 5 Controller Tests
38 Conclusion to Spring MVC Rest Services
39 HTTP GET with Spring MVC
40 Introduction to Postman
41 Axis TCPMon
42 Assignment – Create GET Endpoint with Spring MVC
43 Assignment Review
44 HTTP POST with SpringMVC
Spring Boot RestTemplate
45 Introduction to Spring Boot RestTemplate
46 Apache Client Request Logging
47 Assignment – Externalize Properties
48 Assignment Review
49 LC – JPA Entities
50 LC – Spring Data JPA Repositories
51 LC – Bootstrap Data
52 Conclusion to Spring Boot RestTemplate
53 HTTP GET with Spring RestTemplate
54 HTTP POST with Spring RestTemplate
55 HTTP PUT with Spring RestTemplate
56 HTTP DELETE with Spring RestTemplate
57 Assignment – Create Spring RestTemplate clients
58 Assignment Review
59 HTTP Clients
60 Apache HTTP Client Configuration
Spring MVC Validation
61 Introduction
62 LC – Validation and Error Handling
63 Conclusion to Spring MVC Validation
64 Java Bean Validation
65 Bean Validation Implementation
66 Validation Error Handling
67 Spring Boot Method Validation
68 Assignment – Add Validation and Error Handling
69 Assignment Review
70 Spring MVC Controller Advice
71 LC – Bean Validation
Project Lombok and MapStruct
72 Introduction
73 Date Conversion with MapStruct
74 LC – Implementing MapStruct
75 LC – Fixing Broken Tests
76 LC – Adding CI Builds with CircleCI
77 Conclusion
78 Overview of Project Lombok
79 Project Lombok Configuration
80 Project Lombok Examples
81 Overview of MapStruct
82 MapStruct Configuration
83 Example of using Project Lombok and MapStruct
84 Assignment – Use MapStruct
85 Assignment Review
Spring MVC REST Docs
86 Introduction
87 Documenting Validation Constraints
88 URI Customization
89 Documentation Generation
90 Serving Docs with Spring Boot
91 Assignment – Add Spring REST Doc to Project
92 Assignment Review
93 Conclusion
94 Spring REST Docs Introduction
95 Project Code Review
96 Maven Configuration
97 Spring Mock MVC Configuration
98 Documenting Path Parameters
99 Documenting Query Parameters
100 Documenting Responses
101 Documenting Requests
Processing JSON with Spring Boot
102 Introduction
103 Custom Serializer with Jackson
104 Custom Deserializer with Jackson
105 LC – Jackson Configuration
106 LC – Jackson JSON Creator
107 LC – Beer Service – Implement Controller Methods
108 LC – Beer Service – Adding standard UPCs
109 Conclusion
110 JSON with Spring Boot Overview
111 Overview of Jackson
112 Json Testing with Spring Boot
113 Jackson Property Naming Strategies
114 Assignment – Configure Property Naming Strategy
115 Assignment Review
116 Setting Property Names with Jackson
117 Using @JsonFormat with Jackson
Deconstructing the Monolith
118 Introduction
119 Data Initialization
120 Enhance Get Beer with Inventory Information
121 Assignment – Add Show Inventory as Parameter
122 Assignment Review
123 Add Caching to Get Beer API
124 Assignment – Create Get Beer by UPC Endpoint
125 Assignment Review
126 Save UPC on Beer Order
127 Assignment – Enhance Order Response with Beer Information
128 Assignment Review
129 SFG Brewery Monolith
130 Deconstruction Next Steps
131 Conclusion
132 Monolith Project Code Review
133 Deconstruction Strategies
134 Monolith Deconstruction Plan
135 Beer Service Code Review
136 Beer Order Service Code Review
137 Beer Inventory Service Code Review
138 Setting Default Ports for Services
Enterprise Dependency Management
139 Introduction
140 Assignment – Update Services to use BOM
141 Assignment Review
142 Using Released BOMs
143 Assignment – Update Services to use Release BOM
144 Assignment Review
145 IntelliJ Workspace Tips and Tricks
146 Conclusion
147 Maven Bill of Materials
148 Maven BOM Creation
149 Maven BOM Setting Common Properties
150 Maven BOM Dependency Management
151 Maven BOM Common Dependencies
152 Maven BOM Common Build Plugins
153 Maven Enforcer Build Plugin
154 Beer Service Parent POM Configuration
Local MySQL Configuration
155 Introduction
156 Assignment – Database Initialization
157 Assignment Review
158 Correction – Hibernate Dialog
159 Data Source Connection Pooling
160 HikariCP Configuration for MySQL
161 Conclusion
162 Overview of Datasource Configuration with Spring Boot
163 Configure H2 MySQL Compatibility Mode
164 MySQL Requirements and Setup
165 MySQL Beer Service Configuration
166 Configure Beer Service for Local MySQL
167 Correcting Hibernate Error with MySQL
168 Assignment – Configure Services for MySQL
169 Assignment Review
JMS Messaging
170 Introduction
171 Send and Receive of JMS Messages
172 Running Active MQ in Docker
173 Using Local ActiveMQ Broker with Spring Boot
174 JMS and Spring Message Data Types
175 Conclusion
176 Introduction to JMS
177 Initial Project and Maven Dependencies
178 Java Message Object
179 Embedded Server Configuration
180 Task Configuration
181 Message Converter Configuration
182 Sending JMS Messages
183 Receiving JMS Messages
JMS Messaging Between Microservices
184 Introduction
185 Jackson JMS Configuration
186 Tips and Tricks – Logging Level
187 Challenge – Create New Inventory Listener
188 Challenge Review
189 Conclusion
190 Assignment – Configure JMS for Services
191 Assignment Review
192 IntelliJ Tips and Tricks – Auto Import on Paste
193 Brewing Beer Process Overview
194 Create Beer Event Objects
195 Create Brewing Service
196 Fixing the Broken Build!
197 Create Brew Beer Listener
Spring State Machine
198 Introduction
199 Payment Service Creation
200 Initializing State Machine from Database
201 Sending Events to the State Machine
202 State Change Interceptor
203 Progressing State from New to Pre-Auth
204 State Machine Actions
205 State Machine Guards
206 Microservice Design Pattern – Event Sourcing
207 Introduction to Spring State Machine
208 Conclusion
209 Credit Card Payment State Machine Overview
210 Spring Boot Project Creation and Dependencies
211 State Machine Enumerations
212 Spring Data JPA Configuration
213 State Configuration
214 Transition Configuration
215 Logging Configuration Using State Change Listeners
Using Sagas with Spring
216 Introduction
217 Fix CI Build Failure
218 Refactor Model to Common Package
219 Beer Order Manager Service
220 Refactor Order States
221 Fix CI Build Failure
222 The Problem with Transactions
223 Initiate Allocate Order
224 Add Allocation Service
225 Fix Failed CI Build
226 Retrospective
227 The Need for Sagas
228 Saga Coordination
229 Order Allocation Saga
230 Update Spring Boot in BOM
231 State Machine Enumerations
232 Configure State Machine States
Integration Testing of Sagas
233 Introduction to Integration Testing
234 Refactor Beer Order Service to use Saga
235 Spring Cloud Contract – Interview with Marcin Grzejszczak
236 Create Integration Test for New Order to Allocate
237 Testing with WireMock
238 WireMock for Beer Service
239 Validation JMS Test Component
240 Using Awaitility
241 Resolving Locking Failure
Compensating Transactions with Sagas
242 Introduction
243 Cancel Order Consumer
244 Refactoring for Persistence of Status Change
245 Testing Failed Validation
246 Failed Validation Compensating Transaction
247 Cancel Order Requirements
248 Cancel Order Configuration
249 Cancel Order Compensating Transaction
Spring Cloud Gateway
250 Introduction
251 The API Gateway Pattern
252 Developer Oriented API Gateways
253 Spring Cloud Gateway Service Creation
254 Spring Cloud Gateway Route Configuration
255 Review Running Services Locally
256 Beer Service Route Configuration
257 Inventory Service Route Configuration
Service Registration with Eureka
258 Introduction
259 Introduction to Eureka
260 Eureka Service Creation
261 Eureka Client Configuration for Beer Service
Service Discovery with Eureka
262 Introduction
263 Open Feign Client
264 Configure Gateway for Service Discovery
Circuit Breaker Pattern
265 Introduction
266 Circuit Breaker Pattern Overview
267 Resilience4j Failover for Spring Cloud Gateway
268 Using Hystrix Circuit Breaker with Feign Client
269 Using Resilience4j with Feign Client
Spring Cloud Config
270 Introduction
271 Overview of Spring Cloud Config
272 Create Spring Cloud Config Server
273 Spring Cloud Config Server Server Configuration
274 Server Side Application Configuration
275 Spring Cloud Client Configuration
Distributed Tracing
276 Introduction
277 Introduction to Distributed Tracing
278 Zipkin Server
279 Setup Spring Cloud Sleuth
280 Logging Config for JSON
281 Refactor Zipkin Configuration
Securing Spring Cloud
282 Introduction
283 Secure Inventory Service with Spring Security
284 Configure RESTTemplate for HTTP Basic Authentication
285 Configure Feign Client for HTTP Basic Authentication
286 Security Retrospective
287 Security 101
288 Property Encryption Decryption
289 Encrypt Beer Service Passwords
290 Secure Spring Cloud Config Server
291 Use Spring Security to Secure Eureka Server
Building Docker Images with Maven
292 Introduction
293 Push Images to Docker Hub
294 Docker Image Release Demo
295 Spring Boot Validation Update
296 Interview with James Labocki of RedHat
297 Requirements and Docker Hello World
298 Considerations for the JVM in a Docker Container
299 Overview of Building Docker Containers with Maven
300 Docker File Configuration
301 Troubleshoot Spring Boot Bug
302 Docker Image for Gateway Service
Docker Compose
303 Introduction
304 Important Links to Resources
305 Docker Compose for JMS Broker
306 Docker Compose for Zipkin
307 Docker Compose for Eureka Service & Spring Cloud Config
308 Docker Compose for Inventory Service
309 Configure API Gateway
310 Service Restart Policy
Consolidated Logging with ELK Stack
311 Introduction
312 Overview
313 Logging Configuration Update
314 Add Elasticsearch
315 Add Kibana
316 Add Filebeat
317 View Logs in Kibana
Deploying with Docker Swarm
318 Introduction
319 Configure JMS Server
320 Configure Elasticsearch Server
321 Configure Kibana Server
322 Configure Zipkin Server
323 Configure Eureka Server
324 Configure Spring Cloud Config Server
325 Spring Cloud Config Server IP Address Update
326 Provision Docker Swarm Cluster
327 Linux Troubleshooting Commands
328 Initialize Docker Swarm Cluster
329 Create Digital Ocean Account
330 Filebeat Swarm Configuration
331 Eureka Swarm Configuration
332 Spring Cloud Configuration
333 Digital Ocean Profile
334 Running Microservices with Docker Swarm
335 Tracing Requests for Troubleshooting
336 Zipkin Tracing
337 Tasting Room Service Challenge
338 Retrospective
339 Deployment Design
340 Provision Database Servers
341 Configure Database
342 Configure Java Truststore
343 Add Truststore file to Docker Image
344 Docker Image Release Process
345 Provision Service VMs
Appendix A Using GitHub
346 Git and GitHub Basics – Start here!
Resolve the captcha to access the links!