feature: bring the cdk-preflight rule pack (~3,000 deploy-verified constraints) into the engine
Maintainer thường phản hồi trong vòng 1 ngày
Chưa có ai nhận issue này.
Đánh giá
- Độ khó
- 5/5
- Thời gian dự kiến
- Hơn một tuần
- Mức phù hợp với người mới
- 20/100
Hướng nghiên cứu
Read the approaches in #452, #467, and #468, along with CUSTOM_RULES.md and the cdk-preflight rules list in docs/rules.md. The issue asks maintainers to decide on review pace, rule grouping and IDs, implementation shape, packaging, evidence, and where to start; no code change is defined as done yet.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
Feature summary
I maintain cdk-preflight, a Rego rule pack for CloudFormation
constraints that resource schemas do not express. It runs on this engine through the built-in validator in
aws-cdk-lib. Now that #468 has been merged, I would like to move as much of the pack as possible into this
repository, so that every interface gets these checks, not only CDK users. Before I open more PRs, I would like to
agree with you on how to do it at this scale.
Problem or use case
The constraints in the pack live only in service documentation, in service API validation, or across several
properties. Templates that violate them pass this engine and CloudFormation pre-deployment validation, and then fail
during deployment and roll the stack back. E9014 (#467) is one example: five pack rules about EventPattern became one
engine rule.
What the pack contains (as of 2026-10-21; full list: docs/rules.md)
- 3,034 rules that this engine does not cover yet, over 76 services and 383 resource types.
- Every one of them was reproduced against a real account. Each rule has a failing and a passing template, and its
metadata records the date, the Region and the exact error, for example (shortened):
bench 2026-09-24 us-east-1: Replicas [{Location: us-east-1}] in a stack deploying to us-east-1 -> "Invalid request provided: Replica location us-east-1 cannot be the same as primary location us-east-1." (ROLLBACK_COMPLETE); pass no Replicas -> CREATE_COMPLETE - The rules read only the template (
Resources,Outputs,Parameters). None of them depends on CDK metadata or on
account state.
Questions
- Pace. Is a stream of PRs like #468 welcome, and how much can you review? For example, one PR per service or per
resource type, and how many per week. - Grouping and IDs. #468 grouped the checks for one property under one ID, as E3027 does. If I group the rest the
same way, the number of new IDs is somewhere between one per resource type (about 380) and one per property (more).
Engine-assigned rules use the 9xxx range. Is that range meant to hold hundreds of new IDs, and which grouping do you
prefer? - Implementation shape. #452 and #468 put the logic in
template-modeland call it from both engines (directly
from CEL, through a builtin from Rego). Should simple single-property checks follow the same shape, or be written as
a native CEL rule plus a hand-written Rego policy? - Built-in or optional. Would you rather have some of these as built-in rules and the rest as an optional rule
set that ships with the engine (for example as custom Rego, as described inCUSTOM_RULES.md)? - Evidence. Is the evidence format of #467 enough for each group, or would you like it in another form?
- Where to start. My suggestion is
AWS::Pipes::Pipeand Lambda event source mappingFilterCriteria, which use
the same grammar asEventPatternand can reuse the E9014 code (left as a follow-up in #467). If another service
matters more to you, I can start there instead.
Relevant interfaces: Not interface-specific
Does this change validation behavior? Yes, once each PR lands. This issue itself is about the process.
Additional context
The pack keeps shipping on its own, so nothing on the CDK side waits on this. When a group lands here, the pack stops
evaluating those rules on engines that include it, and deletes them once every supported aws-cdk-lib bundles such an
engine. Taking rules into this repository therefore never leaves the two sets reporting the same finding twice.
- Ngôn ngữ chính
- Rust
- Star
- 11
- Fork
- 6
- Merge trung bình
- 6 giờ 28 phút
- Pull request đã merge (30 ngày)
- 43
Chuẩn bị môi trường
- Không có Dockerfile hay tệp Docker Compose
- Có mẫu pull request
- Đọc hướng dẫn đóng góp
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của aws-cloudformation/cloudformation-validate
-
Độ khó 4/5 Hơn một tuần Mức phù hợp với người mới 8/100
aws-cloudformation/cloudformation-validate#454 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 35/100
aws-cloudformation/cloudformation-validate#69 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
F3017: unhelpful error messageĐang mở
Độ khó 3/5 1-2 ngày Mức phù hợp với người mới 55/100
aws-cloudformation/cloudformation-validate#61 ·
Maintainer thường phản hồi trong vòng 1 ngày
Tất cả issue của aws-cloudformation/cloudformation-validate
Issue tương tự
-
enhancement
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 70/100
zellij-org/zellij#5929 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
bug
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 85/100
swc-project/swc-next-issues#396 ·
-
bug
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 83/100
nautechsystems/nautilus_trader#5685 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
bug db/postgres user-priority/P1
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 68/100
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100