Configure the S3 control client for S3 on Outposts by using the SDK for Java - Amazon Simple Storage Service
Services or capabilities described in Amazon Web Services documentation might vary by Region. To see the differences applicable to the China Regions, see Getting Started with Amazon Web Services in China.

Configure the S3 control client for S3 on Outposts by using the SDK for Java

The following example configures the Amazon S3 control client for Amazon S3 on Outposts by using the Amazon SDK for Java. To use this example, replace each user input placeholder with your own information.

import com.amazonaws.auth.AWSStaticCredentialsProvider; import com.amazonaws.auth.BasicAWSCredentials; import com.amazonaws.services.s3control.AWSS3Control; import com.amazonaws.services.s3control.AWSS3ControlClient; public AWSS3Control createS3ControlClient() { String accessKey = AWSAccessKey; String secretKey = SecretAccessKey; BasicAWSCredentials awsCreds = new BasicAWSCredentials(accessKey, secretKey); return AWSS3ControlClient.builder().enableUseArnRegion() .withCredentials(new AWSStaticCredentialsProvider(awsCreds)) .build(); }