spring-cloud / spring-cloud/spring-cloud-commons

@RefreshScope breaks SmartLifecycle

Open
#118 1 comment 10 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

waiting for votes
Dominant language
Java
Stars
751
Forks
744
Avg merge
1d 14h
Merged PRs (30d)
9

Description

A SmartLifecycle (or probably Lifecycle) bean annotated with @RefreshScope and isAutoStartup() returns true will not call start(). See https://github.com/dturanski/spring-cloud-refresh-scope-lifecycle

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the reproduction linked in the issue, focusing on the @RefreshScope bean and its SmartLifecycle or Lifecycle implementation. Trace how isAutoStartup() and refresh-scope initialization interact, then verify that an auto-startup lifecycle bean receives start() after the fix using the reproduction.

Written by the indexing model from the issue text.

Assessment

Tech stack
java, spring, spring-boot
Domain
backend, cloud
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.