spring-cloud

java.util.NoSuchElementException: No value bound启动报错

不想你离开。 提交于 2019-12-14 18:35:51
D:\Tool\JDK\bin\java.exe -XX:TieredStopAtLevel=1 -noverify -Dspring.output.ansi.enabled=always -Dcom.sun.management.jmxremote -Dcom.sun.management.jmxremote.port=53920 -Dcom.sun.management.jmxremote.authenticate=false -Dcom.sun.management.jmxremote.ssl=false -Djava.rmi.server.hostname=localhost -Dspring.liveBeansView.mbeanDomain -Dspring.application.admin.enabled=true -javaagent:D:\solf\IdeaIU_2018\lib\idea_rt.jar=53921:D:\solf\IdeaIU_2018\bin -Dfile.encoding=UTF-8 -classpath D:\Tool\JDK\jre\lib\charsets.jar;D:\Tool\JDK\jre\lib\deploy.jar;D:\Tool\JDK\jre\lib\ext\access-bridge-64.jar;D:\Tool

Linking between objects on different apps with Spring HATEOAS

﹥>﹥吖頭↗ 提交于 2019-12-14 02:50:19
问题 I'm investigating spring-cloud and I've set up two microservices "offers" and "customers" as eureka clients. The customers app has: @Data public class Customer extends ResourceSupport { private Long customerId; private String name; } @RestController @RequestMapping("/customers") @ExposesResourceFor(Customer.class) public class CustomersController { ... } and the offers app has: @Data public class Offer extends ResourceSupport { private final Long offerId; private final Long priceI; private

路由方式和过滤器

只谈情不闲聊 提交于 2019-12-14 00:55:01
采用服务名称指定路由方式 1.1使用服务名称指定路由的规则是什么? 1)serviceId ##规则:zuul.routes.路径名.path ##规则:zuul.routes.路径名.serviceId=eureka 的服务名 2)#zuul.routes 后面跟着的是服务名,服务名后面跟着的是路径规则,这种 配置方式更简单。 zuul.routes.e-book-product-provider.path=/suibian/** 1.2需改配置文件,将路由规则修改为使用服务名称路由。 路由的排除方法 2.1什么是路由排除法? 排除不需要的服务 1)指定服务 #zuul.ignored-services=服务的名称 2)关闭所有的服务,单独放行需要的服务 #zuul.ignored-services=* #zuul.routes.e-book-order-provider.path=/服务的名称 2.2修改配置文件,将路由规则修改为添加前缀法。 zuul.prefix=/suibian zuul.routes.e-book-product-provider.path=/服务的名称/ 自定义网关过滤器 3.1创建一个Maven的jar项目。 3.2 修改POM文件,添加Zuul启动器。 <dependency> <groupId>org.springframework.cloud<

Configuring catalog items through manifest.yml file

蓝咒 提交于 2019-12-13 20:47:54
问题 Using spring-cloud-cloudfoundry-service-broker we developed a service broker . Initially we defined catalog items within application.yml file which gets bundled inside jar and this all works great. Instead of bundling catalog items within jar file, we thought of supplying through manifest.yml file while pushing the service to cloud foundry . But unfortunately application is not getting the catalog items specified in manigest.yml file. Could you please let us know how do we supply catalog

SpringCloud - ConfigServer - RabbitMQ - Client doesn't receive message from ConfigService

拟墨画扇 提交于 2019-12-13 17:22:24
问题 I'm trying to make a ConfigServer Remote and Client with Gitlab repository. The ConfigServer receives the notification of push through a Webhooks, but it doesn´t send the message to the client. I run a RabbitMQ with Docker, and I can see in the rabbit's console that the services are connected with it. So I don´t know what is the problem. The configServer pom file looks like: <dependency> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-web</artifactId> </dependency>

Spring cloud config client without auto configuration

孤者浪人 提交于 2019-12-13 15:19:11
问题 First, please allow me to acknowledge that I am new to Spring and also there are a few questions (Spring Cloud Config Client Without Spring Boot and spring-cloud-config client without Spring Boot) out there on Spring Cloud Config Client without Spring Boot. However, mine is a, well, a bit different...:) I definitely want to use Spring Config Client without Boot if possible. I have been trying it over the last couple of days and failed. If you have any examples, I would like to see. I can

Can I host JSON file in Spring Cloud Config Server?

我是研究僧i 提交于 2019-12-13 13:20:12
问题 We are using Spring Cloud Config Server to host all configurations for our Spring Boot applications. We want a huge JSON text to be retrieved from the Config Server. Our current approach is to define the json text as a property value myproperty.jsontext="{'name':'value'}" Apart from defining the JSON text as a property value, is there any way to host & fetch it from the config server ? Does Spring Cloud Config Server support a .json file ? Update (additional Question): Can i access the

Multiple resource server oauth2 clients? Spring OAuth2 SSO

狂风中的少年 提交于 2019-12-13 12:07:34
问题 Good day, I have setup a working example implementing SSO & the API Gateway pattern (similar to what is described here https://spring.io/guides/tutorials/spring-security-and-angular-js/#_the_api_gateway_pattern_angular_js_and_spring_security_part_iv). The system consists of separate server components: AUTH-SERVER, API-GATEWAY, SERVICE-DISCOVERY, RESOURCE/UI SERVER. At the API-GATEWAY (implemented with Spring Boot @EnableZuulProxy @EnableOAuth2Sso) I have configured multiple OAuth providers,

Spring Cloud Config - Could not resolve placeholder

时光怂恿深爱的人放手 提交于 2019-12-13 06:54:32
问题 Background I am trying to add centralized configuration support to a medium sized spring based application. I recently made it Bootiful :D It can now run as a jar in an embedded tomcat though with the same old configuration files as before. So next I want to get rid of the filesystem property-files. I have the Config server setup and working, backed by a git repo containing the configuration. Problem During startup my application indicates that a property source is found on the config server.

Unable to download/import package org.springframework.cloud.config.server.EnableConfigServer

怎甘沉沦 提交于 2019-12-13 03:40:00
问题 I'm new to spring-cloud concepts and had followed each and every step of spring cloud document provided by spring.io https://spring.io/guides/gs/centralized-configuration/ weird thing is when I do clt+space on spring-cloud- in my STS, I don't see any option to add spring-cloud-starter-config dependency in pom.xml file, as a result I couldn't able to import the package org.springframework.cloud.config.server.EnableConfigServer in my class file. I'm not understanding what would be the reason