更新时间:2021-07-02 14:55:09
coverpage
Title Page
Copyright
Building Microservices with Spring
About Packt
Why subscribe?
Packt.com
Contributors
About the authors
Packt is searching for authors like you
Preface
Who this book is for
What this book covers
To get the most out of this book
Download the example code files
Conventions used
Get in touch
Reviews
Getting Started with Spring Framework 5.0 and Design Patterns
Introducing Spring Framework
Simplifying application development using Spring and its pattern
Using the power of the POJO pattern
Injecting dependencies between POJOs
How DI works and makes things easy for development and testing
Using factory helper pattern for dependent components
Using DI pattern for dependent components
Applying aspects for cross cutting concerns
How Spring AOP works
Applying the template pattern to eliminate boilerplate code
The Template Design pattern in Spring
Using a Spring container to manage beans with the Factory pattern
Bean factory
Application contexts
Creating a container with an application context
Life of a bean in the container
Spring modules
Core Spring container
Spring's AOP module
Spring DAO - data access and integration
Spring's ORM
Spring web MVC
New features in Spring Framework 5.0
Summary
Overview of GOF Design Patterns - Core Design Patterns
Introducing the power of design patterns
Common GoF Design Pattern overview
Creational design patterns
Factory design pattern
Implementing the Factory design pattern in Spring Framework
Sample implementation of the Factory design pattern
Abstract factory design pattern
Common problems where you should apply the Abstract factory design pattern
Implementing the Abstract factory design pattern in the Spring Framework
Sample implementation of the Abstract Factory design pattern
Singleton design pattern
Common problems where you should apply Singleton pattern
Singleton design pattern implementation in the Spring Framework
Sample implementation of the Singleton design pattern
Prototype design pattern
Benefits of the Prototype design pattern
UML class structure
Sample implementation of the Prototype design pattern
Builder design pattern
Benefits of the Builder pattern:
Implementing the Builder pattern in the Spring Framework
Common problems where you should apply Builder pattern
Sample implementation of the Builder design pattern
Wiring Beans using the Dependency Injection Pattern
The dependency injection pattern
Solving problems using the dependencies injection pattern
Without dependency injection
With dependency injection pattern
Types of dependency injection patterns
Constructor-based dependency injection pattern
Setter-based dependency injection
Configuring the dependency injection pattern with Spring
Dependency injection pattern with Java-based configuration
Creating a Java configuration class - AppConfig.java
Declaring Spring beans into configuration class
Injecting Spring beans
Best approach to configure the dependency injection pattern with Java
Dependency injection pattern with XML-based configuration
Creating an XML configuration file
Declaring Spring beans in an XML file
Using constructor injection
Using setter injection
Dependency injection pattern with Annotation-based configuration
What are Stereotype annotations?
Creating auto searchable beans using Stereotype annotations
Searching beans using component scanning
Annotating beans for autowiring
Using @Autowired with setter method
Using @Autowired with the fields
The Autowiring DI pattern and disambiguation
Resolving disambiguation in Autowiring DI pattern
Implementing the Abstract Factory Pattern in Spring (FactoryBean interface)
Implementation of FactoryBean interface in Spring