[
https://issues.apache.org/jira/browse/HIVE-25992?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
chenruotao updated HIVE-25992:
------------------------------
Description:
when I use this code to access hms
{code:java}
UserGroupInformation proxyUser =
UserGroupInformation.createProxyUser(proxyUserName, userGroupInformation);
proxyUser.doAs((PrivilegedExceptionAction<Boolean>) () -> {
XXXXXX
return true;
});
{code}
there will throw exception
!image-2022-03-01-16-33-49-012.png! so I debug with this, and find something
maybe wrong in the class named HiveMetaStoreClient:
!image-2022-03-01-16-36-52-539.png!
because the value of UserGroupInformation.getLoginUser().getRealUser() that in
proxy.doas is null, so i change to UserGroupInformation.getLoginUser() and i
works
!image-2022-03-01-16-39-57-935.png!
so what I did is no problem?
was:
when I use this code to access hms
{code:java}
UserGroupInformation proxyUser =
UserGroupInformation.createProxyUser(proxyUserName, userGroupInformation);
proxyUser.doAs((PrivilegedExceptionAction<Boolean>) () -> {
XXXXXX
return true;
});
{code}
there will throw exception
!image-2022-03-01-16-33-49-012.png!
so I debug with this, and find something maybe wrong in the class named
HiveMetaStoreClient:
!image-2022-03-01-16-36-52-539.png!
because the value of UserGroupInformation.getLoginUser().getRealUser() that in
proxy.doas is null, so i change to UserGroupInformation.getLoginUser() and i
works
!image-2022-03-01-16-39-57-935.png!
so what I did is no problem?
> Can not init HiveMetaStoreClient when using proxy user
> ------------------------------------------------------
>
> Key: HIVE-25992
> URL: https://issues.apache.org/jira/browse/HIVE-25992
> Project: Hive
> Issue Type: Bug
> Components: Hive
> Affects Versions: 2.3.9
> Reporter: chenruotao
> Priority: Major
> Attachments: image-2022-03-01-16-33-49-012.png,
> image-2022-03-01-16-36-52-539.png, image-2022-03-01-16-39-57-935.png
>
>
> when I use this code to access hms
> {code:java}
> UserGroupInformation proxyUser =
> UserGroupInformation.createProxyUser(proxyUserName, userGroupInformation);
> proxyUser.doAs((PrivilegedExceptionAction<Boolean>) () -> {
> XXXXXX
> return true;
> });
> {code}
> there will throw exception
> !image-2022-03-01-16-33-49-012.png! so I debug with this, and find something
> maybe wrong in the class named HiveMetaStoreClient:
> !image-2022-03-01-16-36-52-539.png!
> because the value of UserGroupInformation.getLoginUser().getRealUser() that
> in proxy.doas is null, so i change to UserGroupInformation.getLoginUser() and
> i works
> !image-2022-03-01-16-39-57-935.png!
> so what I did is no problem?
--
This message was sent by Atlassian Jira
(v8.20.1#820001)