主要是学习spring-cloud
- ConfigServer
- EurekaServer
- EurekaClient1或EurekaClient2或ZuulGateway
Eureka Server 注册中心
目前使用9080端口
测试ConfigurationPropertieshttp://localhost:9080/testConfigurationProperties
测试链接http://localhost:9080/test
测试配置中心链接http://localhost:9080/testConfig返回配置中“application”的值
Eureka Client 服务提供者
目前使用9081端口
测试链接http://localhost:9081/testClient1,随机等待0-4秒再返回
Eureka Client 服务使用者
目前使用9082端口
测试链接(使用RestTemplate)http://localhost:9082/restTemplate2to1
测试链接(使用Feign)http://localhost:9082/feign2to1
经过hystrix的,http://localhost:9082/testCircuitBreaker2To1
config 配置服务器
目前使用8888端口
配置来自自己的github-repo CloudLearning-Config
网关服务器
目前使用9090端口
自动配置的按service-id的反向代理
下述2个链接,注意访问的是gateway,中间一层是service-id
测试链接,通过gateway的1,http://localhost:9090/eurekaclient1/testClient1
测试链接,通过gateway的2,http://localhost:9090/eurekaclient2/feign2to1
- gradle
- spring-boot
- spring-cloud
eureka server & client
config server & client
zuul gateway
sleuth & zipkin hystrix