class DistroXV1RequestToCreateAWSClusterRequestConverter implements DistroXV1RequestToCliRequestConverter {

    @Override
    public CreateAWSClusterRequest convert(DistroXV1Request source) {
        CreateAWSClusterRequest request = new CreateAWSClusterRequest();
        request.setClusterName(source.getName());
        request.setClusterTemplateName(source.getCluster().getBlueprintName());
        request.setEnvironmentName(source.getEnvironmentName());
        request.setImage(convertImageRequest(source.getImage()));
        request.setInstanceGroups(convertInstanceGroups(source.getInstanceGroups()));
        if (source.getNetwork() != null && source.getNetwork().getAws() != null) {
            request.setSubnetId(source.getNetwork().getAws().getSubnetId());
        }
        request.setTags(getIfNotNull(source.getTags(), this::getTags));
        return request;
    }

}