public class FileSystemFactory<S extends ScopeType<S>> extends Object implements SharedResourceFactory<org.apache.hadoop.fs.FileSystem,FileSystemKey,S>
SharedResourceFactory for creating FileSystems.
The factory creates a FileSystem with the correct scheme and applies any FileSystemInstrumentation
found in the classpath.| Modifier and Type | Field and Description |
|---|---|
static String |
FACTORY_NAME |
| Constructor and Description |
|---|
FileSystemFactory() |
| Modifier and Type | Method and Description |
|---|---|
SharedResourceFactoryResponse<org.apache.hadoop.fs.FileSystem> |
createResource(SharedResourcesBroker<S> broker,
ScopedConfigView<S,FileSystemKey> config) |
static <S extends ScopeType<S>> |
get(org.apache.hadoop.conf.Configuration configuration,
SharedResourcesBroker<S> broker)
Equivalent to
FileSystem.get(Configuration), but uses the input SharedResourcesBroker to configure
add-ons to the FileSystem (e.g. |
static <S extends ScopeType<S>> |
get(URI uri,
org.apache.hadoop.conf.Configuration configuration,
SharedResourcesBroker<S> broker)
Equivalent to
FileSystem.get(URI, Configuration), but uses the input SharedResourcesBroker to configure
add-ons to the FileSystem (e.g. |
S |
getAutoScope(SharedResourcesBroker<S> broker,
ConfigView<S,FileSystemKey> config) |
String |
getName() |
public static final String FACTORY_NAME
public static <S extends ScopeType<S>> org.apache.hadoop.fs.FileSystem get(org.apache.hadoop.conf.Configuration configuration, SharedResourcesBroker<S> broker) throws IOException
FileSystem.get(Configuration), but uses the input SharedResourcesBroker to configure
add-ons to the FileSystem (e.g. throttling, instrumentation).IOExceptionpublic static <S extends ScopeType<S>> org.apache.hadoop.fs.FileSystem get(URI uri, org.apache.hadoop.conf.Configuration configuration, SharedResourcesBroker<S> broker) throws IOException
FileSystem.get(URI, Configuration), but uses the input SharedResourcesBroker to configure
add-ons to the FileSystem (e.g. throttling, instrumentation).IOExceptionpublic String getName()
getName in interface SharedResourceFactory<org.apache.hadoop.fs.FileSystem,FileSystemKey,S extends ScopeType<S>>public SharedResourceFactoryResponse<org.apache.hadoop.fs.FileSystem> createResource(SharedResourcesBroker<S> broker, ScopedConfigView<S,FileSystemKey> config) throws NotConfiguredException
createResource in interface SharedResourceFactory<org.apache.hadoop.fs.FileSystem,FileSystemKey,S extends ScopeType<S>>NotConfiguredExceptionpublic S getAutoScope(SharedResourcesBroker<S> broker, ConfigView<S,FileSystemKey> config)
getAutoScope in interface SharedResourceFactory<org.apache.hadoop.fs.FileSystem,FileSystemKey,S extends ScopeType<S>>