官术网_书友最值得收藏!

How it works...

You will see the Project Dependencies section, where we can choose the kind of functionalities that our application will perform: Will it connect to a database? Will it have a web interface? Do we plan to integrate with any of the social networks bake in operational support? and so on. By selecting the desired technologies, the appropriate starter libraries will be added automatically to the dependency list of our pregenerated project template.

Before we proceed with the generation of our project, let's go over what exactly a Spring Boot starter is and the benefits it provides us with.

Spring Boot aims to make it easy to get started with creating an application. Spring Boot starters are bootstrap libraries that contain a collection of all the relevant transitive dependencies that are needed to start a particular functionality. Each starter has a special file, which contains the list of all the provided dependencies Spring provides. Let's take a look at the following link for a spring-boot-starter-test definition as an example:

https://github.com/spring-projects/spring-boot/blob/master/spring-boot-project/spring-boot-starters/spring-boot-starter-test/src/main/resources/META-INF/spring.provides

Here we will see the following code:

provides: spring-test, spring-boot, junit, mockito, hamcrest-library, jsonassert, json-path 

This tells us that by including spring-boot-starter-test in our build as a dependency, we will automatically get spring-test, spring-boot, junit, mockito, hamcrest-library,jsonassert, and json-path. These libraries will provide us with all the necessary things in order to start writing application tests for the software that we will develop, without needing to manually add these dependencies to the build file individually.

With more than 100 starters provided, and with the ongoing community additions increasing the list, it is very likely that unless, we find ourselves with the need to integrate with a fairly common or popular framework, there is already a starter out there that we can use.

The following table shows you the most notable ones so as to give you an idea of what is available:

主站蜘蛛池模板: 潼关县| 舒城县| 徐汇区| 北京市| 闽清县| 彭山县| 东乡族自治县| 潍坊市| 林周县| 巴青县| 淳化县| 息烽县| 比如县| 华阴市| 古交市| 乌兰察布市| 临邑县| 章丘市| 峡江县| 上虞市| 衡水市| 嘉峪关市| 阿克苏市| 六枝特区| 新宁县| 南陵县| 青川县| 应城市| 张家川| 九龙县| 义马市| 新乐市| 中山市| 龙井市| 香格里拉县| 黎平县| 武鸣县| 内丘县| 鄄城县| 南郑县| 丹阳市|