Currently checking if a security group exists, one must catch an Exception:
try {
amazonEC2.describeSecurityGroups(new DescribeSecurityGroupsRequest().withGroupNames(ec2SecurityGroup));
return; //Success, it already exists.
} catch (AmazonServiceException e) {
//The security group doesn't exist.
}
Having a dedicated method would make this much better.