SpringCloud微服务系列博客:
SpringCloud微服务之快速搭建EurekaServer:https://blog.csdn.net/egg1996911/article/details/78787540
SpringCloud微服务之集成thymeleaf访问html页面/静态页面&热部署:https://blog.csdn.net/egg1996911/article/details/78885045
SpringCloud微服务之部署SpringBoot项目至Linux服务器(CentOS):https://blog.csdn.net/egg1996911/article/details/78975945
SpringCloud微服务之使用SpringBoot搭建后端服务&配置MyBatis框架:https://blog.csdn.net/egg1996911/article/details/80215554
SpringCloud微服务之跨服务调用后端接口:https://blog.csdn.net/egg1996911/article/details/80369182
继之前介绍了如何搭建EurekaServer后,现在介绍如何注册服务至eureka上:
1. 新建Project/Module(如果使用Intellij的话,推荐在原来的Project中新建Module,这样就可以同时查看多个微服务工程)
2. 修改pom.xml
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>

本文详细介绍了如何将SpringCloud微服务注册到Eureka Server,包括新建Project/Module,修改pom.xml,application.properties配置,启用@EnableDiscoveryClient注解,以及启动和查看注册服务。同时提到,未启动Eureka时,微服务也可单独调试,但会报找不到服务器异常。

654

被折叠的 条评论
为什么被折叠?



