Skip to content

ec2: add handwritten paginators for VPC Encryption Control APIs - #3435

Open
pedrorfdez wants to merge 1 commit into
aws:mainfrom
pedrorfdez:feature/3232-vpc-encryption-paginators
Open

ec2: add handwritten paginators for VPC Encryption Control APIs#3435
pedrorfdez wants to merge 1 commit into
aws:mainfrom
pedrorfdez:feature/3232-vpc-encryption-paginators

Conversation

@pedrorfdez

Copy link
Copy Markdown
Contributor

Fixes #3232

What was changed

Added handwritten paginators for the two VPC Encryption Control read APIs that support pagination but were missing paginator implementations:

  • NewDescribeVpcEncryptionControlsPaginator
  • NewGetVpcResourcesBlockingEncryptionEnforcementPaginator

Both operations already have NextToken + MaxResults on their input/output structs. The root cause of the missing paginators is the absence of the smithy.api#paginated trait in the upstream EC2 service model. Since the model file and generated source files are off-limits to direct modification per the contributing guidelines, this follows the established handwritten_paginators.go pattern used in service/s3, service/dynamodb, service/kinesis, and service/route53.

Testing

Unit tests added in service/ec2/handwritten_paginators_test.go covering:

  • Multi-page iteration with token propagation
  • Single-page (no token returned)
  • StopOnDuplicateToken behaviour
  • MaxResults/Limit propagation across pages
  • VpcId field preservation across pages (required field on GetVpcResourcesBlockingEncryptionEnforcement)

@pedrorfdez
pedrorfdez requested a review from a team June 4, 2026 16:57
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.

Missing Paginators for new VPC Encryption Control APIs

1 participant