Throw FileNotFound exception which is thrown by SSLEngine
import org.apache.hadoop.security.UserGroupInformation;
import javax.net.ssl.SSLException;
+import java.io.FileNotFoundException;
import java.io.IOException;
import java.net.InetSocketAddress;
import java.net.URI;
@@ -348,6 +349,11 @@ private void createNamenodeClientsFromConfiguration() throws IOException {
RpcHeaderProtos.RpcResponseHeaderProto.RpcErrorCodeProto.FATAL_UNAUTHORIZED)) {
throw e;
}
+ if (e instanceof IOException
+ && (e.getCause() instanceof FileNotFoundException)) {
+ LOG.fatal("Could not find file: " + e.getMessage(), e);
+ throw e;
+ }
LOG.warn("Failed to get list of NN from default NN. Default NN was " +
defaultUri);
} finally {
