Chapter 4. Writing Custom Spring Boot Starters

In this chapter, we will cover the following topics:

  • Understanding Spring Boot autoconfiguration
  • Creating a custom Spring Boot autoconfiguration starter
  • Configuring custom conditional bean instantiations
  • Using custom @Enable* annotations to toggle configurations

Introduction

In the previous chapters, we did a lot of configuration, and even more autoconfiguration while developing our Spring Boot application. Now, it is time to take a look behind the scenes and find out the magic behind the Spring Boot autoconfiguration, and write some starters of our own as well.

This is a very useful capability to possess, especially for large software enterprises where the presence of a proprietary code is inevitable, and ...

Get Spring Boot Cookbook now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.