File tree Expand file tree Collapse file tree 1 file changed +33
-0
lines changed Expand file tree Collapse file tree 1 file changed +33
-0
lines changed Original file line number Diff line number Diff line change @@ -271,6 +271,39 @@ spring:
271
271
272
272
-Xloggc:/opt/logs/gc.log -verbose.gc
273
273
274
+ ### 4.1 切换支持单Nacos
275
+
276
+ 将moss-service/pom.xml中的依赖修改如下
277
+
278
+ ` ` ` xml
279
+ <dependency>
280
+ <groupId>org.xujin.moss</groupId>
281
+ <artifactId>moss-adapter-multi-eureka</artifactId>
282
+ <version>1.0.0.RELEASE</version>
283
+ </dependency>
284
+ ```
285
+ 修改为
286
+ ``` xml
287
+ <dependency >
288
+ <groupId >org.xujin.moss</groupId >
289
+ <artifactId >moss-adapter-single-nacos</artifactId >
290
+ <version >1.0.0.RELEASE</version >
291
+ </dependency >
292
+ ```
293
+
294
+ 主入口程序代码修改打开
295
+
296
+ ``` java
297
+ /**
298
+ * 单nacos或单eureka需要把@EnableDiscoveryClient注释打开
299
+ */
300
+ @EnableDiscoveryClient
301
+ @ComponentScan (" org.xujin.moss.*" )
302
+ public class MossApplication {
303
+
304
+ }
305
+ ```
306
+
274
307
275
308
## 5.致谢
276
309
You can’t perform that action at this time.
0 commit comments