Skip to content

Commit 8ec8860

Browse files
committed
HBASE-24121 [Authorization] ServiceAuthorizationManager isn't dynamically updatable. And it should be (#1439)
Signed-off-by: Bharath Vissapragada <[email protected]> Signed-off-by: Michael Stack <[email protected]> Conflicts: hbase-server/src/main/java/org/apache/hadoop/hbase/ipc/RpcServer.java
1 parent ef3a476 commit 8ec8860

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

hbase-server/src/main/java/org/apache/hadoop/hbase/ipc/RpcServer.java

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2265,6 +2265,14 @@ public void onConfigurationChange(Configuration newConf) {
22652265
if (scheduler instanceof ConfigurationObserver) {
22662266
((ConfigurationObserver)scheduler).onConfigurationChange(newConf);
22672267
}
2268+
// Make sure authManager will read hbase-policy file
2269+
System.setProperty("hadoop.policy.file", "hbase-policy.xml");
2270+
synchronized (authManager) {
2271+
authManager.refresh(newConf, new HBasePolicyProvider());
2272+
}
2273+
LOG.info("Refreshed hbase-policy.xml successfully");
2274+
ProxyUsers.refreshSuperUserGroupsConfiguration(newConf);
2275+
LOG.info("Refreshed super and proxy users successfully");
22682276
}
22692277

22702278
private void initReconfigurable(Configuration confToLoad) {

0 commit comments

Comments
 (0)