Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(ec2): VpcEndpointService construct #5498

Merged
merged 24 commits into from
Jan 7, 2020

Conversation

flemjame-at-amazon
Copy link
Contributor

@flemjame-at-amazon flemjame-at-amazon commented Dec 20, 2019


By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license

L2 construct for VPC Endpoint Service which abstracts away the following code:

CfnVPCEndpointService vpcEndpointService = new CfnVPCEndpointService(this, "VPC Endpoint Service", CfnVPCEndpointServiceProps.builder()
                .acceptanceRequired(false)
                .networkLoadBalancerArns(Arrays.asList("load-balancer-arn"))
                .build());
CfnVPCEndpointServicePermissions principals = new CfnVPCEndpointServicePermissions(this, "Endpoint Service Whitelisted Accounts", CfnVPCEndpointServicePermissionsProps.builder()
                .serviceId(vpcEndpointService.getRef())
                .allowedPrincipals(ArrayList<String>())
                .build());

And makes it into:

VpcEndpointService = new VpcEndpointService(this, "Endpoint Service", VpcEndpointServiceProps.builder()
                .networkLoadBalancerArns(Arrays.asList("load-balancer-arn"))
                .acceptanceRequired(false)
                .allowedPrincipals(ArrayList<ArnPrincipal>())
                .build());

I was not able to make networkLoadBalancerArns take a list of INetworkLoadBalancer due to a cyclic dependency between aws-ec2 and aws-elasticloadbalancingv2.

EDIT:

New invocation after review feedback and subsequent changes:

VpcEndpointService = new VpcEndpointService(this, "Endpoint Service", VpcEndpointServiceProps.builder()
                .vpcEndpointServiceLoadBalancers(ArrayList<IVpcEndpointServiceLoadBalancer>())
                .acceptanceRequired(false)
                .allowedPrincipals(ArrayList<ArnPrincipal>())
                .build());

vpcEndpointServiceLoadBalancers accepts a list of NetworkLoadBalancer as an argument.

Commit Message

feat(ec2): VpcEndpointService construct

Add an experimental VpcEndpointService construct, to allow exposing Network Load Balancers as endpoints in a VPC.

@aws-cdk-automation
Copy link
Collaborator

AWS CodeBuild CI Report

  • Result: SUCCEEDED
  • Build Logs (available for 30 days)

Powered by github-codebuild-logs, available on the AWS Serverless Application Repository

@aws-cdk-automation
Copy link
Collaborator

AWS CodeBuild CI Report

  • Result: SUCCEEDED
  • Build Logs (available for 30 days)

Powered by github-codebuild-logs, available on the AWS Serverless Application Repository

@aws-cdk-automation
Copy link
Collaborator

AWS CodeBuild CI Report

  • Result: SUCCEEDED
  • Build Logs (available for 30 days)

Powered by github-codebuild-logs, available on the AWS Serverless Application Repository

@aws-cdk-automation
Copy link
Collaborator

AWS CodeBuild CI Report

  • Result: SUCCEEDED
  • Build Logs (available for 30 days)

Powered by github-codebuild-logs, available on the AWS Serverless Application Repository

@aws-cdk-automation
Copy link
Collaborator

AWS CodeBuild CI Report

  • Result: SUCCEEDED
  • Build Logs (available for 30 days)

Powered by github-codebuild-logs, available on the AWS Serverless Application Repository

packages/@aws-cdk/aws-ec2/lib/vpc-endpoint-service.ts Outdated Show resolved Hide resolved
packages/@aws-cdk/aws-ec2/lib/vpc-endpoint-service.ts Outdated Show resolved Hide resolved
@mergify mergify bot dismissed rix0rrr’s stale review December 30, 2019 15:00

Pull request has been modified.

@aws-cdk-automation
Copy link
Collaborator

AWS CodeBuild CI Report

  • Result: SUCCEEDED
  • Build Logs (available for 30 days)

Powered by github-codebuild-logs, available on the AWS Serverless Application Repository

@aws-cdk-automation
Copy link
Collaborator

AWS CodeBuild CI Report

  • Result: SUCCEEDED
  • Build Logs (available for 30 days)

Powered by github-codebuild-logs, available on the AWS Serverless Application Repository

@aws-cdk-automation
Copy link
Collaborator

AWS CodeBuild CI Report

  • Result: SUCCEEDED
  • Build Logs (available for 30 days)

Powered by github-codebuild-logs, available on the AWS Serverless Application Repository

@aws-cdk-automation
Copy link
Collaborator

AWS CodeBuild CI Report

  • Result: SUCCEEDED
  • Build Logs (available for 30 days)

Powered by github-codebuild-logs, available on the AWS Serverless Application Repository

@aws-cdk-automation
Copy link
Collaborator

AWS CodeBuild CI Report

  • Result: SUCCEEDED
  • Build Logs (available for 30 days)

Powered by github-codebuild-logs, available on the AWS Serverless Application Repository

rix0rrr
rix0rrr previously requested changes Jan 6, 2020
packages/@aws-cdk/aws-ec2/lib/vpc-endpoint-service.ts Outdated Show resolved Hide resolved
packages/@aws-cdk/aws-ec2/lib/vpc-endpoint-service.ts Outdated Show resolved Hide resolved
packages/@aws-cdk/aws-ec2/lib/vpc-endpoint-service.ts Outdated Show resolved Hide resolved
packages/@aws-cdk/aws-ec2/lib/vpc-endpoint-service.ts Outdated Show resolved Hide resolved
packages/@aws-cdk/aws-ec2/lib/vpc-endpoint-service.ts Outdated Show resolved Hide resolved
@rix0rrr
Copy link
Contributor

rix0rrr commented Jan 6, 2020

Also can you please mark all new APIs @experimental ?

@mergify mergify bot dismissed rix0rrr’s stale review January 6, 2020 14:23

Pull request has been modified.

@aws-cdk-automation
Copy link
Collaborator

AWS CodeBuild CI Report

  • Result: SUCCEEDED
  • Build Logs (available for 30 days)

Powered by github-codebuild-logs, available on the AWS Serverless Application Repository

@aws-cdk-automation
Copy link
Collaborator

AWS CodeBuild CI Report

  • Result: SUCCEEDED
  • Build Logs (available for 30 days)

Powered by github-codebuild-logs, available on the AWS Serverless Application Repository

@aws-cdk-automation
Copy link
Collaborator

AWS CodeBuild CI Report

  • Result: FAILED
  • Build Logs (available for 30 days)

Powered by github-codebuild-logs, available on the AWS Serverless Application Repository

@aws-cdk-automation
Copy link
Collaborator

AWS CodeBuild CI Report

  • Result: FAILED
  • Build Logs (available for 30 days)

Powered by github-codebuild-logs, available on the AWS Serverless Application Repository

@aws-cdk-automation
Copy link
Collaborator

AWS CodeBuild CI Report

  • Result: SUCCEEDED
  • Build Logs (available for 30 days)

Powered by github-codebuild-logs, available on the AWS Serverless Application Repository

@rix0rrr rix0rrr changed the title feat(ec2): add vpc endpoint service L2 construct feat(ec2): VpcEndpointService construct Jan 7, 2020
@mergify
Copy link
Contributor

mergify bot commented Jan 7, 2020

Thank you for contributing! Your pull request is now being automatically merged.

@aws-cdk-automation
Copy link
Collaborator

AWS CodeBuild CI Report

  • Result: SUCCEEDED
  • Build Logs (available for 30 days)

Powered by github-codebuild-logs, available on the AWS Serverless Application Repository

@mergify
Copy link
Contributor

mergify bot commented Jan 7, 2020

Thank you for contributing! Your pull request is now being automatically merged.

@mergify mergify bot merged commit a2713f3 into aws:master Jan 7, 2020
@aws-cdk-automation
Copy link
Collaborator

AWS CodeBuild CI Report

  • Result: SUCCEEDED
  • Build Logs (available for 30 days)

Powered by github-codebuild-logs, available on the AWS Serverless Application Repository

@flemjame-at-amazon flemjame-at-amazon deleted the add-vpc-endpoint-service branch January 7, 2020 15:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants