فهرست منبع

swagger相关jar包依赖优化

rengb 4 سال پیش
والد
کامیت
ff0ee2614f

+ 10 - 64
common/pom.xml

@@ -3,111 +3,57 @@
          xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 https://maven.apache.org/xsd/maven-4.0.0.xsd">
     <modelVersion>4.0.0</modelVersion>
 
-    <groupId>com.lantone</groupId>
+    <parent>
+        <groupId>com.lantone</groupId>
+        <artifactId>emrais</artifactId>
+        <version>0.0.1-SNAPSHOT</version>
+    </parent>
+
     <artifactId>common</artifactId>
-    <version>0.0.1-SNAPSHOT</version>
     <name>common</name>
     <packaging>jar</packaging>
 
-    <properties>
-        <java.version>1.8</java.version>
-        <guava.version>28.1-jre</guava.version>
-        <mybatis-plus-boot-starter.version>3.2.0</mybatis-plus-boot-starter.version>
-        <knife4j-micro-spring-boot-starter.version>1.9.6</knife4j-micro-spring-boot-starter.version>
-        <commons-lang3.version>3.8.1</commons-lang3.version>
-        <fastjson.version>1.2.62</fastjson.version>
-        <gson.version>2.8.5</gson.version>
-        <maven-compiler-plugin.version>3.8.1</maven-compiler-plugin.version>
-        <commons-codec.version>1.11</commons-codec.version>
-        <poi.version>4.0.1</poi.version>
-        <commons-beanutils.version>1.9.3</commons-beanutils.version>
-        <docker-maven-plugin.version>1.2.2</docker-maven-plugin.version>
-    </properties>
-
     <dependencies>
         <dependency>
             <groupId>com.google.guava</groupId>
             <artifactId>guava</artifactId>
-            <version>${guava.version}</version>
-        </dependency>
-
-        <dependency>
-            <groupId>com.baomidou</groupId>
-            <artifactId>mybatis-plus-boot-starter</artifactId>
-            <version>${mybatis-plus-boot-starter.version}</version>
         </dependency>
-
         <dependency>
             <groupId>com.github.xiaoymin</groupId>
             <artifactId>knife4j-micro-spring-boot-starter</artifactId>
-            <version>${knife4j-micro-spring-boot-starter.version}</version>
         </dependency>
-
         <dependency>
             <groupId>org.apache.commons</groupId>
             <artifactId>commons-lang3</artifactId>
-            <version>${commons-lang3.version}</version>
         </dependency>
-
         <dependency>
             <groupId>com.alibaba</groupId>
             <artifactId>fastjson</artifactId>
-            <version>${fastjson.version}</version>
         </dependency>
-
         <dependency>
             <groupId>com.google.code.gson</groupId>
             <artifactId>gson</artifactId>
-            <version>${gson.version}</version>
         </dependency>
-
         <dependency>
             <groupId>commons-codec</groupId>
             <artifactId>commons-codec</artifactId>
-            <version>${commons-codec.version}</version>
         </dependency>
-
-        <!-- poi excel -->
         <dependency>
             <groupId>org.apache.poi</groupId>
             <artifactId>poi</artifactId>
-            <version>${poi.version}</version>
         </dependency>
         <dependency>
             <groupId>org.apache.poi</groupId>
             <artifactId>poi-ooxml</artifactId>
-            <version>${poi.version}</version>
         </dependency>
         <dependency>
             <groupId>commons-beanutils</groupId>
             <artifactId>commons-beanutils</artifactId>
-            <version>${commons-beanutils.version}</version>
         </dependency>
-
+        <dependency>
+            <groupId>org.projectlombok</groupId>
+            <artifactId>lombok</artifactId>
+        </dependency>
     </dependencies>
 
-    <build>
-        <plugins>
-            <plugin>
-                <groupId>com.spotify</groupId>
-                <artifactId>docker-maven-plugin</artifactId>
-                <version>${docker-maven-plugin.version}</version>
-                <configuration>
-                    <imageName>emrais/${project.artifactId}:${project.version}</imageName>
-                    <baseImage>java:8</baseImage>
-                    <forceTags>true</forceTags>
-                    <entryPoint>["java", "-jar", "/${project.build.finalName}.jar $BOOT_OPTIONS"]
-                    </entryPoint>
-                    <resources>
-                        <resource>
-                            <targetPath>/</targetPath>
-                            <directory>${project.build.directory}</directory>
-                            <include>${project.build.finalName}.jar</include>
-                        </resource>
-                    </resources>
-                </configuration>
-            </plugin>
-        </plugins>
-    </build>
-
 </project>

+ 60 - 51
common/src/main/java/com/lantone/common/config/SwaggerConfiguration.java

@@ -1,33 +1,33 @@
 package com.lantone.common.config;
 
-import com.github.xiaoymin.knife4j.spring.annotations.EnableSwaggerBootstrapUi;
-import com.google.common.collect.Lists;
+import com.lantone.common.domain.SwaggerProperties;
 import org.springframework.beans.factory.annotation.Value;
 import org.springframework.context.annotation.Bean;
 import org.springframework.context.annotation.Configuration;
-import org.springframework.context.annotation.Import;
 import org.springframework.core.annotation.Order;
-import springfox.bean.validators.configuration.BeanValidatorPluginsConfiguration;
 import springfox.documentation.builders.ApiInfoBuilder;
 import springfox.documentation.builders.PathSelectors;
 import springfox.documentation.builders.RequestHandlerSelectors;
 import springfox.documentation.service.ApiInfo;
 import springfox.documentation.service.ApiKey;
 import springfox.documentation.service.AuthorizationScope;
+import springfox.documentation.service.Contact;
 import springfox.documentation.service.SecurityReference;
-import springfox.documentation.service.SecurityScheme;
 import springfox.documentation.spi.DocumentationType;
 import springfox.documentation.spi.service.contexts.SecurityContext;
 import springfox.documentation.spring.web.plugins.Docket;
 import springfox.documentation.swagger2.annotations.EnableSwagger2;
 
+import java.util.ArrayList;
 import java.util.List;
 
-
+/**
+ * @Description: Swagger基础配置
+ * @author: rengb
+ * @time: 2021/1/5 18:27
+ */
 @Configuration
 @EnableSwagger2
-@EnableSwaggerBootstrapUi
-@Import(BeanValidatorPluginsConfiguration.class)
 public class SwaggerConfiguration {
 
     @Value("${swagger.title}")
@@ -40,59 +40,68 @@ public class SwaggerConfiguration {
     @Bean
     @Order(value = 1)
     public Docket groupRestApi() {
-        return new Docket(DocumentationType.SWAGGER_2)
-                .apiInfo(groupApiInfo())
+        SwaggerProperties swaggerProperties = swaggerProperties();
+        Docket docket = new Docket(DocumentationType.SWAGGER_2)
+                .apiInfo(apiInfo(swaggerProperties))
                 .select()
-                .apis(RequestHandlerSelectors.basePackage("com.lantone"))
+                .apis(RequestHandlerSelectors.basePackage(swaggerProperties.getApiBasePackage()))
                 .paths(PathSelectors.any())
                 .build();
-//                .securityContexts(Lists.newArrayList(securityContext(), securityContext1())).securitySchemes(Lists.<SecurityScheme>newArrayList(apiKey(), apiKey1()));
+        if (swaggerProperties.isEnableSecurity()) {
+            docket.securitySchemes(securitySchemes()).securityContexts(securityContexts());
+        }
+        return docket;
     }
 
-    private ApiInfo groupApiInfo() {
+    private ApiInfo apiInfo(SwaggerProperties swaggerProperties) {
         return new ApiInfoBuilder()
+                .title(swaggerProperties.getTitle())
+                .description(swaggerProperties.getDescription())
+                .contact(new Contact(swaggerProperties.getContactName(), swaggerProperties.getContactUrl(), swaggerProperties.getContactEmail()))
+                .version(swaggerProperties.getVersion())
+                .build();
+    }
+
+    private List<ApiKey> securitySchemes() {
+        //设置请求头信息
+        List<ApiKey> result = new ArrayList<>();
+        ApiKey apiKey = new ApiKey("Authorization", "Authorization", "header");
+        result.add(apiKey);
+        return result;
+    }
+
+    private List<SecurityContext> securityContexts() {
+        //设置需要登录认证的路径
+        List<SecurityContext> result = new ArrayList<>();
+        result.add(getContextByPath("/*/.*"));
+        return result;
+    }
+
+    private SecurityContext getContextByPath(String pathRegex) {
+        return SecurityContext.builder()
+                .securityReferences(defaultAuth())
+                .forPaths(PathSelectors.regex(pathRegex))
+                .build();
+    }
+
+    private List<SecurityReference> defaultAuth() {
+        List<SecurityReference> result = new ArrayList<>();
+        AuthorizationScope authorizationScope = new AuthorizationScope("global", "accessEverything");
+        AuthorizationScope[] authorizationScopes = new AuthorizationScope[1];
+        authorizationScopes[0] = authorizationScope;
+        result.add(new SecurityReference("Authorization", authorizationScopes));
+        return result;
+    }
+
+    public SwaggerProperties swaggerProperties() {
+        return SwaggerProperties.builder()
+                .apiBasePackage("com.lantone")
                 .title(swagger_title)
                 .description("<div style='font-size:14px;color:red;'>" + swagger_des + "--RESTful APIs</div>")
-                .termsOfServiceUrl("http://localhost:10751/doc.html")
-                .contact("894564193@qq.com")
+                .contactName("lantone")
                 .version(swagger_version)
+                .enableSecurity(true)
                 .build();
     }
 
-//    private ApiKey apiKey() {
-//        return new ApiKey("BearerToken", "Authorization", "header");
-//    }
-//
-//    private ApiKey apiKey1() {
-//        return new ApiKey("BearerToken1", "Authorization-x", "header");
-//    }
-//
-//    private SecurityContext securityContext() {
-//        return SecurityContext.builder()
-//                .securityReferences(defaultAuth())
-//                .forPaths(PathSelectors.regex("/.*"))
-//                .build();
-//    }
-//
-//    private SecurityContext securityContext1() {
-//        return SecurityContext.builder()
-//                .securityReferences(defaultAuth1())
-//                .forPaths(PathSelectors.regex("/.*"))
-//                .build();
-//    }
-//
-//    List<SecurityReference> defaultAuth() {
-//        AuthorizationScope authorizationScope = new AuthorizationScope("global", "accessEverything");
-//        AuthorizationScope[] authorizationScopes = new AuthorizationScope[1];
-//        authorizationScopes[0] = authorizationScope;
-//        return Lists.newArrayList(new SecurityReference("BearerToken", authorizationScopes));
-//    }
-//
-//    List<SecurityReference> defaultAuth1() {
-//        AuthorizationScope authorizationScope = new AuthorizationScope("global", "accessEverything");
-//        AuthorizationScope[] authorizationScopes = new AuthorizationScope[1];
-//        authorizationScopes[0] = authorizationScope;
-//        return Lists.newArrayList(new SecurityReference("BearerToken1", authorizationScopes));
-//    }
-
 }

+ 57 - 0
common/src/main/java/com/lantone/common/domain/SwaggerProperties.java

@@ -0,0 +1,57 @@
+package com.lantone.common.domain;
+
+import lombok.Builder;
+import lombok.Data;
+import lombok.EqualsAndHashCode;
+
+/**
+ * @Description:
+ * @author: rengb
+ * @time: 2021/7/13 14:36
+ */
+@Data
+@EqualsAndHashCode(callSuper = false)
+@Builder
+public class SwaggerProperties {
+
+    /**
+     * API文档生成基础路径
+     */
+    private String apiBasePackage;
+
+    /**
+     * 是否要启用登录认证
+     */
+    private boolean enableSecurity;
+
+    /**
+     * 文档标题
+     */
+    private String title;
+
+    /**
+     * 文档描述
+     */
+    private String description;
+
+    /**
+     * 文档版本
+     */
+    private String version;
+
+    /**
+     * 文档联系人姓名
+     */
+    private String contactName;
+
+    /**
+     * 文档联系人网址
+     */
+    private String contactUrl;
+
+    /**
+     * 文档联系人邮箱
+     */
+    private String contactEmail;
+
+}

+ 0 - 1
config-center/pom.xml

@@ -22,7 +22,6 @@
             <groupId>org.springframework.cloud</groupId>
             <artifactId>spring-cloud-starter-netflix-eureka-client</artifactId>
         </dependency>
-
     </dependencies>
 
     <build>

+ 5 - 5
dblayer-mbg/pom.xml

@@ -14,6 +14,10 @@
     <packaging>jar</packaging>
 
     <dependencies>
+        <dependency>
+            <groupId>com.lantone</groupId>
+            <artifactId>common</artifactId>
+        </dependency>
         <dependency>
             <groupId>com.alibaba</groupId>
             <artifactId>druid-spring-boot-starter</artifactId>
@@ -34,10 +38,6 @@
             <groupId>org.freemarker</groupId>
             <artifactId>freemarker</artifactId>
         </dependency>
-        <dependency>
-            <groupId>org.projectlombok</groupId>
-            <artifactId>lombok</artifactId>
-        </dependency>
     </dependencies>
 
-</project>
+</project>

+ 0 - 1
gateway-service/pom.xml

@@ -30,7 +30,6 @@
         <dependency>
             <groupId>com.github.xiaoymin</groupId>
             <artifactId>knife4j-spring-boot-starter</artifactId>
-            <version>1.9.6</version>
         </dependency>
         <dependency>
             <groupId>org.projectlombok</groupId>

+ 11 - 3
gateway-service/src/main/java/com/lantone/config/SwaggerHandler.java

@@ -15,7 +15,7 @@ import springfox.documentation.swagger.web.UiConfigurationBuilder;
 import java.util.Optional;
 
 /**
- * @Description:
+ * @Description: 自定义Swagger的各个配置节点
  * @author: rengb
  * @time: 2021/1/5 18:32
  */
@@ -35,22 +35,30 @@ public class SwaggerHandler {
         this.swaggerResources = swaggerResources;
     }
 
-
+    /**
+     * Swagger安全配置,支持oauth和apiKey设置
+     */
     @GetMapping("/swagger-resources/configuration/security")
     public Mono<ResponseEntity<SecurityConfiguration>> securityConfiguration() {
         return Mono.just(new ResponseEntity<>(
                 Optional.ofNullable(securityConfiguration).orElse(SecurityConfigurationBuilder.builder().build()), HttpStatus.OK));
     }
 
+    /**
+     * Swagger UI配置
+     */
     @GetMapping("/swagger-resources/configuration/ui")
     public Mono<ResponseEntity<UiConfiguration>> uiConfiguration() {
         return Mono.just(new ResponseEntity<>(
                 Optional.ofNullable(uiConfiguration).orElse(UiConfigurationBuilder.builder().build()), HttpStatus.OK));
     }
 
+    /**
+     * Swagger资源配置,微服务中这各个服务的api-docs信息
+     */
     @GetMapping("/swagger-resources")
     public Mono<ResponseEntity> swaggerResources() {
         return Mono.just((new ResponseEntity<>(swaggerResources.get(), HttpStatus.OK)));
     }
 
-}
+}

+ 0 - 35
gateway-service/src/main/java/com/lantone/config/SwaggerHeaderFilter.java

@@ -1,35 +0,0 @@
-package com.lantone.config;
-
-import org.apache.commons.lang.StringUtils;
-import org.springframework.cloud.gateway.filter.GatewayFilter;
-import org.springframework.cloud.gateway.filter.factory.AbstractGatewayFilterFactory;
-import org.springframework.http.server.reactive.ServerHttpRequest;
-import org.springframework.stereotype.Component;
-import org.springframework.web.server.ServerWebExchange;
-
-/**
- * @Description:
- * @author: rengb
- * @time: 2021/1/5 18:41
- */
-@Component
-public class SwaggerHeaderFilter extends AbstractGatewayFilterFactory {
-    private static final String HEADER_NAME = "X-Forwarded-Prefix";
-
-    private static final String URI = "/v2/api-docs";
-
-    @Override
-    public GatewayFilter apply(Object config) {
-        return (exchange, chain) -> {
-            ServerHttpRequest request = exchange.getRequest();
-            String path = request.getURI().getPath();
-            if (!StringUtils.endsWithIgnoreCase(path,URI )) {
-                return chain.filter(exchange);
-            }
-            String basePath = path.substring(0, path.lastIndexOf(URI));
-            ServerHttpRequest newRequest = request.mutate().header(HEADER_NAME, basePath).build();
-            ServerWebExchange newExchange = exchange.mutate().request(newRequest).build();
-            return chain.filter(newExchange);
-        };
-    }
-}

+ 5 - 4
gateway-service/src/main/java/com/lantone/config/SwaggerResourceConfig.java

@@ -14,7 +14,7 @@ import java.util.ArrayList;
 import java.util.List;
 
 /**
- * @Description:
+ * @Description: Swagger资源配置
  * @author: rengb
  * @time: 2021/1/5 18:27
  */
@@ -27,12 +27,13 @@ public class SwaggerResourceConfig implements SwaggerResourcesProvider {
     private final RouteLocator routeLocator;
     private final GatewayProperties gatewayProperties;
 
-
     @Override
     public List<SwaggerResource> get() {
         List<SwaggerResource> resources = new ArrayList<>();
         List<String> routes = new ArrayList<>();
+        //获取所有路由的ID
         routeLocator.getRoutes().subscribe(route -> routes.add(route.getId()));
+        //过滤出配置文件中定义的路由->过滤出Path Route Predicate->根据路径拼接成api-docs路径->生成SwaggerResource
         gatewayProperties.getRoutes().stream().filter(routeDefinition -> routes.contains(routeDefinition.getId())).forEach(route -> {
             route.getPredicates().stream()
                     .filter(predicateDefinition -> ("Path").equalsIgnoreCase(predicateDefinition.getName()))
@@ -45,7 +46,7 @@ public class SwaggerResourceConfig implements SwaggerResourcesProvider {
     }
 
     private SwaggerResource swaggerResource(String name, String location) {
-        log.info("name:{},location:{}",name,location);
+        log.info("name:{},location:{}", name, location);
         SwaggerResource swaggerResource = new SwaggerResource();
         swaggerResource.setName(name);
         swaggerResource.setLocation(location);
@@ -53,4 +54,4 @@ public class SwaggerResourceConfig implements SwaggerResourcesProvider {
         return swaggerResource;
     }
 
-}
+}

+ 4 - 6
gateway-service/src/main/resources/bootstrap.yml

@@ -15,20 +15,18 @@ spring:
           enabled: true
 #          lower-case-service-id: true
       routes:
-        - id:  structure-center
+        - id: structure-center
           uri: lb://structure-center
           predicates:
             - Path=/sc/**
           filters:
-            - SwaggerHeaderFilter
             - StripPrefix=1
-        - id:  security-center
+        - id: security-center
           uri: lb://security-center
           predicates:
-          - Path=/security/**
+            - Path=/security/**
           filters:
-          - SwaggerHeaderFilter
-          - StripPrefix=1
+            - StripPrefix=1
   #redis
   redis:
     database:

+ 1 - 2
monitor-service/pom.xml

@@ -21,7 +21,7 @@
         <dependency>
             <groupId>de.codecentric</groupId>
             <artifactId>spring-boot-admin-starter-server</artifactId>
-            <version>2.1.6</version>
+            <version>${spring-boot-admin-starter-server.version}</version>
         </dependency>
         <dependency>
             <groupId>org.springframework.cloud</groupId>
@@ -31,7 +31,6 @@
             <groupId>org.springframework.boot</groupId>
             <artifactId>spring-boot-starter-security</artifactId>
         </dependency>
-
     </dependencies>
 
     <build>

+ 84 - 7
pom.xml

@@ -31,6 +31,7 @@
     <properties>
         <java.version>1.8</java.version>
         <spring-cloud.version>Greenwich.SR3</spring-cloud.version>
+        <spring-boot-admin-starter-server.version>2.1.6</spring-boot-admin-starter-server.version>
         <mybatis-plus-boot-starter.version>3.2.0</mybatis-plus-boot-starter.version>
         <mysql-connector-java.version>8.0.18</mysql-connector-java.version>
         <ojdbc6.version>11.2.0.3</ojdbc6.version>
@@ -41,6 +42,15 @@
         <beetl.version>3.0.13.RELEASE</beetl.version>
         <lombok.version>1.18.8</lombok.version>
         <guava.version>28.1-jre</guava.version>
+        <knife4j-micro-spring-boot-starter.version>2.0.4</knife4j-micro-spring-boot-starter.version>
+        <commons-lang3.version>3.8.1</commons-lang3.version>
+        <fastjson.version>1.2.62</fastjson.version>
+        <gson.version>2.8.5</gson.version>
+        <commons-codec.version>1.11</commons-codec.version>
+        <poi.version>4.0.1</poi.version>
+        <commons-beanutils.version>1.9.3</commons-beanutils.version>
+        <common.version>0.0.1-SNAPSHOT</common.version>
+        <dblayer-mbg.version>0.0.1-SNAPSHOT</dblayer-mbg.version>
         <txlcn-tc.version>5.0.2.RELEASE</txlcn-tc.version>
         <txlcn-txmsg-netty.version>5.0.2.RELEASE</txlcn-txmsg-netty.version>
         <docker-maven-plugin.version>1.2.2</docker-maven-plugin.version>
@@ -58,6 +68,19 @@
                 <scope>import</scope>
             </dependency>
 
+            <!-- 通用模块 -->
+            <dependency>
+                <groupId>com.lantone</groupId>
+                <artifactId>common</artifactId>
+                <version>${common.version}</version>
+            </dependency>
+            <!-- MBG生成模块 -->
+            <dependency>
+                <groupId>com.lantone</groupId>
+                <artifactId>dblayer-mbg</artifactId>
+                <version>${dblayer-mbg.version}</version>
+            </dependency>
+
             <!-- mybatisplus 依赖 -->
             <dependency>
                 <groupId>com.baomidou</groupId>
@@ -115,8 +138,8 @@
                 <groupId>org.projectlombok</groupId>
                 <artifactId>lombok</artifactId>
                 <version>${lombok.version}</version>
-                <scope>provided</scope>
-                <optional>true</optional>
+                <!--<scope>provided</scope>-->
+                <!--<optional>true</optional>-->
             </dependency>
 
             <!-- 分布式事务框架 tx-lcn -->
@@ -131,15 +154,69 @@
                 <version>${txlcn-txmsg-netty.version}</version>
             </dependency>
 
+            <!-- 工具类jar包 -->
+            <dependency>
+                <groupId>com.google.guava</groupId>
+                <artifactId>guava</artifactId>
+                <version>${guava.version}</version>
+            </dependency>
+
+            <!-- Knife4j API文档生产工具 -->
+            <dependency>
+                <groupId>com.github.xiaoymin</groupId>
+                <artifactId>knife4j-micro-spring-boot-starter</artifactId>
+                <version>${knife4j-micro-spring-boot-starter.version}</version>
+            </dependency>
+            <dependency>
+                <groupId>com.github.xiaoymin</groupId>
+                <artifactId>knife4j-spring-boot-starter</artifactId>
+                <version>${knife4j-micro-spring-boot-starter.version}</version>
+            </dependency>
+
+            <dependency>
+                <groupId>org.apache.commons</groupId>
+                <artifactId>commons-lang3</artifactId>
+                <version>${commons-lang3.version}</version>
+            </dependency>
+
+            <dependency>
+                <groupId>com.alibaba</groupId>
+                <artifactId>fastjson</artifactId>
+                <version>${fastjson.version}</version>
+            </dependency>
+
+            <dependency>
+                <groupId>com.google.code.gson</groupId>
+                <artifactId>gson</artifactId>
+                <version>${gson.version}</version>
+            </dependency>
+
+            <dependency>
+                <groupId>commons-codec</groupId>
+                <artifactId>commons-codec</artifactId>
+                <version>${commons-codec.version}</version>
+            </dependency>
+
+            <!-- poi excel -->
+            <dependency>
+                <groupId>org.apache.poi</groupId>
+                <artifactId>poi</artifactId>
+                <version>${poi.version}</version>
+            </dependency>
+            <dependency>
+                <groupId>org.apache.poi</groupId>
+                <artifactId>poi-ooxml</artifactId>
+                <version>${poi.version}</version>
+            </dependency>
+            <dependency>
+                <groupId>commons-beanutils</groupId>
+                <artifactId>commons-beanutils</artifactId>
+                <version>${commons-beanutils.version}</version>
+            </dependency>
         </dependencies>
     </dependencyManagement>
 
     <dependencies>
-        <dependency>
-            <groupId>com.google.guava</groupId>
-            <artifactId>guava</artifactId>
-            <version>${guava.version}</version>
-        </dependency>
         <dependency>
             <groupId>org.springframework.boot</groupId>
             <artifactId>spring-boot-starter-actuator</artifactId>

+ 1 - 2
register-center/pom.xml

@@ -22,9 +22,8 @@
         <dependency>
             <groupId>de.codecentric</groupId>
             <artifactId>spring-boot-admin-starter-client</artifactId>
-            <version>2.1.6</version>
+            <version>${spring-boot-admin-starter-server.version}</version>
         </dependency>
-
     </dependencies>
 
     <build>

+ 1 - 3
security-center/pom.xml

@@ -104,8 +104,6 @@
             <groupId>org.apache.commons</groupId>
             <artifactId>commons-pool2</artifactId>
         </dependency>
-
     </dependencies>
 
-
-</project>
+</project>

+ 0 - 8
structure-center/pom.xml

@@ -17,9 +17,7 @@
         <dependency>
             <groupId>com.lantone</groupId>
             <artifactId>common</artifactId>
-            <version>0.0.1-SNAPSHOT</version>
         </dependency>
-
         <dependency>
             <groupId>org.springframework.boot</groupId>
             <artifactId>spring-boot-starter-web</artifactId>
@@ -36,12 +34,6 @@
             <groupId>org.springframework.cloud</groupId>
             <artifactId>spring-cloud-starter-openfeign</artifactId>
         </dependency>
-
-        <dependency>
-            <groupId>org.projectlombok</groupId>
-            <artifactId>lombok</artifactId>
-        </dependency>
-
     </dependencies>
 
     <build>