-
Notifications
You must be signed in to change notification settings - Fork 6.1k
Open
Labels
status: waiting-for-triageAn issue we've not yet triagedAn issue we've not yet triagedtype: enhancementA general enhancementA general enhancement
Description
Expected Behavior
If one of multiple UserDetailsService
beans is primary, then it should be configured.
Current Behavior
Warning log message instead.
Lines 86 to 92 in c905ac3
else if (beanNames.length > 1) { | |
this.logger.warn(LogMessage.format("Found %s UserDetailsService beans, with names %s. " | |
+ "Global Authentication Manager will not use a UserDetailsService for username/password login. " | |
+ "Consider publishing a single UserDetailsService bean.", beanNames.length, | |
Arrays.toString(beanNames))); | |
return; | |
} |
Context
I want to enhance existing UserDetailsService
like this:
@Primary
@Bean
public UserDetailsService primaryUserDetailsService(UserDetailsService userDetailsService) {
return (username) -> {
// TODO load user from other source
return userDetailsService.loadUserByUsername(username);
};
}
I'd like to contribute if it's accepted.
Metadata
Metadata
Assignees
Labels
status: waiting-for-triageAn issue we've not yet triagedAn issue we've not yet triagedtype: enhancementA general enhancementA general enhancement