private <T> T fsExecute(Principal user, String doAs, Hadoop.FileSystemExecutor<T> executor)
throws IOException, HadoopException {
String hadoopUser = getEffectiveUser(user, doAs);
Hadoop hadoop = HoopServer.get().get(Hadoop.class);
Configuration conf = HoopServer.get().get(Hadoop.class).getDefaultConfiguration();
return hadoop.execute(hadoopUser, conf, executor);
}
/**
* Returns a filesystem instance. The fileystem instance is wired for release at the completion of
* the current Servlet request via the {@link FileSystemReleaseFilter}.