@Override protected AbstractFileSystem getTargetFileSystem(final String settings, final URI[] mergeFsURIList) throws URISyntaxException, UnsupportedFileSystemException { throw new UnsupportedFileSystemException("mergefs not implemented yet"); // return MergeFs.createMergeFs(mergeFsURIList, config); } };
/** * Create a FileContext using the passed config. Generally it is better to use * {@link #getFileContext(URI, Configuration)} instead of this one. * * * @param aConf * @return new FileContext * @throws UnsupportedFileSystemException If file system in the config * is not supported */ public static FileContext getFileContext(final Configuration aConf) throws UnsupportedFileSystemException { final URI defaultFsUri = URI.create(aConf.get(FS_DEFAULT_NAME_KEY, FS_DEFAULT_NAME_DEFAULT)); if ( defaultFsUri.getScheme() != null && !defaultFsUri.getScheme().trim().isEmpty()) { return getFileContext(defaultFsUri, aConf); } throw new UnsupportedFileSystemException(String.format( "%s: URI configured via %s carries no scheme", defaultFsUri, FS_DEFAULT_NAME_KEY)); }
/** * Create a file system instance for the specified uri using the conf. The * conf is used to find the class name that implements the file system. The * conf is also passed to the file system for its configuration. * * @param uri URI of the file system * @param conf Configuration for the file system * * @return Returns the file system for the given URI * * @throws UnsupportedFileSystemException file system for <code>uri</code> is * not found */ public static AbstractFileSystem createFileSystem(URI uri, Configuration conf) throws UnsupportedFileSystemException { final String fsImplConf = String.format("fs.AbstractFileSystem.%s.impl", uri.getScheme()); Class<?> clazz = conf.getClass(fsImplConf, null); if (clazz == null) { throw new UnsupportedFileSystemException(String.format( "%s=null: %s: %s", fsImplConf, NO_ABSTRACT_FS_ERROR, uri.getScheme())); } return (AbstractFileSystem) newInstance(clazz, uri, conf); }
throw new UnsupportedFileSystemException("No FileSystem for scheme " + "\"" + scheme + "\"");
src = src.substring(linkPrefix.length()); if (src.equals(SlashPath.toString())) { throw new UnsupportedFileSystemException("Unexpected mount table " + "link entry '" + key + "'. Use " + Constants.CONFIG_VIEWFS_LINK_MERGE_SLASH + " instead!");
FileSystem fileSystem, Path path) throws IOException { if (!isViewFileSystem(fileSystem)) { throw new UnsupportedFileSystemException("FileSystem '" + fileSystem.getUri() + "'is not a ViewFileSystem.");
@Override protected AbstractFileSystem getTargetFileSystem(URI[] mergeFsURIList) throws URISyntaxException, UnsupportedFileSystemException { throw new UnsupportedFileSystemException("mergefs not implemented yet"); // return MergeFs.createMergeFs(mergeFsURIList, config); } };
@Override protected FileSystem getTargetFileSystem(URI[] mergeFsURIList) throws URISyntaxException, UnsupportedFileSystemException { throw new UnsupportedFileSystemException("mergefs not implemented"); // return MergeFs.createMergeFs(mergeFsURIList, config); } };
@Override protected AbstractFileSystem getTargetFileSystem(URI[] mergeFsURIList) throws URISyntaxException, UnsupportedFileSystemException { throw new UnsupportedFileSystemException("mergefs not implemented yet"); // return MergeFs.createMergeFs(mergeFsURIList, config); } };
@Override protected FileSystem getTargetFileSystem(URI[] mergeFsURIList) throws URISyntaxException, UnsupportedFileSystemException { throw new UnsupportedFileSystemException("mergefs not implemented"); // return MergeFs.createMergeFs(mergeFsURIList, config); } };
@Override protected AbstractFileSystem getTargetFileSystem(URI[] mergeFsURIList) throws URISyntaxException, UnsupportedFileSystemException { throw new UnsupportedFileSystemException("mergefs not implemented yet"); // return MergeFs.createMergeFs(mergeFsURIList, config); } };
@Override protected FileSystem getTargetFileSystem(URI[] mergeFsURIList) throws URISyntaxException, UnsupportedFileSystemException { throw new UnsupportedFileSystemException("mergefs not implemented"); // return MergeFs.createMergeFs(mergeFsURIList, config); } };
@Override protected FileSystem getTargetFileSystem(URI[] mergeFsURIList) throws URISyntaxException, UnsupportedFileSystemException { throw new UnsupportedFileSystemException("mergefs not implemented"); // return MergeFs.createMergeFs(mergeFsURIList, config); } };
@Override protected AbstractFileSystem getTargetFileSystem(URI[] mergeFsURIList) throws URISyntaxException, UnsupportedFileSystemException { throw new UnsupportedFileSystemException("mergefs not implemented yet"); // return MergeFs.createMergeFs(mergeFsURIList, config); } };
@Override public FileChecksum next(final FileSystem fs, final Path p) throws IOException { if (fs instanceof DistributedFileSystem) { return fs.getFileChecksum(p, length); } else { throw new UnsupportedFileSystemException( "getFileChecksum(Path, long) is not supported by " + fs.getClass().getSimpleName()); } } }.resolve(this, absF);
@Override public FileChecksum next(final FileSystem fs, final Path p) throws IOException { if (fs instanceof DistributedFileSystem) { return ((DistributedFileSystem) fs).getFileChecksum(p, length); } else { throw new UnsupportedFileSystemException( "getFileChecksum(Path, long) is not supported by " + fs.getClass().getSimpleName()); } } }.resolve(this, absF);
@Override public FileChecksum next(final FileSystem fs, final Path p) throws IOException { if (fs instanceof DistributedFileSystem) { return ((DistributedFileSystem) fs).getFileChecksum(p, length); } else { throw new UnsupportedFileSystemException( "getFileChecksum(Path, long) is not supported by " + fs.getClass().getSimpleName()); } } }.resolve(this, absF);
/** * Create a FileContext using the passed config. Generally it is better to use * {@link #getFileContext(URI, Configuration)} instead of this one. * * * @param aConf * @return new FileContext * @throws UnsupportedFileSystemException If file system in the config * is not supported */ public static FileContext getFileContext(final Configuration aConf) throws UnsupportedFileSystemException { final URI defaultFsUri = URI.create(aConf.get(FS_DEFAULT_NAME_KEY, FS_DEFAULT_NAME_DEFAULT)); if ( defaultFsUri.getScheme() != null && !defaultFsUri.getScheme().trim().isEmpty()) { return getFileContext(defaultFsUri, aConf); } throw new UnsupportedFileSystemException(String.format( "%s: URI configured via %s carries no scheme", defaultFsUri, FS_DEFAULT_NAME_KEY)); }
/** * Create a FileContext using the passed config. Generally it is better to use * {@link #getFileContext(URI, Configuration)} instead of this one. * * * @param aConf * @return new FileContext * @throws UnsupportedFileSystemException If file system in the config * is not supported */ public static FileContext getFileContext(final Configuration aConf) throws UnsupportedFileSystemException { final URI defaultFsUri = URI.create(aConf.get(FS_DEFAULT_NAME_KEY, FS_DEFAULT_NAME_DEFAULT)); if ( defaultFsUri.getScheme() != null && !defaultFsUri.getScheme().trim().isEmpty()) { return getFileContext(defaultFsUri, aConf); } throw new UnsupportedFileSystemException(String.format( "%s: URI configured via %s carries no scheme", defaultFsUri, FS_DEFAULT_NAME_KEY)); }
/** * Create a FileContext using the passed config. Generally it is better to use * {@link #getFileContext(URI, Configuration)} instead of this one. * * * @param aConf * @return new FileContext * @throws UnsupportedFileSystemException If file system in the config * is not supported */ public static FileContext getFileContext(final Configuration aConf) throws UnsupportedFileSystemException { final URI defaultFsUri = URI.create(aConf.get(FS_DEFAULT_NAME_KEY, FS_DEFAULT_NAME_DEFAULT)); if ( defaultFsUri.getScheme() != null && !defaultFsUri.getScheme().trim().isEmpty()) { return getFileContext(defaultFsUri, aConf); } throw new UnsupportedFileSystemException(String.format( "%s: URI configured via %s carries no scheme", defaultFsUri, FS_DEFAULT_NAME_KEY)); }