Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Apply a setter for the logger field of RetryTemplate so that it doesn't need to be injected via reflections #470

Closed
klopfdreh opened this issue Sep 16, 2024 · 0 comments · Fixed by #471
Milestone

Comments

@klopfdreh
Copy link
Contributor

klopfdreh commented Sep 16, 2024

Currently there is a workaround in Spring Cloud Config (spring-cloud/spring-cloud-config#2456) that sets the logger of RetryTemplate via reflections. There should be a setter for the logger.

By fixing this issue the setter is applied to the RetryTemplate.

@klopfdreh klopfdreh changed the title Enable RetryTemplate for reflections to be used at Spring Boot Native images (aot) Apply a setter for the logger field of RetryTemplate so that it doesn't need to be injected via reflections Sep 19, 2024
@artembilan artembilan added this to the 2.0.10 milestone Sep 19, 2024
artembilan pushed a commit that referenced this issue Sep 19, 2024
GH-470: Add `RetryTemplate.setLogger()` to avoid reflection in other places

Fixes: #470
Issue link: #470

Spring Cloud Config does mutation in the `RetryTemplate` for its system loading logger via `RetryTemplateFactory`.

* Expose setter for `logger` property to avoid reflection.
* Add `RetryTemplateBuilder.withLogger()` for convenience
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants