Spring Boot starters

The steps of the functional components of Spring Boot (such as Spring-boot-starter -actuator, Spring-boot-starter -data-redis, etc.) are very simple. In the famous way of putting elephants in refrigerators, There are three steps to complete the use of component functionality:

STEP 1

Import the corresponding package in the POM file, for example:

STEP 2

Add the corresponding configuration to the application configuration file. The configuration is specified by the component. You need to view the official documents or related instructions. Some of the more complex components, the corresponding parameters and rules are also more, some may be dozens or hundreds of large.

STEP 3

With the above two steps working, we can use the relevant interfaces provided by the component to develop business functions. I’ve compiled the official starter list below. Let’s take a look.

1, the application of starters

App-level Starters

The name of the Starter The Starter description
spring-boot-starter Core Starter, including automatic configuration, logging, and YAML support
spring-boot-starter-activemq Integrated Apache ActiveMQ, JMS-based message queue
spring-boot-starter-artemis Integrated Apache Artemis, JMS-based message queue
spring-boot-starter-amqp Message queues that integrate Spring AMQP and Rabbit MQ
spring-boot-starter-aop Integrate Spring AOP and AspectJ for faceted programming
spring-boot-starter-batch Integrate Spring Batch
spring-boot-starter-cache Integrated Spring Cache
spring-boot-starter-data-cassandra Integrate Cassandra (distributed database) with Spring Data Cassandra
spring-boot-starter-data-cassandra-reactive Integrate Cassandra (distributed database) with Spring Data Cassandra Reactive
spring-boot-starter-data-couchbase Integrate Couchbase (document database) with Spring Data Couchbase
spring-boot-starter-data-couchbase-reactive Integrate Couchbase (document database) and Spring Data Couchbase Reactive
spring-boot-starter-data-elasticsearch Elasticsearch integration with Spring Data Elasticsearch
spring-boot-starter-data-solr Integrate Apache Solr (search engine) with Spring Data Solr
spring-boot-starter-data-jdbc Integrate with Spring Data JDBC
spring-boot-starter-data-jpa Integrate Spring Data JPA with Hibernate
spring-boot-starter-data-ldap Integrate with Spring Data LDAP
spring-boot-starter-data-mongodb Integrate MongoDB (document-based database) and Spring Data MongoDB
spring-boot-starter-data-mongodb-reactive Integrate MongoDB (document database) and Spring Data MongoDB Reactive
spring-boot-starter-data-neo4j Integrate Neo4j (graphical database) and Spring Data Neo4j
spring-boot-starter-data-r2dbc Integrate Spring Data R2DBC
spring-boot-starter-data-redis Integrate Redis (in-memory database) with Spring Data Redis and the Lettuce client
spring-boot-starter-data-redis-reactive Integrate Redis (in-memory database) with Spring Data Redis Reactive and the Lettuce client
spring-boot-starter-data-rest Integrating Spring Data REST exposes Spring Data Repositories for outputting REST resources
spring-boot-starter-thymeleaf Integrate Thymeleaf views to build MVC Web applications
spring-boot-starter-freemarker Integrate FreeMarker views to build MVC Web applications
spring-boot-starter-groovy-templates Integrate Groovy template views to build MVC Web applications
spring-boot-starter-hateoas Integrate Spring MVC and Spring HATEOAS to build hypermedia RESTful Web applications
spring-boot-starter-integration Integrated Spring Integration
spring-boot-starter-jdbc Integrate JDBC with HikariCP connection pool
spring-boot-starter-jersey Integrating JAX-RS and Jersey to build RESTful Web applications, it is an alternative starter of Spring-boot-starter-Web
spring-boot-starter-jooq JOOQ integrates jOOQ to access SQL databases and is an alternative starter for spring-boot-starter-data-JPA or spring-boot-starter-JDBC
spring-boot-starter-json Read and write JSON
spring-boot-starter-jta-atomikos Integrate Atomikos to implement JTA transactions
spring-boot-starter-jta-bitronix Integrate Bitronix to implement JTA transactions (identified as of 2.3.0)Deprecated)
spring-boot-starter-mail Integrate Java Mail with the Spring framework’s Mail sending capabilities
spring-boot-starter-mustache Build web applications with Mustache View
spring-boot-starter-security Integrated Spring Security
spring-boot-starter-oauth2-client Integrated with Spring Security’s OAuth2/OpenID to connect to clients
spring-boot-starter-oauth2-resource-server Integrated with Spring Security’s OAuth2 resource server capabilities
spring-boot-starter-quartz Integrated Quartz task scheduling
spring-boot-starter-rsocket Build the RSocket client and server
spring-boot-starter-test Integrate JUnit Jupiter, Hamcrest and Mockito to test Spring Boot applications and class libraries
spring-boot-starter-validation Integrate Java Bean Validation with Hibernate Validator
spring-boot-starter-web Integrate Spring MVC to build RESTful Web applications, using Tomcat as the default embedded container
spring-boot-starter-web-services Integrate With Spring Web Services
spring-boot-starter-webflux Integrate With Spring Reactive Web to build WebFlux applications
spring-boot-starter-websocket Integrate Spring WebSocket to build WebSocket applications

Use Starter for each technology you use, and Spring Boot helps you quickly integrate, rather than manually configure.

2, production of starters

In addition to the above app-level starters, there are production-level starters that can be used for online/production functions:

The name of the Starter The Starter description
spring-boot-starter-actuator Integrated Spring Boot Actuator provides production functions to help monitor and manage applications

This means that it does not matter with any technology or any business, as long as you use the Spring Boot framework, you can use it in the production environment, not only in production, but in the production environment to experience its significance.

3, technical starters

In addition to app and production Starters, Spring Boot also includes the following technical Starters to help you eliminate or replace a specific framework or technology:

The name of the Starter The Starter description
spring-boot-starter-jetty Integrate Jetty as an embedded servlet container that can be used as an alternative to Spring-boot-starter-Tomcat
spring-boot-starter-log4j2 The integrated Log4j2 logging framework can be used to replace Spring-boot-starter-logging
spring-boot-starter-logging Integrate Logback logging framework, which is also the default logging Starter
spring-boot-starter-reactor-netty Integrate Netty as a built-in responsive HTTP server
spring-boot-starter-tomcat Integrate Tomcat as an embedded servlet container, which is also the default servlet container starter integrated with Spring-boot-starter-Web
spring-boot-starter-undertow Integrate Undertow as an embedded servlet container that can be used as an alternative to Spring-boot-starter-Tomcat

Please refer to:

link

conclusion

As the Spring Boot version continues to be updated, more starters may be added, although a few may be removed.

Of course, in addition to third-party starters, companies using Spring Boot often have private, customized starters that can be used for quick integration across business units within the company without having to build separate wheels.

Concern public number: Java baodian