The new info endpoint doesn't need special treatment to pick up
changes in the Environment, so we can just skip installing the
old bean that manipulates it.
Fixes gh-108
Users now need to create their own bean and qualify it, and Spring
Cloud will customize it (instead of providing the @Bean itself).
This is much better for users, since they remain in control of the
bean declarations, and can choose which one (if any) is @Primary.
It's a breaking change for some apps (if they rely on a
@LoadBalanced RestTemplate being automatically injected).
When the bootstrap properties are added back into the main Environment
we have to be careful that any source that is already there (such as
one that was added in a Spring Boot EnvironmentPostProcessor) is not
replaced in the wrong order.
Fixes gh-90
Use SystemEnvironmentPropertySource so that env vars can be
encrypted as well as property values (i.e. FOO_BAR will bind to
@Value("foo.bar")).
Fixes gh-89, fixes gh-87
When the RefreshEndpoint makes a new Environment it creates a new
ApplicationContext with (hopefully) empty sources. If the user has
set spring.main.sources it won't be empty, so we should take care
to mask it off in the process.
Fixes gh-79
Repots DOWN if there are errors in RefreshScope or
ConfigurationProperties rebinding, N.B. RefreshScope instantiates
its beans lazily after a refresh by default, so you won't see an
error until the bean is used.
Fixes gh-85
The fact that PropertySourceBootstrapConfiguration was re-using the
"bootstrap" property source name from the listener was a problem. The
listener has to be able to manage its own temporary property source name.
Fixes gh-83