Spring Boot Starter 是一组方便使用的依赖关系描述符,可以在应用程序中包含这些描述符。借助 Spring Boot Starter 开发人员可以获得所需的所有 Spring 及相关技术的一站式服务,而无需查看示例代码或复制粘贴依赖的库文件。譬如,如果需要 Spring JPA 访问数据库,则可以在工程中直接饮用 spring-boot-starter-data-jpa。
有关 Spring Boot Starter 命名规范,所有官方发布的 Starter 都遵循以下命名模式:spring-boot-starter-*,其中 * 指特定的应用程序代号或名称。任何第三方提供的 Starter 都不能以 spring-boot 作为前缀,应该将应用程序代号或名称作为前缀,譬如 mybatis-spring-boot-starter。
Spring Boot(2.2.x)官方目前已提供的 Starter 包括:
Spring Boot application starters:
spring-boot-starter
核心启动器,包括支持自动配置、日志记录及YAML。spring-boot-starter-activemq
支持使用Apache ActiveMQ作为JMS消息服务。spring-boot-starter-amqp
支持使用Spring AMQP和RabbitMQ。spring-boot-starter-aop
支持使用Spring AOP和AspectJ进行切面编程。spring-boot-starter-artemis
支持使用Apache Artemis作为JMS消息服务。spring-boot-starter-batch
支持使用Spring Batch。spring-boot-starter-cache
启用Spring Framework缓存支持。spring-boot-starter-cloud-connectors
支持使用Spring Cloud Connectors简化Cloud Foundry、Heroku等云平台的连接服务。spring-boot-starter-data-cassandra
支持使用Cassandra分布式数据库及Spring Data Cassandra。spring-boot-starter-data-cassandra-reactive
支持使用Cassandra分布式数据库及Spring Data Cassandra Reactive。spring-boot-starter-data-couchbase
支持使用Couchbase文档数据库及Spring Data Couchbase。spring-boot-starter-data-couchbase-reactive
支持使用Couchbase文档数据库及Spring Data Couchbase Reactive。spring-boot-starter-data-elasticsearch
支持使用Elasticsearch作为搜索分析引擎及Spring Data Elasticsearch。spring-boot-starter-data-jdbc
支持使用Spring Data JDBC。spring-boot-starter-data-jpa
支持使用Spring Data JPA with Hibernate。spring-boot-starter-data-ldap
支持使用Spring Data LDAP。spring-boot-starter-data-mongodb
支持使用MongoDB文档数据库及Spring Data MongoDB。spring-boot-starter-data-mongodb-reactive
支持使用MongoDB文档数据库及Spring Data MongoDB Reactive。spring-boot-starter-data-neo4j
支持使用Neo4j图数据库及Spring Data Neo4j。spring-boot-starter-data-redis
支持使用Redis键值数据存储及Spring Data Redis和Lettuce客户端。spring-boot-starter-data-redis-reactive
支持使用Redis键值数据存储及Spring Data Redis Reactive和Lettuce客户端。spring-boot-starter-data-rest
支持使用REST方式暴露Spring Data Repositories。spring-boot-starter-data-solr
支持使用Apache Solr搜索平台及Spring Data Solr。spring-boot-starter-freemarker
支持使用FreeMarker视图构建MVCWeb 应用。spring-boot-starter-groovy-templates
支持使用Groovy模板视图构建MVCWeb 应用。spring-boot-starter-hateoas
支持使用Spring MVC和Spring HATEOAS构建超媒体的RESTfulWeb 应用。spring-boot-starter-integration
支持使用Spring Integration。spring-boot-starter-jdbc
支持使用HikariCP作为JDBC连接池。spring-boot-starter-jersey
支持使用JAX-RS和Jersey构建RESTfulWeb 应用,替代spring-boot-starter-web。spring-boot-starter-jooq
支持使用jOOQ访问SQL数据库,替代spring-boot-starter-data-jpa或spring-boot-starter-jdbc。spring-boot-starter-json
支持读写json。spring-boot-starter-jta-atomikos
启用Atomikos支持JTA事务。spring-boot-starter-jta-bitronix
启用Bitronix支持JTA事务。spring-boot-starter-mail
支持使用Java Mail和Spring提供的邮件发送功能。spring-boot-starter-mustache
支持使用Mustache视图构建 Web 应用。spring-boot-starter-oauth2-client
支持使用Spring Security提供的OAuth2/OpenID连接客户端特性。spring-boot-starter-oauth2-resource-server
支持使用Spring Security提供的OAuth2资源服务器特性。spring-boot-starter-quartz
支持使用Quartz定时机制。spring-boot-starter-rsocket
支持构建RSocket客户端和服务器。spring-boot-starter-security
支持使用Spring Security。spring-boot-starter-test
支持使用JUnit,Hamcrest和Mockito测试Spring Boot应用。spring-boot-starter-thymeleaf
支持使用Thymeleaf视图构建MVCWeb 应用。spring-boot-starter-validation
支持基于Hibernate Validator的Java Bean校验。spring-boot-starter-web
支持使用Spring MVC构建 Web 应用,包括RESTful应用,使用Tomcat作为默认的嵌入式容器。spring-boot-starter-web-services
支持使用 Spring Web Services。spring-boot-starter-webflux
支持构建 WebFlux 应用。spring-boot-starter-websocket
支持构建 WebSocket 应用。
Spring Boot production starters:
-
spring-boot-starter-actuator
支持使用 Spring Boot Actuator 提供生产级别的应用程序监控和管理功能。
Spring Boot technical starters:
spring-boot-starter-jetty
支持使用 Jetty 作为嵌入式 Servlet 容器。spring-boot-starter-log4j2
支持使用 Log4j2 记录日志。spring-boot-starter-logging
支持使用 Logback 记录日志,默认。spring-boot-starter-reactor-netty
支持使用 Reactor Netty 作为嵌入式 Reactive HTTP 服务器。spring-boot-starter-tomcat
支持使用 Tomcat 作为嵌入式 Servlet 容器,是spring-boot-starter-web默认支持的 Servlet 容器。spring-boot-starter-undertow
支持使用 Undertow 作为嵌入式 Servlet 容器。