Spring Boot: Understanding starters

In Previous post we learn a basic idea about boot application. Let’s see some short but useful funda used covered in that post. Here i am talking about Spring Boot Starters.

Spring boot provides 45+ built in starters which provides capability to support ready to implement capability.

Git url for Boot starter is: https://github.com/spring-projects/spring-boot/tree/master/spring-boot-starters
you can find all starters available for boot here.

Actually starter combines multiple dependencies into one so Boot engine will come to know which dependency needs to add in project. According to dependency defined in pom.xml boot engine will download required jar files and create snapshot in memory for required classes.

The pom.xml from previous post shows

Here, we found one common naming pattern of artifactIdwhere spring-boot-starter- remains common and trailing part would be different. in Parent tag artifactId is spring-boot-starter- appended by parent and in dependency tag artifactId is spring-boot-starter- appended by web. so the trailing part is type of application or module.

As we discussed starter combines multiple dependency into one so let’s see from where we can find which dependency covered under particular starter. We can find the same using same GIT url which is shared previously.
to see detailed information about starter

  • open link: https://github.com/spring-projects/spring-boot/tree/master/spring-boot-starters
  • For example we clicked on :spring-boot-starter-data-jpa
  • It shows a package structure of spring-boot-starter-data-jpa
  • you will find pom.xml and src/main/resources/META-INF package inside it
  • Open src/main/resources/META-INF
  • you will find one more file called spring.provides and it shows number of modules covered in it, here you will get provides: spring-orm,hibernate-entity-manager,spring-data-jpa written on file
  • and pom.xml shows actual artifacts for dependency which is displayed on spring.provides file.

At last here is some list of starters as per latest git update as on date 08 Mar, 2016.

Starter Name Description Demo (4)
spring-boot-starter-parent The core Spring Boot starter, including auto-configuration support, logging and YAML.
spring-boot-starter-actuator Production ready features to help you monitor and manage your application.
spring-boot-starter-amqp Support for the “Advanced Message Queuing Protocol” via spring-rabbit.
spring-boot-starter-aop Support for aspect-oriented programming including spring-aop and AspectJ.
spring-boot-starter-artemis Support for “Java Message Service API” via Apache Artemis.
spring-boot-starter-batch Support for “Spring Batch” including HSQLDB database.
spring-boot-starter-cache Support for Spring’s Cache abstraction.
spring-boot-starter-cloud-connectors Support for “Spring Cloud Connectors” which simplifies connecting to services in cloud platforms like Cloud Foundry and Heroku.
spring-boot-starter-data-cassandra Support for Apache Cassandra.
spring-boot-starter-data-couchbase Support for Couchbae Database.
spring-boot-starter-data-elasticsearch Support for the Elasticsearch search and analytics engine including spring-data-elasticsearch.
spring-boot-starter-data-gemfire Support for the GemFire distributed data store including spring-data-gemfire.
spring-boot-starter-data-jpa Support for the “Java Persistence API” including spring-data-jpa, spring-orm and Hibernate. View
spring-boot-starter-data-mongodb Support for the MongoDB NoSQL Database, including spring-data-mongodb.
spring-boot-starter-data-redis Support for the REDIS key-value data store, including spring-redis.
spring-boot-starter-data-rest Support for exposing Spring Data repositories over REST via spring-data-rest-webmvc.
spring-boot-starter-data-solr Support for the Apache Solr search platform, including spring-data-solr. View
spring-boot-starter-freemarker Support for the FreeMarker templating engine.
spring-boot-starter-groovy-templates Support for the Groovy templating engine.
spring-boot-starter-hateoas Support for HATEOAS-based RESTful services via spring-hateoas.
spring-boot-starter-hornetq Support for “Java Message Service API” via HornetQ.
Support for common spring-integration modules.
spring-boot-starter-jdbc Support for JDBC databases.
spring-boot-starter-jersey Support for the Jersey RESTful Web Services framework.
spring-boot-starter-jetty Support for embedded Jetty server.
spring-boot-starter-jooq Support for JOOQ (Java Object Oriented Querying )
spring-boot-starter-jta-atomikos Support for JTA distributed transactions via Atomikos.
spring-boot-starter-jta-bitronix Support for JTA distributed transactions via Bitronix.
spring-boot-starter-log4j2 Support logging using log4j2,log4j-slf4j-impl.
spring-boot-starter-logging Support logging using logback-classic,jcl-over-slf4j,jul-to-slf4j.
spring-boot-starter-mail Support for javax.mail. View
spring-boot-starter-mobile Support for spring-mobile.
spring-boot-starter-mustache Support for the Mustache templating engine.
spring-boot-starter-remote-shell Supports an integrated Java shell called ‘CRaSH’
spring-boot-starter-security Support for spring-security.
spring-boot-starter-social-facebook Support for spring-social-facebook.
spring-boot-starter-social-linkedin Support for spring-social-linkedin.
spring-boot-starter-social-twitter Support for spring-social-twitter.
spring-boot-starter-test Support for common test dependencies, including JUnit, Hamcrest and Mockito along with the spring-test module.
spring-boot-starter-thymeleaf Support for the Thymeleaf templating engine, including integration with Spring.
spring-boot-starter-tomcat Support for embedded Tomcat container.
spring-boot-starter-undertow Support for undertow server, for more: http://undertow.io/.
spring-boot-starter-validation Support for validation mechanism, currently providing hibernate-validator.
spring-boot-starter-velocity Support for the Velocity templating engine.
spring-boot-starter-web Support for full-stack web development, including Tomcat and spring-webmvc. View
spring-boot-starter-websocket Support for WebSocket development.
spring-boot-starter-ws Support for Spring Web Services.

At Last, i would like to hear from you guys for some mistakes, new blogs, demo, ideas or anything which will help us to make our blog better.

Share current post by copy: http://goo.gl/wxqT44