springCloud(二) eureka客户端搭建
2021-01-16 10:11
标签:java desc 文件 framework conf snapshot des eureka ups springCloud(二) eureka客户端搭建 标签:java desc 文件 framework conf snapshot des eureka ups 原文地址:https://www.cnblogs.com/guhualin/p/12926810.html1:pom.xml
2.applocation.yml 文件
server:
port: 80
spring:
application:
name: order-service
eureka:
client:
service-url:
defaultZone:
http://localhost:8761/eureka/
3.启动类
package com.imooc.EurekaClient;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.cloud.netflix.eureka.EnableEurekaClient;
@SpringBootApplication
@EnableEurekaClient
public class EurekaClientApplication {
public static void main(String[] args) {
SpringApplication.run(EurekaClientApplication.class, args);
}
}
4.效果图
上一篇:java8中的排序
文章标题:springCloud(二) eureka客户端搭建
文章链接:http://soscw.com/index.php/essay/42658.html