mirror of
https://github.com/spring-projects/spring-boot.git
synced 2024-07-15 01:07:30 +08:00
Document that failure analyzers should use constructor injection
Closes gh-39099
This commit is contained in:
parent
c1495bca33
commit
f4ff2e63ff
@ -23,7 +23,7 @@ The following example registers `ProjectConstraintViolationFailureAnalyzer`:
|
||||
com.example.ProjectConstraintViolationFailureAnalyzer
|
||||
----
|
||||
|
||||
NOTE: If you need access to the `BeanFactory` or the `Environment`, your `FailureAnalyzer` can implement `BeanFactoryAware` or `EnvironmentAware` respectively.
|
||||
NOTE: If you need access to the `BeanFactory` or the `Environment`, declare them as constructor arguments in your `FailureAnalyzer` implementation.
|
||||
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user