These are chat archives for spring-cloud/spring-cloud

21st
Jul 2016
Dreampie
@Dreampie
Jul 21 2016 08:32

@dsyer spring-cloud/spring-cloud-netflix#1194

private String encodeIfNotVariable(String in) {
    if (in == null || in.indexOf('{') == 0) {
      return in;
    }
    return urlEncode(in);
  }

if I send parameter contains {,not encode it ?

Dreampie
@Dreampie
Jul 21 2016 08:40
my parameter is json string , so contians {json},that is feign‘s variable fomater
Włodzimierz Rożkow
@rozhok
Jul 21 2016 09:14
hey there..
i'm researching now capabilities of canary releases
My case
one env, 20 different services
they talk to each other using eureka/ribbon/feign
one edge service which re-routes requests
I'm wondering how hard will be implement following
I deploy new version of service 1
all requests going to old version
if I have some flag (maybe header in request) it will be re-routed to new version of service 1
next, I'm going to release new version of service 2
I want new version of service 2 to talk with new version of service 1
Włodzimierz Rożkow
@rozhok
Jul 21 2016 09:19
then I'm testing stuff
and redeploy rest of services
and remove "canary" flags
how hard will be to do this? I need very rough estimate.
what I thinking about was write down some Zuul filters, put metadata into eureka registry, analyze metadata on ribbon side, something like this
Just can't imagine right now how much of code I need to override to do this
Dave Syer
@dsyer
Jul 21 2016 09:26
Shouldn't be too much. @ryanjbaxter will help you (he wants to write a blog about it and maybe add some features to Spring Cloud).
Matt Benson
@mbenson
Jul 21 2016 16:22
so the thing I brought up yesterday seems like a @dsyer thing... since you are the author of record for PropertySourceBootstrapConfiguration. For example, the ConfigServicePropertySourceLocator returns profile documents picked up due to a spring.profiles.include property returned by the config service. Now, I don't really think it makes sense that spring.profiles.active could be modified in the PSBC, but it would seem a straightforward code change to pick up spring.profiles.include after modifying the [Configurable]Environment.
(if one that requires a bit of code duplication from e.g. ConfigFileApplicationListener)
Dave Syer
@dsyer
Jul 21 2016 17:29
I didn't really follow what the problem was, sorry.
But if you think you can solve it, go ahead
Marcos Barbero
@marcosbarbero
Jul 21 2016 21:51
is there a way to spring cloud stream rabbitmq creates exchanges?
Marcos Barbero
@marcosbarbero
Jul 21 2016 22:44
Nevermind, it's working fine
Ali Moghadam
@alighm
Jul 21 2016 23:28
Hi Spensor, It’s a pleasure to meet you Sir! I had a quick question for you. I am using Spring Cloud in building a Common Services Framework for all of our Microservices to use, in my journey I came across to use the DiscoveryClient. My Service Discovery is Consul and I see that the client does not have any read or writing of Key/Values. I ended up creating a separate interface called CustomDiscoveryClient and having a Consul implementation of it and wiring the bean up the same way that the ConsulDiscoveryClient is wired up. In my bean I’m exposing the ConsulClient’s setKVValue. I was wondering if the getter and setters for key/value would be added to the SD Client?
Ali Moghadam
@alighm
Jul 21 2016 23:34
I’m doing this because once my microservice is up, it registers with Consul. Now when a API call is done to my service, it will be via client load balancer (i.e. FeignClient) on top of that, my service is a “Resource Server” so it’s protected via OAuth2 JWT tokens. I am setting a flag in consul key/value so that when the Client Load Balancer grabs an instance from Consul, it will also give the flag along as well. Then my code will know to call the Auth Service (custom api) to gain the clientId and clientSecret in order to have the caller use the credentials to get a token from the Auth Service. Sorry for the long message lol
I guess that leads to me asking, how I can place a hook into ribbon to also get back key/values of a service registered with Consul….