Browse Source

second init

qrs 1 month ago
parent
commit
9bff320c82

+ 1 - 1
alien-gateway/pom.xml

@@ -220,7 +220,7 @@
                 <groupId>org.springframework.boot</groupId>
                 <artifactId>spring-boot-maven-plugin</artifactId>
                 <configuration>
-                    <mainClass>shop.alien.gateway.GatewayApplication</mainClass>
+                    <mainClass>shop.alien.gateway.AlienGatewayApplication</mainClass>
                     <layout>ZIP</layout>
                     <includes>
                         <include>

+ 2 - 2
alien-gateway/src/main/java/shop/alien/gateway/GatewayApplication.java → alien-gateway/src/main/java/shop/alien/gateway/AlienGatewayApplication.java

@@ -15,7 +15,7 @@ import org.springframework.context.annotation.ComponentScan;
 @ComponentScan({"shop.alien.gateway.*"})
 @MapperScan({"shop.alien.gateway.mapper","shop.alien.entity.system.mapper"})
 @SpringBootApplication
-public class GatewayApplication {
+public class AlienGatewayApplication {
 
     public static void main(String[] args) {
         /*因为Spring Boot本身已经集成了日志框架Logback,而在Alibaba Nacos中又集成了一套Logback框架
@@ -23,7 +23,7 @@ public class GatewayApplication {
         所以,在项目启动时,Alibaba Nacos的Logback先加载完成后,再加载项目本身的Logback时就出现了冲突,报错误日志 “ Failed to rename context [logback] as [nacos] java.lang.IllegalStateException: Context has been already given a name ” ,但是不影响使用,
         解决这个,只要禁用掉其中一个Logback就可以了,一般禁用外部框架夹带的Logback即可*/
         System.setProperty("nacos.logging.default.config.enabled", "false");
-        SpringApplication.run(GatewayApplication.class, args);
+        SpringApplication.run(AlienGatewayApplication.class, args);
     }
 
 }