I. Overview
In the front, we learned about Springboot's management behavior for our dependent versions, but there is still one problem that needs to be addressed, which is the question of which jar files we want to introduce.
For example, we want to complete the development of a Web project, we need to introduce a lot of dependencies, each time we need to replicate a bunch of the same dependency configuration, not very cumbersome, and very error-prone,
For this reason, Springboot provides us with a concept of a scenario launcher.
Two. Scene Launcher
The scene launcher, simply speaking, is a collection of all the jar files needed for a particular business.
For example, Springboot provides a web scenario startup package, and if we develop a Web project, we just need to introduce a web-based scenario to launch the package. As to how much specific dependence it needs, Springboot helps us to declare it in advance.
After that, we no longer need to worry about the need for the jar file above.
In addition, the name of the scene launcher provided by spring is very canonical, and we can infer the name of the scenario launcher we need ourselves.
Look at the following Web scene Launcher:
<dependency> <groupId>org.springframework.boot</groupId> <artifactId> Spring-boot-starter-web</artifactid></dependency>
We found that we did not have a version of the information, that is because we used the dependency management function, the specific look at the previous section.
Three. Start-up dependency
Now, the most painful problem we have in using the MAVEN process is solved
Now, let's think about the solution.
[1] using the dependency manager to manage the version of the jar file we need
[2] through the scene launcher to complete a specific scenario all the jar file introduction.
Let's look at the scenario launcher for the Web environment we introduced above, and we found that a lot of dependencies were introduced.
Think about it, if we need a one to add, that is how much trouble, fortunately this problem has been a better solution.
003 Scene Launcher