You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I set a breakpoint in ParameterStorePropertySource Line 45 to see if the parameter "testCount" contains the changed value from the parameter store.
This is the case.
But unfortunately the bean, which is using 'testCount' isn't updated.
@Configuration
@RefreshScope
public class TestConfiguration {
@Value("${testCount}")
private Integer testCount;
public Integer getTestCount() {
return this.testCount;
}
}
@Component
@EnableScheduling
public class TestBean {
private static final Logger LOGGER = LoggerFactory.getLogger(TestBean.class);
@Autowired
private TestConfiguration config;
@Scheduled(fixedDelay = 5000)
public void message() {
System.out.println("The message is: " + config.getTestCount());
}
}
Any ideas why this could be?
Do I still need the spring actuator endpoint "refresh"?
management.endpoints.web.exposure.include=refresh
I tried using it, but it didn't do anything.
The text was updated successfully, but these errors were encountered:
Perhaps there's something else wrong. I am happy to take a look but please create such a repo like the one i did so that i can easily run it and see what's not working
Type: Bug
Component:
spring-cloud-aws-parameter-store Version 3.1.0
Describe the bug
I am currently trying to migrate the Spring Cloud AWS dependencies from 2.4.4 to 3.1.0.
The Spring Boot Version we are using is 3.2.2
We use the AWS Parameter Store to obtain the application parameters.
Here is the configuration for that:
So far everything fits, except the refresh of properties in @Refreshscope annotated beans isn't working.
In the debug output I see that the task runs every 15 seconds.
I set a breakpoint in ParameterStorePropertySource Line 45 to see if the parameter "testCount" contains the changed value from the parameter store.
This is the case.
But unfortunately the bean, which is using 'testCount' isn't updated.
Any ideas why this could be?
Do I still need the spring actuator endpoint "refresh"?
management.endpoints.web.exposure.include=refresh
I tried using it, but it didn't do anything.
The text was updated successfully, but these errors were encountered: