use of com.amazonaws.services.ec2.model.DescribeVpcEndpointServicesResult in project cloudbreak by hortonworks.
the class AwsNetworkCfTemplateProviderTest method createDescribeVpcEndpointServicesResultWithDifferentAzs.
private static DescribeVpcEndpointServicesResult createDescribeVpcEndpointServicesResultWithDifferentAzs() {
DescribeVpcEndpointServicesResult describeVpcEndpointServicesResult = new DescribeVpcEndpointServicesResult();
List<ServiceDetail> serviceDetails = new ArrayList<>();
ServiceDetail serviceDetail1 = new ServiceDetail().withServiceName(String.format(AwsNetworkCfTemplateProvider.VPC_INTERFACE_SERVICE_ENDPOINT_NAME_PATTERN, "region", "interface1"));
serviceDetail1.setAvailabilityZones(List.of("az1"));
serviceDetails.add(serviceDetail1);
ServiceDetail serviceDetail2 = new ServiceDetail().withServiceName(String.format(AwsNetworkCfTemplateProvider.VPC_INTERFACE_SERVICE_ENDPOINT_NAME_PATTERN, "region", "interface2"));
serviceDetail2.setAvailabilityZones(List.of("az2", "az3"));
serviceDetails.add(serviceDetail2);
ServiceDetail serviceDetail3 = new ServiceDetail().withServiceName(String.format(AwsNetworkCfTemplateProvider.VPC_INTERFACE_SERVICE_ENDPOINT_NAME_PATTERN, "region", "interface3"));
serviceDetail3.setAvailabilityZones(List.of("az5", "az6"));
serviceDetails.add(serviceDetail3);
describeVpcEndpointServicesResult.setServiceDetails(serviceDetails);
return describeVpcEndpointServicesResult;
}
use of com.amazonaws.services.ec2.model.DescribeVpcEndpointServicesResult in project cloudbreak by hortonworks.
the class AwsNetworkCfTemplateProviderTest method createDescribeVpcEndpointServicesResult.
private static DescribeVpcEndpointServicesResult createDescribeVpcEndpointServicesResult(String... services) {
DescribeVpcEndpointServicesResult describeVpcEndpointServicesResult = new DescribeVpcEndpointServicesResult();
List<ServiceDetail> serviceDetails = new ArrayList<>();
for (String service : services) {
ServiceDetail serviceDetail = new ServiceDetail().withServiceName(String.format(AwsNetworkCfTemplateProvider.VPC_INTERFACE_SERVICE_ENDPOINT_NAME_PATTERN, "region", service));
serviceDetail.setAvailabilityZones(List.of("az1", "az2"));
serviceDetails.add(serviceDetail);
}
describeVpcEndpointServicesResult.setServiceDetails(serviceDetails);
return describeVpcEndpointServicesResult;
}
Aggregations