I have 2 separate Spring Boot applications, one serving as an an OAuth 2 authorization server, and the other as resource server. I\'m using Spring\'s RemoteTokenServices>
RemoteTokenServices>
Did you enable the AuthenticationPrincipalArgumentResolver, like following xml?
AuthenticationPrincipalArgumentResolver
And you need to implement the UserDetails to return your own CustomerUser object, then you can use the annotation to get principal directly.
UserDetails
CustomerUser object