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(efs): transition to archive for FileSystem #28719

Merged
merged 11 commits into from
Jan 18, 2024

Conversation

longtv2222
Copy link
Contributor

@longtv2222 longtv2222 commented Jan 16, 2024

This PR adds support for TransitionToArchive property for AWS::EFS::FileSystem

Also updated LifecyclePolicy to add missing values for TransitionToArchive and TransitionToIA

Docs

Closes #28720.


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

@github-actions github-actions bot added p2 repeat-contributor [Pilot] contributed between 3-5 PRs to the CDK labels Jan 16, 2024
@aws-cdk-automation aws-cdk-automation requested a review from a team January 16, 2024 01:14
@github-actions github-actions bot added the feature-request A feature should be added or improved. label Jan 16, 2024
@longtv2222 longtv2222 marked this pull request as ready for review January 16, 2024 02:37
@aws-cdk-automation aws-cdk-automation added the pr/needs-community-review This PR needs a review from a Trusted Community Member or Core Team Member. label Jan 16, 2024
longtv2222 and others added 2 commits January 16, 2024 08:11
Co-authored-by: Kyle Laker <kyle@laker.email>
@longtv2222 longtv2222 force-pushed the efs-transition-to-archive branch from eae85fd to 2e1513c Compare January 16, 2024 15:21
@longtv2222 longtv2222 requested a review from laurelmay January 16, 2024 16:35
Copy link
Contributor

@kaizencc kaizencc left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi @longtv2222, this looks great to me except for the one comment below. Thanks for contributing!

/**
* After 365 days of not being accessed.
*/
AFTER_365_DAYS = 'AFTER_365_DAYS',
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It looks like TransitionToIA and TransitionToArchive have the same set of enums excelt that TransitionToArchive does not allow AFTER_1_DAY source

Can you add in a synth-time check that throws an error if AFTER_1_DAY is set for transitionToArchivePolicy? Plus a unit test :)

Copy link
Contributor Author

@longtv2222 longtv2222 Jan 16, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It looks like they share the same set of enums to me. The order is a bit off for AFTER_1_DAY...

Submitted docs feedback for improvement.

Screenshot 2024-01-16 144600

From: https://docs.aws.amazon.com/efs/latest/ug/lifecycle-management-efs.html

image

Copy link
Contributor Author

@longtv2222 longtv2222 Jan 16, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm also able to create EFS with transitionToArchive set to 1 day as well! (I can update integration test to test AFTER_1_DAY for transitionToArchivePolicy if needed)

image

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🤦🤦🤦

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

sorry. the order screwed me up and shame on me for expecting the enum list to be in the same chronological order :)

@kaizencc kaizencc changed the title feat(efs): support transition to archive for FileSystem feat(efs): transition to archive for FileSystem Jan 16, 2024
@github-actions github-actions bot added the effort/medium Medium work item – several days of effort label Jan 16, 2024
@aws-cdk-automation aws-cdk-automation removed the pr/needs-community-review This PR needs a review from a Trusted Community Member or Core Team Member. label Jan 16, 2024
@longtv2222 longtv2222 requested a review from kaizencc January 16, 2024 21:54
Copy link
Contributor

mergify bot commented Jan 17, 2024

Thank you for contributing! Your pull request will be updated from main and then merged automatically (do not update manually, and be sure to allow changes to be pushed to your fork).

@aws-cdk-automation
Copy link
Collaborator

AWS CodeBuild CI Report

  • CodeBuild project: AutoBuildv2Project1C6BFA3F-wQm2hXv2jqQv
  • Commit ID: 710e935
  • Result: SUCCEEDED
  • Build Logs (available for 30 days)

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

@mergify mergify bot merged commit 03c08b0 into aws:main Jan 18, 2024
9 checks passed
Copy link
Contributor

mergify bot commented Jan 18, 2024

Thank you for contributing! Your pull request will be updated from main and then merged automatically (do not update manually, and be sure to allow changes to be pushed to your fork).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
effort/medium Medium work item – several days of effort feature-request A feature should be added or improved. p2 repeat-contributor [Pilot] contributed between 3-5 PRs to the CDK
Projects
None yet
Development

Successfully merging this pull request may close these issues.

efs: support TransitionToArchive property for AWS::EFS::FileSystem
4 participants