AmazonEC2 ec2Client = ec2Client();
DescribeVolumesRequest request = new DescribeVolumesRequest();
if (volumeIds != null) {
request.setVolumeIds(Arrays.asList(volumeIds));
}
DescribeVolumesResult result = ec2Client.describeVolumes(request);
List<Volume> volumes = result.getVolumes();
LOGGER.info(String.format("Got %d EBS volumes in region %s.", volumes.size(), region));
return volumes;
}