public static void initialize(Configuration conf) throws IOException {
    ImmutableSet.Builder<String> superUsersBuilder = ImmutableSet.builder();
    ImmutableSet.Builder<String> superGroupsBuilder = ImmutableSet.builder();
    systemUser = User.getCurrent();

    if (systemUser == null) {
      throw new IllegalStateException("Unable to obtain the current user, "
        + "authorization checks for internal operations will not work correctly!");
    }

    String currentUser = systemUser.getShortName();
    LOG.trace("Current user name is {}", currentUser);
    superUsersBuilder.add(currentUser);

    String[] superUserList = conf.getStrings(SUPERUSER_CONF_KEY, new String[0]);
    for (String name : superUserList) {
      if (AuthUtil.isGroupPrincipal(name)) {
        // Let's keep the '@' for distinguishing from user.
        superGroupsBuilder.add(name);
      } else {
        superUsersBuilder.add(name);
      }
    }
    superUsers = superUsersBuilder.build();
    superGroups = superGroupsBuilder.build();
  }
Should be called only once to pre-load list of super users and super groups from Configuration.
This operation is idempotent.
@param conf configuration to load users from
@throws IOException           if unable to initialize lists of superusers or super groups
@throws IllegalStateException if current user is null
hbase-common/src/main/java/org/apache/hadoop/hbase/security/Superusers.java