5
0
mirror of https://github.com/apache/sqoop.git synced 2025-05-09 03:59:46 +08:00

SQOOP-2116: Sqoop2: RequestContext should use user short name

(Abraham Elmahrek via Jarek Jarcec Cecho)
This commit is contained in:
Jarek Jarcec Cecho 2015-02-17 17:54:27 -08:00
parent 170ab67bbb
commit f0033ebe53

View File

@ -122,7 +122,7 @@ public Locale getAcceptLanguageHeader() {
*/
public String getUserName() {
if (AuthenticationManager.getAuthenticationHandler().isSecurityEnabled()) {
return HttpUserGroupInformation.get().getUserName();
return HttpUserGroupInformation.get().getShortUserName();
} else {
return request.getParameter(PseudoAuthenticator.USER_NAME);
}