Skip to content

feat(aws-batch): restore unmanagedvCpus after provider support lands #140

Description

@sakul-learning

Summary

UnmanagedComputeEnvironmentProps.unmanagedvCpus is part of the AWS CDK API being ported in #136, but the generated @cdktn/provider-aws BatchComputeEnvironmentConfig cannot currently represent it because hashicorp/aws does not expose the AWS Batch API field on aws_batch_compute_environment.

Upstream provider tracking issue:

Until that provider enhancement is released and regenerated into @cdktn/provider-aws, #136 intentionally fails fast rather than silently accepting a capacity reservation that Terraform would omit.

Current fail-fast locations

At PR head 1c3ac230c3e88f164057e4911ff3d3b5568e56a9:

Work once provider support lands

After hashicorp/terraform-provider-aws#49311 is implemented and included in a published AWS Provider release:

  1. Upgrade/regenerate @cdktn/provider-aws so BatchComputeEnvironmentConfig exposes the new unmanaged_vcpus field.
  2. Remove the constructor ValidationError and the temporary TERRACONSTRUCTS DEVIATION: NOT SUPPORTED documentation.
  3. Forward UnmanagedComputeEnvironmentProps.unmanagedvCpus into the generated BatchComputeEnvironment resource configuration.
  4. Replace the current fail-fast unit test with synthesis assertions proving the Terraform JSON contains the expected value.
  5. Add/update an AWS integration test that performs terraform apply, verifies DescribeComputeEnvironments.unmanagedvCpus, updates the value and verifies it again, then performs terraform destroy and verifies cleanup.
  6. Confirm import/refresh does not drift before closing this issue.

Acceptance criteria

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions