Log In
Or create an account ->
Imperial Library
Home
About
News
Upload
Forum
Help
Login/SignUp
Index
Preface
Welcome
Conventions Used in This Book
Using Code Examples
O’Reilly Online Learning
How to Contact Us
Acknowledgments
1. Spring Boot in a Nutshell
Spring Boot’s Three Foundational Features
Starters for Simplified Dependency Management
Executable JARs for Simplified Deployment
Autoconfiguration
Summary
2. Choosing Your Tools and Getting Started
Maven or Gradle?
Apache Maven
Gradle
Choosing Between Maven and Gradle
Java or Kotlin?
Java
Kotlin
Choosing Between Java and Kotlin
Choosing a Version of Spring Boot
The Spring Initializr
Straight Outta Commandline
Staying In Integrated Development Environments (IDEs)
Cruising Down main()
Summary
3. Creating Your First Spring Boot REST API
The Hows and Whys of APIs
What Is REST, and Why Does It Matter?
Your API, HTTP Verb Style
Back to the Initializr
Creating a Simple Domain
GET-ting
@RestController in a Nutshell
POST-ing
PUT-ting
DELETE-ing
And More
Trust, but Verify
Summary
4. Adding Database Access to Your Spring Boot App
Priming Autoconfig for Database Access
What Do We Hope to Gain?
Adding a Database Dependency
Adding Code
Saving and Retrieving Data
A Bit of Polishing
Summary
5. Configuring and Inspecting Your Spring Boot App
Application Configuration
@Value
@ConfigurationProperties
Potential Third-Party Option
Autoconfiguration Report
Actuator
Getting Actuator to Open Up
Becoming More Environmentally Aware Using Actuator
Turning Up the Volume on Logging with Actuator
Summary
6. Really Digging into Data
Defining Entities
Template Support
Repository Support
@Before
Creating a Template-Based Service Using Redis
Initializing the Project
Developing the Redis Service
Converting from Template to Repository
Creating a Repository-Based Service Using the Java Persistence API (JPA)
Initializing the Project
Developing the JPA (MySQL) Service
Loading Data
Creating a Repository-Based Service Using a NoSQL Document Database
Initializing the Project
Developing the MongoDB Service
Creating a Repository-Based Service Using a NoSQL Graph Database
Initializing the Project
Developing the Neo4j Service
Summary
7. Creating Applications Using Spring MVC
Spring MVC: What Does It Mean?
End User Interactions Using Template Engines
Initializing the Project
Developing the Aircraft Positions Application
Passing Messages
Powering Up PlaneFinder
Extending the Aircraft Positions Application
Creating Conversations with WebSocket
What Is WebSocket?
Refactoring the Aircraft Positions Application
Summary
8. Reactive Programming with Project Reactor and Spring WebFlux
Introduction to Reactive Programming
Project Reactor
Tomcat versus Netty
Reactive Data Access
R2DBC with H2
Reactive Thymeleaf
RSocket for Fully Reactive Interprocess Communication
What Is RSocket?
Putting RSocket to Work
Summary
9. Testing Spring Boot Applications for Increased Production Readiness
Unit Testing
Introducing @SpringBootTest
Important Unit Tests for the Aircraft Positions Application
Refactoring for Better Testing
Testing Slices
Summary
10. Securing Your Spring Boot Application
Authentication and Authorization
Authentication
Authorization
Spring Security in a Nutshell
The HTTP Firewall
Security Filter Chains
Request and Response Headers
Implementing Forms-Based Authentication and Authorization with Spring Security
Adding Spring Security Dependencies
Adding Authentication
Authorization
Implementing OpenID Connect and OAuth2 for Authentication and Authorization
Aircraft Positions Client Application
PlaneFinder Resource Server
Summary
11. Deploying Your Spring Boot Application
Revisiting the Spring Boot Executable JAR
Building a “Fully Executable” Spring Boot JAR
What Does It Mean?
Exploding JARs
Deploying Spring Boot Applications to Containers
Creating a Container Image from an IDE
Creating a Container Image from the Command Line
Verifying the Image Exists
Running the Containerized Application
Utilities for Examining Spring Boot Application Container Images
Pack
Dive
Summary
12. Going Deeper with Reactive
When Reactive?
Testing Reactive Applications
But First, Refactoring
And Now, the Testing
Diagnosing and Debugging Reactive Applications
Hooks.onOperatorDebug()
Checkpoints
ReactorDebugAgent.init()
Summary
Index
← Prev
Back
Next →
← Prev
Back
Next →