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

26th
Mar 2019
Davy De Waele
@ddewaele
Mar 26 09:38
Hi, I have a config server (Dalston.SR3), and I noticed that although I can pass -Dspring.cloud.config.server.git.default-label=foo, I cannot pass an environment variable SPRING_CLOUD_CONFIG_SERVER_GIT_DEFAULTLABEL=foo to specify the default label. Is there a reason why this would only work with system properties ?
Passing the environment variable SPRING_PROFILES_ACTIVE works fine. But for the spring cloud config params only system properties seem to work
s-spindler
@s-spindler
Mar 26 09:43
@dave-fl Hi Dave, thanks for the link! That's what I found but what I'm missing is how to return execution to Spring Cloud Gateway's scheduler after "dispatching" the background task to another scheduler. I suppose all I would need to do is do another publishOn on the defautl scheduler, but how do I get that scheduler?
Davy De Waele
@ddewaele
Mar 26 10:06
Seems like I need to use SPRING_CLOUD_CONFIG_SERVER_GIT_DEFAULT_LABEL instead of SPRING_CLOUD_CONFIG_SERVER_GIT_DEFAULTLABEL. I got confused by the relaxed binding section of the docs where they seem to suggest that ACME_MYPROJECT_PERSON = acme.my-project.person
Olga Maciaszek-Sharma
@OlgaMaciaszek
Mar 26 10:07
ok. So it's working fine @ddewaele ?
btw., Dalston is out of support already, we recommend upgrading to a newer release train.
Davy De Waele
@ddewaele
Mar 26 10:08
yes, except for the confusion in the docs where they say : ACME_MYPROJECT_PERSON_FIRSTNAME : Upper case format, which is recommended when using system environment variables. Notice how MYPROJECT seems to map to my-project
Olga Maciaszek-Sharma
@OlgaMaciaszek
Mar 26 10:10
yes. we should probably fix the doc; could you send me the link?
Davy De Waele
@ddewaele
Mar 26 10:12
it's in the previous message (relaxed binding link). I assume this type of stuff always falls back to https://github.com/spring-projects/spring-framework/blob/master/spring-core/src/main/java/org/springframework/core/env/SystemEnvironmentPropertySource.java where I always see . and - converted to _
But I'm still on spring boot 1.x .... I think there were some changes in 2.x (https://spring.io/blog/2018/03/28/property-binding-in-spring-boot-2-0)
Davy De Waele
@ddewaele
Mar 26 10:24
@OlgaMaciaszek : think docs are ok ... .the 1.5.10.RELEASE docs show a different example : https://docs.spring.io/spring-boot/docs/1.5.10.RELEASE/reference/htmlsingle/#boot-features-external-config-relaxed-binding
Olga Maciaszek-Sharma
@OlgaMaciaszek
Mar 26 11:21
ok. thanks. Please consider upgrading your Spring stack :) we don't do any fixes or service upgrades for Dalston anymore
Chris Overgaauw
@chrisovergaauw
Mar 26 18:31
I'm still working based on this example
the resource server responds with 401. Does anyone have tips for debugging webflux security?
I don't know if it is receiving a token, what is in it and hence why any of the hasRole/hasAuthority filters fail.