我是Spring Cloud的新手,我的目标是连接本地git repo(Windows机器->在文件夹Z:/ Spring_boot_cloud_microservices_udemy / Projects / local-git-repo /中创建)。但是,当我输入其相应的URL(http://localhost:8888/limit-services/default)我正在获取默认的eclipse的whitelabel错误页面时,有人可以让我确定我的错误吗。
以下是创建的项目:其中极限服务是微服务之一
以下是其对应的代码:
1] application.properties(限制服务->微服务)]]
spring.application.name=limit-services
server.port=8081
# custom limits to access for config properties
limit-service.minlimit=121
# custom limits to access for config properties
limit-service.maxlimit=1
2] application.properties(spring-cloud-config-server)]]
spring.application.name=spring-cloud-config-server
server.port=8888
spring.cloud.config.server.git.uri=file://Z:/Spring_boot_cloud_microservices_udemy/Projects/local-git-repo/
3] Spring Boot主类(spring-cloud-server):
@EnableConfigServername
@SpringBootApplication
public class SpringConfigCloudServerApplication {
public static void main(String[] args) {
System.setProperty("spring.devtools.restart.enabled", "false");
SpringApplication.run(SpringConfigCloudServerApplication.class, args);
}
}
4]链接到Spring-cloud-server的本地git存储库:
5]击中以下URL捕获的日志是:http://localhost:8888/limit-services/default
2020-05-15 07:22:03.943 INFO 30412 --- [ main] c.s.s.SpringConfigCloudServerApplication : Started SpringConfigCloudServerApplication in 13.168 seconds (JVM running for 14.341)
2020-05-15 07:22:11.689 INFO 30412 --- [nio-8888-exec-1] o.a.c.c.C.[Tomcat].[localhost].[/] : Initializing Spring DispatcherServlet 'dispatcherServlet'
2020-05-15 07:22:11.690 INFO 30412 --- [nio-8888-exec-1] o.s.web.servlet.DispatcherServlet : Initializing Servlet 'dispatcherServlet'
2020-05-15 07:22:11.700 INFO 30412 --- [nio-8888-exec-1] o.s.web.servlet.DispatcherServlet : Completed initialization in 10 ms
2020-05-15 07:22:11.953 INFO 30412 --- [nio-8888-exec-1] .c.s.e.MultipleJGitEnvironmentRepository : Cannot pull from remote null, the working tree is not clean.
我是Spring Cloud的新手,我的目标是将本地git repo(Windows机器->在文件夹Z:/ Spring_boot_cloud_microservices_udemy / Projects / local-git-repo /中创建)连接到Spring Cloud Server。但是...