/** configure ugi */ @BeforeClass public static void setup() { javax.security.auth.login.Configuration.setConfiguration( new DummyLoginConfiguration()); // doesn't matter what it is, but getGroups needs it set... // use HADOOP_HOME environment variable to prevent interfering with logic // that finds winutils.exe String home = System.getenv("HADOOP_HOME"); System.setProperty("hadoop.home.dir", (home != null ? home : ".")); // fake the realm is kerberos is enabled System.setProperty("java.security.krb5.kdc", ""); System.setProperty("java.security.krb5.realm", "DEFAULT.REALM"); }
/** configure ugi */ @BeforeClass public static void setup() { javax.security.auth.login.Configuration.setConfiguration( new DummyLoginConfiguration()); // doesn't matter what it is, but getGroups needs it set... // use HADOOP_HOME environment variable to prevent interfering with logic // that finds winutils.exe String home = System.getenv("HADOOP_HOME"); System.setProperty("hadoop.home.dir", (home != null ? home : ".")); // fake the realm is kerberos is enabled System.setProperty("java.security.krb5.kdc", ""); System.setProperty("java.security.krb5.realm", "DEFAULT.REALM"); }