HI all, I am using hadoop2.0 alpha release,
org.apache.hadoop.http.lib.StaticUserWebFilter.getUsernameFromConf(Configuration) static String getUsernameFromConf(Configuration conf) { String oldStyleUgi = conf.get(DEPRECATED_UGI_KEY); if (oldStyleUgi != null) { // We can't use the normal configuration deprecation mechanism here // since we need to split out the username from the configured UGI. LOG.warn(DEPRECATED_UGI_KEY + " should not be used. Instead, use " + USERNAME_KEY + "."); String[] parts = oldStyleUgi.split(","); return parts[0]; } else { return conf.get(USERNAME_KEY, USERNAME_DEFAULT); // this part will never be executed, because in hdfs-default.xml,the DEPRECATED_UGI_KEY will always there, so here the logic should check the new property first, then the deprecated key. Any idea? } }