Class S3EndpointUtils
java.lang.Object
software.amazon.awssdk.services.s3.internal.endpoints.S3EndpointUtils
Utilities for working with Amazon S3 bucket names and endpoints.
-
Method Summary
Modifier and TypeMethodDescriptionstatic URI
accelerateDualstackEndpoint
(String domain, String protocol) static URI
accelerateEndpoint
(String domain, String protocol) static void
changeToDnsEndpoint
(SdkHttpRequest.Builder mutableRequest, String bucketName) Changes from path style addressing (which the marshallers produce by default, to DNS style or virtual style addressing where the bucket name is prepended to the host.static URI
dualstackEndpoint
(String id, String domain, String protocol) static URI
fipsDualstackEndpoint
(String id, String domain, String protocol) static URI
fipsEndpoint
(String id, String domain, String protocol) static boolean
isAccelerateEnabled
(S3Configuration serviceConfiguration) static boolean
isAccelerateSupported
(SdkRequest originalRequest) static boolean
static boolean
isArnRegionEnabled
(S3Configuration serviceConfiguration) static boolean
isDualstackEnabled
(S3Configuration serviceConfiguration) static boolean
isFipsRegion
(String region) static boolean
isPathStyleAccessEnabled
(S3Configuration serviceConfiguration) static String
removeFipsIfNeeded
(String region)
-
Method Details
-
removeFipsIfNeeded
-
isFipsRegion
-
isAccelerateEnabled
- Returns:
- True if accelerate mode is enabled per
S3Configuration
, false if not.
-
isAccelerateSupported
- Parameters:
originalRequest
- Request object to identify the operation.- Returns:
- True if accelerate is supported for the given operation, false if not.
-
accelerateEndpoint
- Returns:
- The endpoint for an S3 accelerate enabled operation. S3 accelerate has a single global endpoint.
-
accelerateDualstackEndpoint
- Returns:
- The endpoint for an S3 accelerate enabled operation. S3 accelerate has a single global endpoint.
-
isDualstackEnabled
- Returns:
- True if dualstack is enabled per
S3Configuration
, false if not.
-
dualstackEndpoint
- Returns:
- dual stack endpoint from given protocol and region metadata
-
fipsEndpoint
- Returns:
- fips endpoint from given protocol and region metadata
-
fipsDualstackEndpoint
- Returns:
- dual stack + fips endpoint from given protocol and region metadata
-
isPathStyleAccessEnabled
- Returns:
- True if path style access is enabled per
S3Configuration
, false if not.
-
isArnRegionEnabled
-
changeToDnsEndpoint
Changes from path style addressing (which the marshallers produce by default, to DNS style or virtual style addressing where the bucket name is prepended to the host. DNS style addressing is preferred due to the better load balancing qualities it provides, path style is an option mainly for proxy based situations and alternative S3 implementations.- Parameters:
mutableRequest
- Marshalled HTTP request we are modifying.bucketName
- Bucket name for this particular operation.
-
isArn
-