uploadedObject.setBucketName(uploadedObject.getBucketName());
// Add all metadata returned by S3 to uploaded object.
Map<String, Object> map = new HashMap<String, Object>();
map.putAll(convertHeadersToMap(httpResponse.getAllHeaders()));
uploadedObject.replaceAllMetadata(ServiceUtils.cleanRestMetadataMap(
map, this.getRestHeaderPrefix(), this.getRestMetadataPrefix()));
// Confirm that the data was not corrupted in transit by checking S3's calculated
// hash value with the locally computed value. This is only necessary if the user
// did not provide a Content-MD5 header with the original object.