Skip to content

Conversation

OlgaMaciaszek
Copy link
Collaborator

No description provided.

@OlgaMaciaszek OlgaMaciaszek added this to the 4.1.0-M2 milestone Sep 20, 2023
@OlgaMaciaszek OlgaMaciaszek self-assigned this Sep 20, 2023
@OlgaMaciaszek OlgaMaciaszek marked this pull request as draft September 20, 2023 10:01
synchronized (lifecycleMonitor) {
if (!isRunning()) {
if (LOG.isDebugEnabled()) {
LOG.debug("Refreshing context on restart.");
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'd say this is important enough for info rather than debug

@OlgaMaciaszek OlgaMaciaszek marked this pull request as ready for review September 20, 2023 15:26
@OlgaMaciaszek
Copy link
Collaborator Author

@Buzzardo could you please take a look at the doc changes?

@OlgaMaciaszek OlgaMaciaszek merged commit 9449edf into main Sep 21, 2023
[refresh-scope-on-restart]
=== Refresh Scope on Restart

In order to allow seamlessly refreshing beans on restart, which is especially useful for applications running with JVM Checkpoint Restore (for example with https://github.com/CRaC[Project CRaC]), we now instantiate a `RefreshScopeLifecycle` bean that will trigger Context Refresh on restart, resulting in rebinding configuration properties and refreshing any `@RefreshScope`-annotated beans. This behaviour can be disabled by setting the value of `spring.cloud.refresh.on-restart.enabled` to `false`.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That long and complex sentence is hard to parse in one pass, so please change it to:

Seamlessly refreshing beans on restart is especially useful for applications that run with JVM Checkpoint Restore (such as https://github.com/CRaC[Project CRaC]). To allow this ability, we now instantiate a RefreshScopeLifecycle bean that triggers Context Refresh on restart, resulting in rebinding configuration properties and refreshing any beans annotated with @RefreshScope. You can disable this behavior by setting spring.cloud.refresh.on-restart.enabled to false.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @Buzzardo - will change.

@OlgaMaciaszek OlgaMaciaszek deleted the refresh-scope-on-restart branch November 13, 2023 18:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

No open projects
Status: Done
Status: In Progress

Development

Successfully merging this pull request may close these issues.

3 participants