List of usage examples for com.amazonaws.services.s3 AmazonS3Client getBucketVersioningConfiguration
@Override public BucketVersioningConfiguration getBucketVersioningConfiguration( GetBucketVersioningConfigurationRequest getBucketVersioningConfigurationRequest) throws SdkClientException, AmazonServiceException
From source file:com.eucalyptus.objectstorage.providers.s3.S3ProviderClient.java
License:Open Source License
@Override public GetBucketVersioningStatusResponseType getBucketVersioningStatus(GetBucketVersioningStatusType request) throws S3Exception { GetBucketVersioningStatusResponseType reply = request.getReply(); User requestUser = getRequestUser(request); OsgInternalS3Client internalS3Client = null; try {/*from w w w . j a v a2s.c o m*/ internalS3Client = getS3Client(requestUser); AmazonS3Client s3Client = internalS3Client.getS3Client(); BucketVersioningConfiguration versioning = s3Client .getBucketVersioningConfiguration(request.getBucket()); reply.setVersioningStatus(versioning.getStatus()); } catch (AmazonServiceException e) { LOG.debug("Error from backend", e); throw S3ExceptionMapper.fromAWSJavaSDK(e); } return reply; }