File tree Expand file tree Collapse file tree 5 files changed +40
-12
lines changed
java/io/geekidea/springbootplus Expand file tree Collapse file tree 5 files changed +40
-12
lines changed Original file line number Diff line number Diff line change 6363 <lombok .version>1.18.8</lombok .version>
6464 <commons-pool2 .version>2.6.2</commons-pool2 .version>
6565 <jwt .version>0.9.1</jwt .version>
66+ <spring-boot-admin .version>2.1.6</spring-boot-admin .version>
6667
6768 <maven-compiler-source .version>1.8</maven-compiler-source .version>
6869 <maven-compiler-target .version>1.8</maven-compiler-target .version>
261262 <version >4.5.10</version >
262263 </dependency >
263264
265+ <!-- spring boot admin start -->
266+ <dependency >
267+ <groupId >de.codecentric</groupId >
268+ <artifactId >spring-boot-admin-starter-server</artifactId >
269+ <version >${spring-boot-admin.version} </version >
270+ </dependency >
271+ <dependency >
272+ <groupId >de.codecentric</groupId >
273+ <artifactId >spring-boot-admin-starter-client</artifactId >
274+ <version >${spring-boot-admin.version} </version >
275+ </dependency >
276+ <!-- spring boot admin end -->
277+
264278 </dependencies >
265279
266280 <build >
Original file line number Diff line number Diff line change 1616
1717package io .geekidea .springbootplus ;
1818
19+ import de .codecentric .boot .admin .server .config .EnableAdminServer ;
1920import io .geekidea .springbootplus .util .PrintApplicationInfo ;
2021import lombok .extern .slf4j .Slf4j ;
2122import org .mybatis .spring .annotation .MapperScan ;
3839@ EnableScheduling
3940@ EnableTransactionManagement
4041@ EnableConfigurationProperties
42+ @ EnableAdminServer
4143@ SpringBootApplication
4244@ MapperScan ({"io.geekidea.springbootplus.**.mapper" })
4345public class SpringBootPlusApplication {
Original file line number Diff line number Diff line change 3434@ Slf4j
3535public class IndexController {
3636
37- @ RequestMapping ("/" )
37+ @ RequestMapping ("/index " )
3838 public ApiResult <String > index (){
3939 log .debug ("index..." );
4040 return ApiResult .ok ("Welcome to Spring Boot Plus Project..." );
Original file line number Diff line number Diff line change @@ -139,12 +139,6 @@ mybatis-plus:
139139 logic-not-delete-value : 1
140140 mapper-locations : classpath*:mapper/**/*Mapper.xml
141141
142- # 开启和暴露所有端点
143- management :
144- endpoints :
145- web :
146- exposure :
147- include : ' *'
148142
149143swagger :
150144 base :
@@ -160,15 +154,31 @@ swagger:
160154
161155
162156info :
157+ project-groupId : ' @project.groupId@'
163158 project-artifactId : ' @project.artifactId@'
159+ project-name : ' @project.name@'
160+ project-finalName : ' @project.build.finalName@'
164161 project-author : ${swagger.contact.name}
165162 project-description : ' @project.description@'
166- project-finalName : ' @project.build.finalName@'
167- project-groupId : ' @project.groupId@'
168- project-name : ' @project.name@'
169163 project-sourceEncoding : ' @project.build.sourceEncoding@'
170- project-spring-boot-version : ' @project-parent.version@'
164+ project-spring-boot-version : ' @spring-boot.version@'
165+ project-mybatis-plus-version : ' @mybatis-plus-boot-starter.version@'
171166 project-version : ' @project.version@'
172167
168+ ---
169+ # spring boot admin
170+ spring :
171+ boot :
172+ admin :
173+ client :
174+ url : ' http://localhost:8888'
173175
174-
176+ # 开启和暴露所有端点
177+ management :
178+ endpoints :
179+ web :
180+ exposure :
181+ include : " *"
182+ endpoint :
183+ health :
184+ show-details : ALWAYS
Original file line number Diff line number Diff line change @@ -10,3 +10,5 @@ ${AnsiColor.BLUE}
1010
1111 :: Spring Boot :: (v${spring-boot.version})
1212 :: Spring Boot Plus :: (v${project.version})
13+ :: spring-boot-plus :: https://springboot.plus
14+
You can’t perform that action at this time.
0 commit comments