title: How to correctly implement the UserDetailsService without having an username?
body: <p>I am creating an oauth service in spring-boot and want to use user information from a MariaDB for authentication.
  When implementing UserDetailsService I have to override the function loadUserByUsername. The problem is that my user model does not have a field username, instead of this I want to load the users using their mail address.
  So my question: How do I correctly implement the UserDetailsService without having an username?</p>