(aws-ec2): Add `InterfaceVpcEndpointAwsService.SCHEDULER` for EventBridge Scheduler

Open Beginner friendly
#38,588 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
1/5
Estimated time
1-3 hours
Newbie friendliness
88/100
Issue type
Feature
Clarity
Clearly specified
Activity status
Active
Tech stack
aws, typescript

Research direction

Start with packages/aws-cdk-lib/aws-ec2/lib/vpc-endpoint.ts and review the neighboring InterfaceVpcEndpointAwsService constants. Add the Scheduler service constant described in the issue, then verify that the aws-ec2 tests pass and that the exposed constant represents the scheduler endpoint and is usable by VPC interface endpoints.

Written by the indexing model from the issue text.

Description

@aws-cdk/aws-ec2 effort/small feature-request p2
Describe the feature

aws-cdk-lib/aws-ec2 exposes static InterfaceVpcEndpointAwsService constants for most AWS services (EVENTBRIDGE, STEP_FUNCTIONS, LAMBDA, etc.), but has no constant for EventBridge Scheduler (com.amazonaws.<region>.scheduler).

Users must currently construct it manually:

this.vpc.addInterfaceEndpoint('SchedulerEndpoint', {
  service: new InterfaceVpcEndpointAwsService('scheduler'),
});
Use Case

VPC-attached Lambdas that call the EventBridge Scheduler API (aws-sdk-scheduler) need an interface VPC endpoint (or NAT egress).

Adding a supported constant would match the ergonomics of other services and avoid the surprise that Scheduler is not covered by EVENTBRIDGE (which points at events, a separate service).

Proposed Solution

Add to packages/aws-cdk-lib/aws-ec2/lib/vpc-endpoint.ts:

public static readonly SCHEDULER = new InterfaceVpcEndpointAwsService('scheduler');

Region availability per AWS docs: https://docs.aws.amazon.com/scheduler/latest/UserGuide/using-vpc-endpoints.html

Other Information

No response

Acknowledgements
  • I may be able to implement this feature request
  • This feature might incur a breaking change
AWS CDK Library version (aws-cdk-lib)

2.258.1

AWS CDK CLI version

2.1135.1 (build 6551740)

Environment details (OS name and version, etc.)

Amazon Linux 2

Dominant language
TypeScript
Stars
12.9k
Forks
4.6k
Avg merge
2d 3h
Merged PRs (30d)
71

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from aws/aws-cdk

All issues in aws/aws-cdk

Similar issues

More TypeScript issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.