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

Nov 2016
Felipe Adorno
Nov 04 2016 01:25
Hi guys, anybody can helpe me, I have a problem with use ISO DATE_TIME and feign
I created dateformater and used FeignFormatterRegistrar to register but the date isn't formated
any idea?
My formater
    public FeignFormatterRegistrar localDateFeignFormatterRegistrar() {
        return formatterRegistry -> {
            DateTimeFormatterRegistrar registrar = new DateTimeFormatterRegistrar();
Felipe Adorno
Nov 04 2016 01:31
My feign method
PagedResources<ReceivableResource> getReceivables(
            @RequestParam("createAt") Date createAt,
            @RequestParam("paymentDate") Date paymentDate);
Felipe Adorno
Nov 04 2016 04:11
I have one more question, how I use Patch in feign?
Stian Lågstad
Nov 04 2016 13:55
What is the recommended way to use spring-cloud-config when we have several environments with different config settings? We have dev, test, staging and production. Right now we have four branches (and we're using labels), but for changes we have to change things in 4 different places.
I think we'd prefer to separate the environments with filenames, for ex bootstrap-staging.yml and bootstrap-test.yml. But those are used for spring profiles, is that right?
Dave Syer
Nov 04 2016 13:57
Yes. It's the same thing by default.
Obviously you only need to put things that change between environment in the environment-specific places
Well, not the same thing.
But if you run an app in the "staging" profile it asks for config in that profile.
Branches are more for versioning and rollbacks
Not really so much useful for environments (as you have noticed)
Stian Lågstad
Nov 04 2016 14:02
Thanks! :)
Matthieu Bertin .tgz
Nov 04 2016 16:19
Hey there, has anyone here been confronted with random bugs with escaping placeholders in yml configuration files for spring cloud config? I have, in the same run, some correctly forwarded placeholders, and others who got resolved and prefixed with \….
Dave Syer
Nov 04 2016 16:21
Doesn't sound random to me
"\" is used to escape the placeholder in a config server
Maybe you have a config server that is incorrectly configured?
Matthieu Bertin .tgz
Nov 04 2016 16:24
no no
in both cases, it was meant to be forwarded to the clients without resolving, therefore, in both cases, they were like:
thing: \${ENV_VAR_THING:defThing}
other: \${ENV_VAR_OTHER:defOther}
and i get:
thing: \defThing
other: ${ENV_VAR_OTHER:defOther}
Dave Syer
Nov 04 2016 16:40
Looks like ENV_VAR_THING was replaced because it was in the OS env vars
and ENV_VAR_OTHER was not
It's not likely to be random.
Nov 04 2016 16:59
Hey..How can i pass eureka.client.serviceUrl.defaultZone at run time while running my war on server..i.e for port we use --server.port=xxxx...Similar way works ?
Matthieu Bertin .tgz
Nov 04 2016 17:12
therefore i would have gotten thing: value_of_env_var_thing rather than def value. but ill make sure of it again, sounds fair.
Matthieu Bertin .tgz
Nov 04 2016 17:41
hoeaaan :(