Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Allow overriding phase in RedisMessageListenerContainer #3208

Open
Assignees
Labels
@eye-dee

Description

Title: Allow overriding phase in RedisMessageListenerContainer

Description:
Currently, RedisMessageListenerContainer uses the default SmartLifecycle phase of Integer.MAX_VALUE.
This makes it difficult to control startup/shutdown ordering relative to other SmartLifecycle beans in the application.

In some scenarios, developers may want to ensure that certain beans start after the Redis listener container is fully initialized, or conversely, that the container waits until other infrastructure is ready before starting. Since the phase is not configurable, fine-grained lifecycle control is not possible.

Proposal:
Introduce the ability to override the phase of RedisMessageListenerContainer, for example by:

  • Exposing a setPhase(int phase) method

Use case:

  • Ensuring custom initialization logic (that depends on the container being ready) runs after the container is started.
  • Aligning the container’s lifecycle with other messaging or connection beans that also implement SmartLifecycle.

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      AltStyle によって変換されたページ (->オリジナル) /