use of com.emc.sa.service.vipr.object.tasks.CreateBucket in project coprhd-controller by CoprHD.
the class ObjectStorageUtils method createBucket.
public static URI createBucket(String bucketName, URI virtualArray, URI virtualPoolId, URI projectId, Double softQuota, Double hardQuota, String retention, String owner) {
String softQuotaSize = gbToQuotaSize(softQuota);
String hardQuotaSize = gbToQuotaSize(hardQuota);
Task<BucketRestRep> task = execute(new CreateBucket(bucketName, virtualArray, virtualPoolId, projectId, softQuotaSize, hardQuotaSize, retention, owner));
addAffectedResource(task);
URI bucketId = task.getResourceId();
addRollback(new DeactivateBucket(bucketId));
logInfo("object.bucket.task", bucketId, task.getOpId());
return bucketId;
}
Aggregations