This week's book giveaway is in the OO, Patterns, UML and Refactoring forum. We're giving away four copies of Refactoring for Software Design Smells: Managing Technical Debt and have Girish Suryanarayana, Ganesh Samarthyam & Tushar Sharma on-line! See this thread for details.
Username, user id, login name, they all mean the same thing to me.
Why do you see it meaning something different?
Which UserDetailsService are you using, JDBC, LDAP, etc?
For JDBC just change the userByUserName property or authoritiesByUserName property to go to the name of the fields in the database that you have that don't match the default built in queries.
Remember the userByUserName property query has to return three fields; username(userID), password, and boolean for enabled.
The authoritiesByUserName query has to return two fields; username(UserID), role
For the role field, make sure it is prefixed with "ROLE_"