Package software.amazon.nio.spi.s3.util
Class S3XFileSystemInfo
- java.lang.Object
-
- software.amazon.nio.spi.s3.util.S3FileSystemInfo
-
- software.amazon.nio.spi.s3.util.S3XFileSystemInfo
-
public class S3XFileSystemInfo extends S3FileSystemInfo
Populates fields with information extracted by the S3 URI provided. This implementation is for standard AWS buckets as described in section "Accessing a bucket using S3://" in https://docs.aws.amazon.com/AmazonS3/latest/userguide/access-bucket-intro.htmlIt also computes the file system key that can be used to identify a runtime instance of a S3FileSystem (for caching purposes for example). In this implementation the key is the bucket name (which is unique in the AWS S3 namespace).
-
-
Field Summary
-
Fields inherited from class software.amazon.nio.spi.s3.util.S3FileSystemInfo
accessKey, accessSecret, bucket, endpoint, key
-
-
Constructor Summary
Constructors Constructor Description S3XFileSystemInfo(java.net.URI uri)Creates a new instance and populates it with the information extracted fromuri.
-
Method Summary
-
Methods inherited from class software.amazon.nio.spi.s3.util.S3FileSystemInfo
accessKey, accessSecret, bucket, endpoint, key
-
-
-
-
Constructor Detail
-
S3XFileSystemInfo
public S3XFileSystemInfo(java.net.URI uri) throws java.lang.IllegalArgumentExceptionCreates a new instance and populates it with the information extracted fromuri. The provided uri is parsed accordingly to the following format:<p> s3x://[accessKey:accessSecret@]endpoint[:port]/bucket/key <p>Please note that the authority part of the URI (endpoint[:port] above) is always considered a HTTP(S) endpoint, therefore the name of the bucket is the first element of the path. The remaining path elements will be the object key.
Additionally
keyis computed as endpoint/bucket/accessKey- Parameters:
uri- a S3 URI- Throws:
java.lang.IllegalArgumentException- if URI contains invalid components (e.g. an invalid bucket name)
-
-