mirror of
https://github.com/apache/sqoop.git
synced 2025-05-20 19:00:48 +08:00
SQOOP-2227: Sqoop2: Clear connector cache in ShowConnectorFunction.java
(Richard Zhou via Abraham Elmahrek)
This commit is contained in:
parent
756a3c17e2
commit
04f374b501
@ -99,6 +99,10 @@ private Status grantPrivilege(String action, String resourceType, String resourc
|
||||
Arrays.asList(principalObject),
|
||||
Arrays.asList(privilegeObject));
|
||||
|
||||
if (resourceType.toUpperCase().equals(MResource.TYPE.CONNECTOR.name())) {
|
||||
client.clearCache();
|
||||
}
|
||||
|
||||
printlnResource(Constants.RES_GRANT_PRIVILEGE_SUCCESSFUL,
|
||||
action, resourceType + " " + resource,
|
||||
((withGrant) ? " " + resourceString(Constants.RES_GRANT_PRIVILEGE_SUCCESSFUL_WITH_GRANT) : ""),
|
||||
|
@ -100,6 +100,10 @@ private Status revokePrivilege(String action, String resourceType, String resour
|
||||
Arrays.asList(principalObject),
|
||||
Arrays.asList(privilegeObject));
|
||||
|
||||
if (resourceType.toUpperCase().equals(MResource.TYPE.CONNECTOR.name())) {
|
||||
client.clearCache();
|
||||
}
|
||||
|
||||
printlnResource(Constants.RES_REVOKE_PRIVILEGE_SUCCESSFUL,
|
||||
action, resourceType + " " + resource,
|
||||
((withGrant) ? " " + resourceString(Constants.RES_REVOKE_PRIVILEGE_SUCCESSFUL_WITH_GRANT) : ""),
|
||||
|
Loading…
Reference in New Issue
Block a user