@ThreadSafe public final class ClientPool extends Object implements Closeable
FileSystem
) returned. The main reason for this is
to build cleanup clients.Modifier and Type | Method and Description |
---|---|
void |
close() |
FileSystem |
getClient()
Returns a
FileSystem client. |
FileSystem |
getClient(FileSystemContext context)
Returns a
FileSystem client using a specific context. |
public FileSystem getClient() throws IOException
FileSystem
client. This client does not need to be
closed directly, but can be closed by calling close()
on this object.FileSystem
clientIOException
public FileSystem getClient(FileSystemContext context) throws IOException
FileSystem
client using a specific context. This client does not need to be
closed directly, but can be closed by calling close()
on this object.context
- the FileSystemContext to useFileSystem
clientIOException
public void close() throws IOException
close
in interface Closeable
close
in interface AutoCloseable
IOException
Copyright © 2023. All Rights Reserved.