From f5e0497bffea5f0fe0ef11cdb40b11ddba171258 Mon Sep 17 00:00:00 2001 From: Nick Cipollina Date: Mon, 23 Nov 2026 21:27:16 -0500 Subject: [PATCH 01/19] chore(beads): record 3.0.0 planning beads (cdkc-2lh) Exports the 3.0.0 epic cdkc-2lh and its six children (#108-#112 and the two owner gates) through the repository's committed issues.jsonl convention. Existing records are unchanged. Co-Authored-By: Claude Opus 5.5 --- .beads/issues.jsonl | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/.beads/issues.jsonl b/.beads/issues.jsonl index 4ab482f..54d1258 100644 --- a/.beads/issues.jsonl +++ b/.beads/issues.jsonl @@ -15,6 +15,13 @@ {"_type":"issue","id":"cdkc-18e.2","title":"T1: Add Web Function public models, options, and value validation","description":"Purpose: introduce the public model/value types every later bead consumes, with value validation. Design §8.1, §8.2, §8.3 (props + WebFunctionLogs), §8.4 (options/attributes), §8.5 (origin props), §8.7, §10.2 (WebFunctionCallerPolicy, WebFunctionInvokeGrantOptions), §14.\n\nDeliverables (namespace LayeredCraft.Cdk.Constructs.Models unless noted; follow the newest Cognito style: get-only interfaces + init-only sealed records, XML docs):\n- Enums: WebFunctionAuthType {IamAuth, ApplicationManaged}; WebFunctionEndpointType {HomeRegion, MultiRegion, PerRegion};\n WebFunctionCodeBucketPolicy {Automatic, ExternallyManaged}; WebFunctionOriginPermissions {Automatic, ExternallyManaged};\n WebFunctionCallerPolicy {Automatic, ExternallyManaged}.\n- WebFunctionRuntime (sealed; NodeJs24X = \"nodejs24.x\"; Of(string)).\n- WebFunctionCode (abstract, private protected ctor, closed hierarchy) with static FromBucket(IBucket, string key, WebFunctionCodeFromBucketOptions?)\n and WebFunctionCodeFromBucketOptions {ObjectVersion, BucketPolicy = Automatic}. The internal Bind contract to the construct is\n declared but bucket-policy wiring is implemented in the core-construct bead; keep the binding surface internal so FromAsset can be added later.\n- WebFunctionLogs (abstract, closed): Create(RetentionDays? retention = null [→ TWO_WEEKS], RemovalPolicy? [→ DESTROY]), Use(ILogGroup), ServiceDefault().\n- IWebFunctionConstructProps / WebFunctionConstructProps exactly per §8.3 (FunctionName, Code, Endpoint required; Runtime, EntryPoint,\n EnvironmentVariables, Timeout=30s, MaxConcurrencyPerEnvironment, Description, Role, Logs=Create(), ApplicationLogLevel, SystemLogLevel\n reusing Amazon.CDK.AWS.Lambda enums). NO EncryptionKey property.\n- IWebFunctionEndpointOptions / WebFunctionEndpointOptions (EndpointName=\"default\", required AuthType, EndpointType=HomeRegion, Regions, MaxEnvironments, RateLimit, Description).\n- WebFunctionEndpointAttributes (EndpointArn, DomainName, AuthType required; EndpointType=HomeRegion).\n- WebFunctionInvokeGrantOptions {CallerPolicy = Automatic}.\n- WebFunctionOriginProps (explicit members only: OriginId, OriginPath, CustomHeaders, ConnectionAttempts, ConnectionTimeout, ReadTimeout,\n KeepaliveTimeout, ResponseCompletionTimeout, OriginShieldEnabled, OriginShieldRegion) and sealed WebFunctionOriginWithOacProps : WebFunctionOriginProps\n {OriginAccessControl, Permissions = Automatic}. Must NOT expose ProtocolPolicy or OriginAccessControlId.\n- Internal validation helpers (local to new types; do not refactor shared code or existing constructs) for §14 value rules: FunctionName\n regex 1–64; EndpointName 1–64 [A-Za-z0-9_-]; Timeout 3–900 whole seconds; MaxConcurrencyPerEnvironment 1–128; MaxEnvironments 2–10000;\n RateLimit grid {0} ∪ 100..1000 step 100 ∪ 2000..10000 step 1000; Regions rules; env var key regex; EntryPoint relative/no \"..\";\n reserved AWS_LAMBDA_HTTP_ENDPOINT; EntryPoint vs AWS_LAMBDA_NODEJS_ENTRYPOINT conflict. Unresolved tokens (Token.IsUnresolved) are skipped, never rejected.\n Exception types per §14 (ArgumentException / ArgumentOutOfRangeException / InvalidOperationException).\n\nExpected files: src/LayeredCraft.Cdk.Constructs/Models/WebFunction*.cs (one type per file or small cohesive groups); test/.../WebFunctionModelsTests.cs (+ validation tests).\nExclusions: no constructs, no CloudFormation resources, no IBucket policy mutation yet, no testing-namespace helpers, no docs.\nEdge cases: FunctionName must allow tokens; nullable reference types enabled; records must be init-only (no Action\u003c\u003e mutation APIs anywhere).\n","acceptance_criteria":"- All listed public types exist with the exact names, members, and defaults in design §8.1–§8.5, §8.7 (no EncryptionKey), §10.2.\n- WebFunctionConstructProps cannot be constructed without FunctionName, Code, and Endpoint; WebFunctionEndpointOptions cannot be constructed without AuthType (compile-time `required`).\n- Every §14 value rule has a positive and negative unit test; tokens bypass literal validation (tested).\n- WebFunctionLogs.Create() defaults are TWO_WEEKS and DESTROY (tested).\n- No existing source file outside new WebFunction* files changed; existing golden templates still pass.\n- Validation gates pass.","notes":"T1 IMPLEMENTED (public WebFunction model/value types + §14 value validation). Not committed per task restriction.\n\nDELIVERABLES (src/LayeredCraft.Cdk.Constructs/Models/):\n- Enums: WebFunctionAuthType (IamAuth, ApplicationManaged), WebFunctionEndpointType (HomeRegion, MultiRegion, PerRegion), WebFunctionCodeBucketPolicy (Automatic, ExternallyManaged), WebFunctionOriginPermissions (Automatic, ExternallyManaged), WebFunctionCallerPolicy (Automatic, ExternallyManaged).\n- WebFunctionRuntime: sealed; NodeJs24X='nodejs24.x'; Of(string) escape hatch.\n- WebFunctionCode: abstract closed hierarchy (private protected ctor); static FromBucket(IBucket,string,WebFunctionCodeFromBucketOptions?); internal sealed WebFunctionCodeFromBucket. Options: WebFunctionCodeFromBucketOptions { ObjectVersion; BucketPolicy=Automatic }.\n- WebFunctionLogs: abstract closed; Create(RetentionDays?=TWO_WEEKS, RemovalPolicy?=DESTROY) / Use(ILogGroup) / ServiceDefault(); internal concrete subtypes.\n- IWebFunctionConstructProps + WebFunctionConstructProps: FunctionName/Code/Endpoint required; Runtime=NodeJs24X; EntryPoint; EnvironmentVariables; Timeout=30s; MaxConcurrencyPerEnvironment; Description; Role; Logs=Create(); ApplicationLogLevel; SystemLogLevel. NO EncryptionKey (deferred KMS, §8.7).\n- IWebFunctionEndpointOptions + WebFunctionEndpointOptions: EndpointName='default'; required AuthType (explicit selection, no default); EndpointType=HomeRegion; Regions=[]; MaxEnvironments; RateLimit; Description.\n- WebFunctionEndpointAttributes: required EndpointArn/DomainName/AuthType; EndpointType=HomeRegion.\n- WebFunctionInvokeGrantOptions: CallerPolicy=Automatic (explicit ownership contract).\n- WebFunctionOriginProps + sealed WebFunctionOriginWithOacProps (no ProtocolPolicy/OriginAccessControlId).\n- WebFunctionValidation (internal static): §14 helpers (FunctionName, EndpointName, Timeout, MaxConcurrencyPerEnvironment, MaxEnvironments, RateLimit grid, Regions, env var keys, env var map, EntryPoint incl reserved AWS_LAMBDA_HTTP_ENDPOINT and AWS_LAMBDA_NODEJS_ENTRYPOINT conflict). Token-aware: unresolved tokens (Token.IsUnresolved / Fn.Ref) bypass literal validation. Exceptions per §14 (ArgumentException / ArgumentOutOfRangeException).\n- [assembly: InternalsVisibleTo(\"LayeredCraft.Cdk.Constructs.Tests\")] added (new file) so validation is unit-testable.\n\nTESTS (test/LayeredCraft.Cdk.Constructs.Tests/): WebFunctionModelsTests.cs (defaults, required values, immutability, factory arg validation, crypto/logs/endpoint/origin surface) + WebFunctionValidationTests.cs (positive+negative per §14 rule, boundary values, token bypass). +110 tests/TFM ([Collection(\"CDK Tests\")], xUnit v3, AwesomeAssertions).\n\nCOMMANDS/RESULTS (JSII_SILENCE_WARNING_UNTESTED_NODE_VERSION=1):\n- dotnet build LayeredCraft.Cdk.Constructs.slnx -c Release -\u003e 0 warnings, 0 errors.\n- dotnet test --solution LayeredCraft.Cdk.Constructs.slnx -c Release -\u003e 1184 passed / 0 failed / 0 skipped (296 x net8.0/net9.0/net10.0/net11.0). Baseline was 744 (186x4).\n- 17 golden templates UNCHANGED; ExistingConstructsGoldenTemplateTests passed (zero diff). Goldens NOT regenerated.\n\nSCOPE: no constructs, no CFN resources, no IBucket policy mutation, no Testing helpers, no docs. No existing (pre-T1) source file modified; only new WebFunction*.cs files added. No new dependencies.\n\nINTENTIONAL DEVIATION (must be reported): design §8.2 declares internal 'abstract WebFunctionCodeConfig Bind(WebFunctionConstruct function)'. WebFunctionConstruct is created in T2 (cdkc-18e.3), so this internal seam cannot be declared in T1 without the type. Deferred Bind to T2 (which already owns the construct + bucket-policy wiring). Public contract unchanged. Recommendation: T2 declares the abstract Bind on WebFunctionCode and overrides it in WebFunctionCodeFromBucket. No other deviation from the approved design.","spec_id":"docs/designs/lambda-web-functions-integration.md","status":"closed","priority":1,"issue_type":"task","assignee":"Nick Cipollina","owner":"ncipollina@gmail.com","created_at":"2026-10-23T01:14:47Z","created_by":"Nick Cipollina","updated_at":"2026-10-23T01:53:01Z","started_at":"2026-10-23T01:38:29Z","closed_at":"2026-10-23T01:53:01Z","close_reason":"Implemented T1: public WebFunction model/value types (auth/endpoint-type/bucket-policy/origin-permissions/caller-policy enums, WebFunctionRuntime, closed WebFunctionCode+FromBucket, closed WebFunctionLogs with Create/Use/ServiceDefault, IWebFunctionConstructProps+record, IWebFunctionEndpointOptions+record, EndpointAttributes, InvokeGrantOptions, OriginProps+WithOacProps) and internal token-aware WebFunctionValidation for all §14 value rules. Added 2 test files (WebFunctionModelsTests, WebFunctionValidationTests) = +110 tests/TFM. Build 0 warnings/0 errors; full suite 1184/1184 passed across net8.0/9.0/10.0/11.0; all 17 existing golden templates unchanged (goldens not regenerated). No existing source modified, no constructs/CFN resources/IBucket mutation/Testing helpers/docs added. Internal Bind(WebFunctionConstruct) seam intentionally deferred to T2 (cdkc-18e.3) because the construct type does not exist in T1; public contract unaffected.","external_ref":"gh-98","labels":["lambda-web-functions","models","t1"],"dependencies":[{"issue_id":"cdkc-18e.2","depends_on_id":"cdkc-18e","type":"parent-child","created_at":"2026-10-23T01:14:47Z","created_by":"Nick Cipollina","metadata":"{}"},{"issue_id":"cdkc-18e.2","depends_on_id":"cdkc-18e.1","type":"blocks","created_at":"2026-10-23T01:15:09Z","created_by":"Nick Cipollina","metadata":"{}"}],"dependency_count":1,"dependent_count":1,"comment_count":0} {"_type":"issue","id":"cdkc-18e.1","title":"T0: Upgrade Amazon.CDK.Lib to 2.274.0 and add golden-template baseline for existing constructs","description":"Purpose: separate review checkpoint that raises the CDK floor and proves existing constructs are unchanged. Design §5.5, §12.4 (Enforcement), §13, §19 T0.\n\nREQUIRED ORDER (do not reorder):\n a. Confirm Directory.Packages.props still pins Amazon.CDK.Lib 2.273.0 (`dotnet list test/LayeredCraft.Cdk.Constructs.Tests package --include-transitive | grep Amazon.CDK.Lib`). If it is already 2.274.0, STOP and record a blocker: the baseline can no longer be produced from the original version.\n b. Generate the golden baseline ON 2.273.0, run the tests once to prove the baseline passes on 2.273.0, and record the 2.273.0 SHA-256 of every golden file in the bead notes.\n c. Only then change Amazon.CDK.Lib to 2.274.0, restore, and run the golden tests in COMPARE mode (regeneration env var unset) against the unchanged 2.273.0 baseline.\n d. If any template differs: do NOT regenerate, accept, or edit golden files; do NOT adjust normalization to hide the diff. Record the full diff (construct, resource, property, old → new) on this bead with `bd update \u003cid\u003e --append-notes`, set the bead to blocked (`bd update \u003cid\u003e --status blocked`), and report to the maintainer. Leave 2.274.0 in place only together with the failing tests and the recorded diff.\n\nScope:\n1. BEFORE changing the CDK version, add a test-only golden-template harness and capture golden templates on the current\n Amazon.CDK.Lib 2.273.0 for the four existing constructs (LambdaFunctionConstruct, StaticSiteConstruct, DynamoDbTableConstruct,\n CognitoUserPoolConstruct) in default and representative configurations (e.g. Lambda: OTEL on/off, URL on/off, permissions;\n StaticSite: with/without ApiDomain and alternate domains; DynamoDB: GSI/stream/TTL; Cognito: domain prefix vs custom domain with\n explicit IHostedZone/ICertificate, groups, resource servers). Avoid configurations that require HostedZone.FromLookup unless the\n test supplies context; prefer deterministic inputs (no random AutoFixture values in golden stacks).\n2. Bump Amazon.CDK.Lib to 2.274.0 in Directory.Packages.props (the only dependency change).\n3. Re-run: golden templates must be identical (zero diff).\n\nHarness requirements (reused by later beads):\n- Lives in the test project (e.g. test/LayeredCraft.Cdk.Constructs.Tests/TestKit/Golden/GoldenTemplate.cs) with golden files under\n test/LayeredCraft.Cdk.Constructs.Tests/GoldenTemplates/*.json (copied to output).\n- Compares the COMPLETE synthesized template (Template.FromStack(...).ToJSON()), normalized only for asset hashes / asset\n S3 keys and CDK metadata (aws:cdk:path, CDKMetadata resource, BootstrapVersion parameter/rule). Document normalization in code.\n- Regeneration only when an env var (e.g. UPDATE_GOLDEN_TEMPLATES=1) is set; default mode fails on any diff with a readable diff message.\n- Stable across all target frameworks (net8.0–net11.0).\n\nExpected files: Directory.Packages.props; test/.../TestKit/Golden/*; test/.../GoldenTemplates/*.json; test/.../ExistingConstructsGoldenTemplateTests.cs; test csproj (copy golden files).\n\nExclusions: no changes to src/ production code; no new constructs; no other package bumps.\nEdge cases: CDK 2.274 may change synthesized output of existing constructs (e.g. new defaults/feature flags). If any golden diff\nappears after the bump, STOP and record the diff on this bead as a blocker for maintainer review; do not \"fix\" by editing goldens.\nAlso record whether CDK default-rule validation still warns \"Unknown resource type AWS::Lambda::WebFunction\" on 2.274 (design §5.5).\n","acceptance_criteria":"- Golden templates for all four existing constructs were generated on Amazon.CDK.Lib 2.273.0 BEFORE the upgrade, passed on 2.273.0, and their SHA-256 hashes are recorded in notes.\n- After upgrading to 2.274.0 the comparison ran against that ORIGINAL baseline; golden-file hashes are unchanged (no regeneration or acceptance of snapshots).\n- If the upgrade changed any synthesized template, the bead is blocked with the recorded diff instead of closed.\n- Directory.Packages.props uses Amazon.CDK.Lib 2.274.0; no other dependency changed.\n- After the bump all golden tests pass with zero diff on every target framework.\n- Harness supports regeneration via env var and fails readably on diff by default.\n- Full validation gates (restore/build/test) pass; coverage threshold not reduced.\n- Notes record commands run, the golden file list, and the 2.274 CloudFormation-Validate warning observation.","notes":"T0 (cdkc-18e.1) implementation evidence\n\nFILES CHANGED / ADDED\n- Directory.Packages.props: Amazon.CDK.Lib 2.273.0 -\u003e 2.274.0 (ONLY dependency change; diff is a single line).\n- test/LayeredCraft.Cdk.Constructs.Tests/LayeredCraft.Cdk.Constructs.Tests.csproj: added \u003cNone Update=\"GoldenTemplates\\**\\*.json\"\u003e\u003cCopyToOutputDirectory\u003ePreserveNewest\u003c/CopyToOutputDirectory\u003e.\n- test/LayeredCraft.Cdk.Constructs.Tests/TestKit/Golden/GoldenTemplate.cs (new): golden harness.\n- test/LayeredCraft.Cdk.Constructs.Tests/ExistingConstructsGoldenTemplateTests.cs (new): 17 golden cases across the 4 existing constructs.\n- test/LayeredCraft.Cdk.Constructs.Tests/GoldenTemplates/*.json (new): 17 baseline golden templates.\nNo changes to src/ production code.\n\nGOLDEN COVERAGE ADDED (17 templates)\n- LambdaFunctionConstruct: lambda-default, lambda-otel-amd64, lambda-otel-arm64, lambda-permissions, lambda-url, lambda-otel-url-permissions.\n- StaticSiteConstruct: static-site-default, static-site-api, static-site-alternates, static-site-full.\n- DynamoDbTableConstruct: dynamodb-default, dynamodb-sort-key, dynamodb-gsi, dynamodb-stream-ttl.\n- CognitoUserPoolConstruct: cognito-prefix-domain, cognito-custom-domain, cognito-no-domain.\n\nNORMALIZATION (documented in GoldenTemplate.cs)\nCompares the COMPLETE Template.FromStack(...).ToJSON(). Only: BootstrapVersion parameter + CheckBootstrapVersion rule removed; AWS::CDK::Metadata resource removed; per-resource Metadata removed (aws:cdk:path / aws:asset:path); 64-hex asset content hashes / S3 keys replaced with \u003cASSET-HASH\u003e. No other keys altered. Regeneration only when UPDATE_GOLDEN_TEMPLATES is truthy; default mode fails with a readable -/+ line diff and never overwrites the golden. Golden files resolve from the source tree (walk-up to project dir) with an output-dir fallback.\n\nCOMMANDS + RESULTS\n- Baseline restore on 2.273.0: `dotnet restore LayeredCraft.Cdk.Constructs.slnx` OK.\n- Baseline test on 2.273.0: `dotnet test --solution LayeredCraft.Cdk.Constructs.slnx -c Release` -\u003e PASSED, 186 x net8.0/net9.0/net10.0/net11.0 (744 total), 0 failed, 0 skipped.\n- Golden files SHA-256 recorded, then upgrade to 2.274.0: `dotnet restore` OK; `dotnet list ... package` shows Amazon.CDK.Lib 2.274.0.\n- Post-upgrade test on 2.274.0 (against the ORIGINAL unchanged baseline): `dotnet test --solution LayeredCraft.Cdk.Constructs.slnx -c Release` -\u003e PASSED, 186 x4 TFMs (744 total), 0 failed, 0 skipped, ZERO golden diff on every TFM.\n- `shasum -a 256` before vs after: HASHES IDENTICAL (git tracked files unmodified by the run).\n\nBASELINE SHA-256 (identical before and after upgrade)\n66398f765a746fbe76268e666d0b492ddb8aadec9f2c4c76d17a25b6981cc769 cognito-custom-domain.json\n3396b3ceeedbd15de26119076158e3f1d0c8bc638f1a2be556e8d87fa8dce30b cognito-no-domain.json\nd18cc32d82a07f45534584a59f5431540883baf24d4bf7311a8ebe14c0ac5447 cognito-prefix-domain.json\n0d5397ab86db3dd0194fd4a6463ebd9461005c65f7964be0b617dfab9ade384e dynamodb-default.json\n07a9509cad0feb734c4c48eec96b4271a9e7c80acb7bdcf39a4bfb6de300e80d dynamodb-gsi.json\n1517371079a842ed38ac411b64e1c4093c80e6b896a77b0ca766762ef9e8412b dynamodb-sort-key.json\n5a500b2d5d2073d0747b355aa19aae5092d8754ad8e529776bebb91997679ab8 dynamodb-stream-ttl.json\nd1038f5889457882b0a50736446376b8a05d9430db99429b39bec989bcd3073b lambda-default.json\n796c2acdaca4bb90df681ddfcd05c5867ed3d0e8e05b0ec417d4cac067fed881 lambda-otel-amd64.json\n26f601e11cb042ed163cc595fb9131bbb1fddbaa0d6993ff6d3a1dfcf094c543 lambda-otel-arm64.json\n8aadb2159cc9febd6a73a7aa888ce470b3ef81eabc8c857174615166efd3b1ff lambda-otel-url-permissions.json\n648cd4745abb61979544466c171b72f7cc70b1e239ca43ec4a58c0e50151a9f6 lambda-permissions.json\nf9b86ad9c94ad499e373df8b97536e0525b4d0565c34539a75df0bd720308362 lambda-url.json\nb1bc13271470ae7136b8f085de3f584e51409acb69788764957079df1c3dd639 static-site-alternates.json\nb5e4a36010f31a7666cc0b9fb0ce94754ed046bb1a6cf3a993bf57d7b0970973 static-site-api.json\n1eb6acb8bd3579c9157ee82fe94e24727c35dafa91828dd7f5d9cc3359cc8f38 static-site-default.json\n63bfa34136f47b16bd7829efa91c8b66b1d000bb2096beeccf961e8ff5a09a04 static-site-full.json\n\n2.274 CLOUDFORMATION DEFAULT-RULE VALIDATION OBSERVATION\nStill warn-only (feature flag @aws-cdk/core:validateAgainstDefaultRules remains OFF by default). A temporary probe that synthesized a raw CfnResource of type AWS::Lambda::WebFunction emitted:\n WARNING Unknown resource type 'AWS::Lambda::WebFunction' (CloudFormation Validate) [CloudFormation-Validate::F3006]\n Set feature flag \"@aws-cdk/core:validateAgainstDefaultRules\" to true to turn these into errors.\nSo the unknown AWS::Lambda::WebFunction type is still only a warning (not an error) on 2.274. Note: the 2.274 assembly does now ship CfnWebFunction / CfnWebFunctionEndpoint / CfnWebFunctionRevision L1 types. The temporary probe file was removed and is not part of the deliverable.\n\nCOVERAGE\nsrc/ production code is unchanged, so the CI 80% coverage gate is unaffected.\n\nRESTRICTIONS HONORED\nNo src/ changes, no new constructs, no other dependency bumps, goldens not regenerated/adjusted, normalization not weakened, no commit/push/PR/deploy/publish.","spec_id":"docs/designs/lambda-web-functions-integration.md","status":"closed","priority":1,"issue_type":"task","assignee":"Nick Cipollina","owner":"ncipollina@gmail.com","created_at":"2026-10-23T01:14:46Z","created_by":"Nick Cipollina","updated_at":"2026-10-23T01:32:51Z","started_at":"2026-10-23T01:23:53Z","closed_at":"2026-10-23T01:32:51Z","close_reason":"T0 complete: golden baseline (17 templates, 4 constructs) captured and verified on 2.273.0; Amazon.CDK.Lib bumped to 2.274.0 (only dependency change); goldens re-verified against unchanged baseline with zero diff and identical SHA-256 on all 4 TFMs; 186x4 tests pass. 2.274 default-rule validation still warns (not errors) on unknown AWS::Lambda::WebFunction.","external_ref":"gh-98","labels":["baseline","lambda-web-functions","t0"],"dependencies":[{"issue_id":"cdkc-18e.1","depends_on_id":"cdkc-18e","type":"parent-child","created_at":"2026-10-23T01:14:46Z","created_by":"Nick Cipollina","metadata":"{}"}],"dependency_count":0,"dependent_count":1,"comment_count":0} {"_type":"issue","id":"cdkc-18e","title":"AWS Lambda Web Functions support — LayeredCraft.Cdk.Constructs","description":"Implement AWS Lambda Web Functions support in LayeredCraft.Cdk.Constructs per the APPROVED design (revision 3):\ndocs/designs/lambda-web-functions-integration.md (authoritative; GitHub issue #98).\n\nScope: new additive constructs WebFunctionConstruct, WebFunctionEndpointConstruct/IWebFunctionEndpoint, WebFunctionOrigin,\nWebFunctionCode.FromBucket, WebFunctionLogs, supporting models, Testing helpers, docs, and a mandatory AWS sandbox release gate.\n\nNon-negotiable constraints (design §2, §6, §8, §10.2, §12.4):\n- Hybrid composition; L3 over CDK L1 (CfnWebFunction/Revision/Endpoint, CfnResourcePolicy); no upstream alpha/L2 dependency;\n upstream L2 types never appear in the public API.\n- Existing constructs (LambdaFunctionConstruct, StaticSiteConstruct, DynamoDbTableConstruct, CognitoUserPoolConstruct) are\n NOT modified; their synthesized templates must not change (golden templates from cdkc T0).\n- Explicit AuthType on every endpoint (no default). Single-owner resource policy per function. Same-stack automatic OAC\n permissions only. Limited endpoint imports (no whole-function import). Existing S3 artifacts only (no FromAsset).\n Default log retention TWO_WEEKS. No customer-managed revision KMS key. Workload-neutral (Next.js, ASP.NET Core shim,\n Blazor Static SSR) with no workload-specific constructs.\n- GrantInvoke follows the revision-3 algorithm in §10.2 (account establishment E1/E2, Automatic vs ExternallyManaged).\n Never use Grant.AddToPrincipalOrResource or trust Grant.Success/AssertSuccess.\n- Amazon.CDK.Lib floor 2.274.0.\n\nRules for every implementation agent:\n- Implement only the claimed bead's scope. If the design is ambiguous or seems wrong, stop and record a blocker note on\n the bead (bd update \u003cid\u003e --append-notes ...) instead of changing the design.\n- Do not commit, push, open PRs, publish NuGet packages, or close GitHub issue #98 unless separately authorized by the maintainer.\n- Do not deploy to AWS except in the sandbox bead, and only with maintainer-provided non-production credentials.\n- Do not modify the Sharedale repository.\n- Validation gates (run from repo root): `dotnet restore LayeredCraft.Cdk.Constructs.slnx`, `dotnet build LayeredCraft.Cdk.Constructs.slnx -c Release`,\n `dotnet test --solution LayeredCraft.Cdk.Constructs.slnx -c Release` (Microsoft.Testing.Platform, see global.json); CI requires\n 80% coverage across net8.0–net11.0. Docs: `uv run mkdocs build --clean`. If Node \u003e24 prints jsii warnings, set\n JSII_SILENCE_WARNING_UNTESTED_NODE_VERSION=1.\n- Test conventions: xUnit v3, AwesomeAssertions, AutoFixture TestKit customizations, `[Collection(\"CDK Tests\")]`, Template.FromStack\n after constructs are added (see CLAUDE.md \"Testing Patterns\").\n- Close a bead only when its acceptance criteria are met; record validation evidence (commands run + results) in notes.\n\nFeature completion is gated by the \"Verify release acceptance criteria\" bead, which depends on the sandbox deployment bead.\nOptional bead T4a never blocks completion.\n","acceptance_criteria":"All required child beads closed, including the AWS sandbox release gate and the release acceptance verification bead; optional spike may be open or closed.","notes":"Agent workflow: find work with 'bd ready --parent cdkc-18e --exclude-type epic'; read 'bd show \u003cid\u003e' (description, acceptance, deps); claim with 'bd update \u003cid\u003e --claim' (or --status in_progress); record evidence with 'bd update \u003cid\u003e --append-notes \"...\"'; close with 'bd close \u003cid\u003e --reason \"...\"' only when acceptance criteria are met; then re-run bd ready. Never claim or close this epic directly: when all children are closed, the maintainer runs 'bd epic close-eligible'. Optional spike cdkc-18e.7 never blocks required work; close it with outcome A or B before epic closure. The feature is complete only after cdkc-18e.14 (which depends on the mandatory AWS sandbox gate cdkc-18e.13).","spec_id":"docs/designs/lambda-web-functions-integration.md","status":"closed","priority":1,"issue_type":"epic","owner":"ncipollina@gmail.com","created_at":"2026-10-23T01:14:45Z","created_by":"Nick Cipollina","updated_at":"2026-10-27T20:08:16Z","closed_at":"2026-10-27T20:08:16Z","close_reason":"All children completed","external_ref":"gh-98","labels":["lambda-web-functions"],"dependency_count":0,"dependent_count":0,"comment_count":0} +{"_type":"issue","id":"cdkc-2lh.6","title":"HUMAN GATE: owner publishes the v3.0.0 stable release","description":"After #112 downstream validation evidence. Publishing the GitHub release triggers publish-release.yaml (NuGet push).","acceptance_criteria":"Owner publishes; release URL + NuGet version recorded.","status":"open","priority":2,"issue_type":"task","owner":"ncipollina@gmail.com","created_at":"2026-11-24T01:27:25Z","created_by":"Nick Cipollina","updated_at":"2026-11-24T01:27:25Z","labels":["human-gate","release:v3.0.0"],"dependencies":[{"issue_id":"cdkc-2lh.6","depends_on_id":"cdkc-2lh","type":"parent-child","created_at":"2026-11-24T01:27:25Z","created_by":"Nick Cipollina","metadata":"{}"},{"issue_id":"cdkc-2lh.6","depends_on_id":"cdkc-2lh.5","type":"blocks","created_at":"2026-11-24T01:27:31Z","created_by":"Nick Cipollina","metadata":"{}"}],"dependency_count":1,"dependent_count":0,"comment_count":0} +{"_type":"issue","id":"cdkc-2lh.5","title":"#112 3.0.0: downstream validation (Jedi Duel, Sharedale) and stable release","description":"https://github.com/LayeredCraft/cdk-constructs/issues/112 (authoritative). Throwaway-branch validation against the same 3.0.0-preview in both consumers; nothing merged downstream here.","acceptance_criteria":"See #112.","status":"open","priority":2,"issue_type":"feature","owner":"ncipollina@gmail.com","created_at":"2026-11-24T01:27:24Z","created_by":"Nick Cipollina","updated_at":"2026-11-24T01:27:24Z","external_ref":"gh-112","labels":["release:v3.0.0"],"dependencies":[{"issue_id":"cdkc-2lh.5","depends_on_id":"cdkc-2lh","type":"parent-child","created_at":"2026-11-24T01:27:24Z","created_by":"Nick Cipollina","metadata":"{}"},{"issue_id":"cdkc-2lh.5","depends_on_id":"cdkc-2lh.3","type":"blocks","created_at":"2026-11-24T01:27:29Z","created_by":"Nick Cipollina","metadata":"{}"},{"issue_id":"cdkc-2lh.5","depends_on_id":"cdkc-2lh.4","type":"blocks","created_at":"2026-11-24T01:27:30Z","created_by":"Nick Cipollina","metadata":"{}"}],"dependency_count":2,"dependent_count":1,"comment_count":0} +{"_type":"issue","id":"cdkc-2lh.4","title":"#111 3.0.0: private static-assets construct (BPA, OAC, optional DNS, immutable deployment)","description":"https://github.com/LayeredCraft/cdk-constructs/issues/111 (authoritative).","acceptance_criteria":"See #111.","status":"open","priority":2,"issue_type":"feature","owner":"ncipollina@gmail.com","created_at":"2026-11-24T01:27:22Z","created_by":"Nick Cipollina","updated_at":"2026-11-24T01:27:22Z","external_ref":"gh-111","labels":["release:v3.0.0"],"dependencies":[{"issue_id":"cdkc-2lh.4","depends_on_id":"cdkc-2lh","type":"parent-child","created_at":"2026-11-24T01:27:22Z","created_by":"Nick Cipollina","metadata":"{}"},{"issue_id":"cdkc-2lh.4","depends_on_id":"cdkc-2lh.2","type":"blocks","created_at":"2026-11-24T01:27:28Z","created_by":"Nick Cipollina","metadata":"{}"}],"dependency_count":1,"dependent_count":1,"comment_count":0} +{"_type":"issue","id":"cdkc-2lh.3","title":"#110 3.0.0: LambdaFunctionConstruct U1 alias name, U2 alias-only default, U3 public alias, U4 scoped log policy, U7 S3 artifacts","description":"https://github.com/LayeredCraft/cdk-constructs/issues/110 (authoritative).","acceptance_criteria":"See #110.","status":"open","priority":2,"issue_type":"feature","owner":"ncipollina@gmail.com","created_at":"2026-11-24T01:27:21Z","created_by":"Nick Cipollina","updated_at":"2026-11-24T01:27:21Z","external_ref":"gh-110","labels":["release:v3.0.0"],"dependencies":[{"issue_id":"cdkc-2lh.3","depends_on_id":"cdkc-2lh","type":"parent-child","created_at":"2026-11-24T01:27:21Z","created_by":"Nick Cipollina","metadata":"{}"},{"issue_id":"cdkc-2lh.3","depends_on_id":"cdkc-2lh.2","type":"blocks","created_at":"2026-11-24T01:27:27Z","created_by":"Nick Cipollina","metadata":"{}"}],"dependency_count":1,"dependent_count":1,"comment_count":0} +{"_type":"issue","id":"cdkc-2lh.2","title":"#109 3.0.0: drop net8/net9, update all dependencies, SDK and workflows, Compono-first tests (+ design doc)","description":"https://github.com/LayeredCraft/cdk-constructs/issues/109 (authoritative). Golden templates byte-identical; breaking-change label; supersedes Dependabot #101; first merge publishes 3.0.0-preview.N.","acceptance_criteria":"See #109.","status":"open","priority":2,"issue_type":"feature","owner":"ncipollina@gmail.com","created_at":"2026-11-24T01:27:20Z","created_by":"Nick Cipollina","updated_at":"2026-11-24T01:27:20Z","external_ref":"gh-109","labels":["release:v3.0.0"],"dependencies":[{"issue_id":"cdkc-2lh.2","depends_on_id":"cdkc-2lh","type":"parent-child","created_at":"2026-11-24T01:27:20Z","created_by":"Nick Cipollina","metadata":"{}"},{"issue_id":"cdkc-2lh.2","depends_on_id":"cdkc-2lh.1","type":"blocks","created_at":"2026-11-24T01:27:26Z","created_by":"Nick Cipollina","metadata":"{}"}],"dependency_count":1,"dependent_count":2,"comment_count":0} +{"_type":"issue","id":"cdkc-2lh.1","title":"HUMAN GATE: owner authorizes 3.0.0 implementation","description":"Planning authorized 2026-11-24 (issues/Beads only). Implementation needs the owner's separate explicit authorization.","acceptance_criteria":"Owner authorization quoted in a note.","status":"open","priority":2,"issue_type":"task","owner":"ncipollina@gmail.com","created_at":"2026-11-24T01:27:19Z","created_by":"Nick Cipollina","updated_at":"2026-11-24T01:27:19Z","labels":["human-gate","release:v3.0.0"],"dependencies":[{"issue_id":"cdkc-2lh.1","depends_on_id":"cdkc-2lh","type":"parent-child","created_at":"2026-11-24T01:27:19Z","created_by":"Nick Cipollina","metadata":"{}"}],"dependency_count":0,"dependent_count":1,"comment_count":0} +{"_type":"issue","id":"cdkc-2lh","title":"LayeredCraft.Cdk.Constructs 3.0.0 — .NET 10/11 modernization, LambdaFunctionConstruct options, private static assets","description":"GitHub milestone v3.0.0 https://github.com/LayeredCraft/cdk-constructs/milestone/1 ; epic issue https://github.com/LayeredCraft/cdk-constructs/issues/108 (authoritative scope; Beads = execution state). Owner decisions 2026-11-24: dogfooding is an architectural requirement; fix gaps upstream; don't compromise APIs to avoid breaking changes; drop net8/net9; update all deps/SDK/workflows to current stable; Compono-first tests; U2 default alias-only; include U7 S3 artifacts. Preview strategy: first code PR (#109) labeled breaking-change so all previews are 3.0.0-preview.N; fold Dependabot #101 into #109; stable publish only on owner authorization. Downstream consumers: ncipollina/jedi-duel #292 (tracking bead jedi-duel-aub.16), sharedale/sharedale #266.","acceptance_criteria":"All child issues closed with evidence; net10/net11 green; golden diffs only intentional; migration guide; downstream validation; owner publishes v3.0.0.","status":"open","priority":2,"issue_type":"epic","owner":"ncipollina@gmail.com","created_at":"2026-11-24T01:27:17Z","created_by":"Nick Cipollina","updated_at":"2026-11-24T01:27:17Z","external_ref":"gh-108","labels":["release:v3.0.0"],"dependency_count":0,"dependent_count":0,"comment_count":0} {"_type":"issue","id":"cdkc-18e.18.3","title":"#104 O: Document companion log groups, ownership, regional limits, and AlreadyExists remedies","description":"Objective: consumer documentation and operational guidance for LayeredCraft/cdk-constructs#104, written against design\nrevision 5 (cdkc-18e.18.1). May run in parallel with cdkc-18e.18.2 once revision 5 is approved; reconcile with the final\ncode before the PR. (Design doc itself: cdkc-18e.18.1. XML docs: cdkc-18e.18.2.)\n\nFiles: docs/constructs/web-function.md (\"Execution Role and Logging\" ~L132-139, props table ~L95, reserved IDs ~L151,\ntesting helpers ~L369, limitations ~L387-388); docs/testing/index.md (Web Function assertions, if listed);\nCHANGELOG.md [Unreleased]; CLAUDE.md (WebFunctionConstructAssertions list + WebFunctionLogs notes).\n\nMust cover:\n1. Why two groups exist (in-Region staging -\u003e home-Region centralization) and why events look duplicated (same\n timestamps/messages; centralized stream name adds -{account}-{region}); storage billed for both.\n2. Retention: centralized default TWO_WEEKS, companion default THREE_DAYS, why the companion is short; how to set\n both (Create(retention, removalPolicy, companionRetention)); companion inherits the removal policy.\n3. Which group to query: centralized for normal querying/alarms; `.local` in the serving Region for lowest-latency Live Tail.\n4. Ownership table for Create / Use(logGroup) / Use(logGroup, companion) / ServiceDefault: who creates, owns,\n deletes each group; ServiceDefault = both service-created, unlimited retention, outlive the stack.\n5. Execution-role permissions: the verified resource types (CreateLogGroup -\u003e log-group ARN; CreateLogStream/\n PutLogEvents -\u003e log-stream ARN), the per-role matrix, and the exact caller-provided permissions from design rev 5\n §8.3 (stream write on {c}:log-stream:* in the home Region and {c}.local:log-stream:* in {R}; CreateLogGroup on\n {c}.local only where Lambda creates it, and on {c} for ServiceDefault). Without .local write, logs from that Region\n are not delivered. Immutable roles are caller-managed.\n6. Ordering: managed groups precede the revision; supplied same-stack groups too; imported/cross-stack groups must\n exist before deployment.\n7. Regional limits: PerRegion/MultiRegion companions in other Regions are service-created with no expiry and not\n managed; set retention there separately; W2 id and how to acknowledge (Annotations acknowledgeWarning /\n `cdk synth --strict` impact). W1 id for Use without companion.\n8. AlreadyExists when adopting a managed companion where Lambda already created `{name}.local` (e.g. preview.27 stacks\n that served traffic, ServiceDefault -\u003e Create, redeploy after stack deletion): remedies = delete the\n service-created group(s) before deploying, or move to a new centralized group name; no adoption support.\n9. Teardown: DESTROY removes both managed groups after the revision; RETAIN keeps both; remote-Region companions\n always remain.\n10. CHANGELOG: Added (companion group, companionRetention, Use companion, LocalLogGroup, assertions, warnings);\n Fixed (missing .local write grant for Use custom groups; missing ordering for same-stack supplied groups);\n Notes (two groups per Create, AlreadyExists, binary break vs 2.6.0-preview.27 requiring recompilation). Reference #104;\n claim no released version.\n","acceptance_criteria":"- Topics 1–10 covered, with code examples for Create(custom retentions) and Use(logGroup, companion).\n- Ownership table and permissions matrix present in docs/constructs/web-function.md.\n- W1/W2 ids documented verbatim.\n- CHANGELOG [Unreleased] entry references #104 and claims no released version.\n- Docs match the final implemented API names/defaults (cross-checked with cdkc-18e.18.2 before the PR).\n- `uv run mkdocs build --clean` passes.","notes":"Documentation complete per design revision 5. Updated docs/constructs/web-function.md (two-group behavior, duplicate events/storage, query guidance, Create/Use/ServiceDefault, ownership+retention table, ordering/teardown, execution-role and caller-provided permissions incl. log-group vs log-stream ARNs and minimizePolicies, Multi-Region/W2, verbatim W1/W2 IDs and acknowledgement, AlreadyExists remedies, public API, testing helpers). Updated docs/testing/index.md (ShouldHaveWebFunctionLogGroup, ShouldHaveCompanionLogGroup, ShouldHaveRevisionDependingOnLogGroups), CLAUDE.md, and CHANGELOG [Unreleased] Added/Fixed/Notes for #104 with no released version claimed. Validation: uv run mkdocs build --strict --clean passed with no errors/warnings (built in 1.20s); AWS logging/permissions docs and GitHub #104 links return 200; internal anchors verified in built HTML; examples cross-checked against WebFunctionLogs.cs/WebFunctionConstruct.cs; W1/W2 IDs exact; design revision 5 unchanged; no src/test/GoldenTemplates changes; git diff --check clean.","spec_id":"docs/designs/lambda-web-functions-integration.md","status":"closed","priority":2,"issue_type":"task","owner":"ncipollina@gmail.com","created_at":"2026-10-26T15:32:53Z","created_by":"Nick Cipollina","updated_at":"2026-10-26T22:57:33Z","started_at":"2026-10-26T22:52:52Z","closed_at":"2026-10-26T22:57:33Z","close_reason":"Documentation for #104 completed against design revision 5: two-group logging behavior, all three modes, ownership/retention and execution-role permission matrices, Multi-Region limits, verbatim W1/W2 warnings with acknowledgement, AlreadyExists remedies, public API/testing helpers, and CHANGELOG [Unreleased] entries. uv run mkdocs build --strict --clean passes; links, anchors, API examples, and warning IDs verified; no src/test/golden changes.","external_ref":"gh-104","labels":["docs","gh-104","lambda-web-functions","logging"],"dependencies":[{"issue_id":"cdkc-18e.18.3","depends_on_id":"cdkc-18e.18","type":"parent-child","created_at":"2026-10-26T15:32:53Z","created_by":"Nick Cipollina","metadata":"{}"},{"issue_id":"cdkc-18e.18.3","depends_on_id":"cdkc-18e.18.1","type":"blocks","created_at":"2026-10-26T15:32:53Z","created_by":"Nick Cipollina","metadata":"{}"}],"dependency_count":1,"dependent_count":1,"comment_count":0} {"_type":"issue","id":"cdkc-18e.16","title":"T2 follow-up: Harden owned code-bucket inspection (tokens, unrecognized values, DSSE classification)","description":"Purpose: align WebFunctionCodeFromBucket.ValidateOwnedBucketConfiguration (src/LayeredCraft.Cdk.Constructs/Models/WebFunctionCode.cs) with design §14 and the revision-4 clarification under the §14 table. Source: independent review findings P4 and DSSE.\n\nDefects:\n(1) Tokens are rejected instead of skipped: a VersioningConfiguration.Status token resolves to {Ref:...}, its ToString() is compared to 'Enabled', and the bucket is rejected.\n(2) A Stack.Resolve result whose structure is not recognized should be treated as unknown and skipped, not rejected.\n(3) UsesAwsManagedKey rejects every aws:kms:dsse bucket, including DSSE with a customer-managed key. Per §8.7/§14, reject only DSSE_MANAGED (no key) and KMS_MANAGED/aws/s3, and make each message name the actual problem.\n(4) Versioning enabled only through an escape-hatch property override is a documented limitation, not a fix target. T6a documents the workaround (Bucket.FromBucketName + ExternallyManaged).\n\nKeep the current rule that owned buckets are inspected even under ExternallyManaged; the design does not change that.\n\nTests: token Status skipped; DSSE with a customer key accepted; DSSE_MANAGED rejected with an accurate message; KMS_MANAGED still rejected; customer-key SSE-KMS accepted; unversioned still rejected.\n\nExclusions: IAM/grant code (T3c), docs (T6a). No golden changes expected; verify. No commits or pushes unless authorized.","acceptance_criteria":"• Unresolved bucket configuration values are handled conservatively: a token or unrecognized versioning Status, encryption algorithm, encryption structure, or KMS key id is SKIPPED and never rejected (each case has a test). Unresolved values are never treated as proof of a violation.\n• Literal violations are still rejected: unversioned, KMS_MANAGED/aws/s3, DSSE_MANAGED (no key).\n• DSSE with a customer-managed key is accepted. Messages name the actual problem.\n• Escape-hatch-only versioning remains a documented limitation (T6a); it is not handled in code.\n• New tests pass; all goldens unchanged.\n• Release build has 0 warnings and the full suite passes on net8.0–net11.0; evidence is recorded in notes.","notes":"Maintainer decision (2026-10-23): keep escape-hatch S3 versioning as a documented limitation. Handle unresolved values conservatively: never reject tokenized values.\nIMPLEMENTATION (2026-10-23): Rewrote WebFunctionCodeFromBucket.ValidateOwnedBucketConfiguration in src/LayeredCraft.Cdk.Constructs/Models/WebFunctionCode.cs into ValidateVersioning + ValidateEncryption + ValidateKmsKey, classifying every value as literal-valid, literal-invalid, or unresolved/unrecognized.\n\nStorage/versioning/encryption handling:\n- Versioning: missing VersioningConfiguration or literal Status \"Suspended\" -\u003e reject (VersioningMessage). Literal Status \"Enabled\" -\u003e accept. A token Status, a missing status key, a non-dictionary resolved structure, or any other literal status -\u003e skipped (never rejected).\n- Encryption: missing BucketEncryption -\u003e no violation. Unrecognized structure (not a map, no rules, no ServerSideEncryptionByDefault) -\u003e skipped. Algorithm literal \"aws:kms\": key literal aws/s3 or empty/absent -\u003e reject (KmsManagedMessage names aws/s3); literal customer key -\u003e accept; token/absent-as-token key -\u003e skipped (never treated as AWS-managed). Algorithm literal \"aws:kms:dsse\": no key / aws/s3 -\u003e reject (DsseManagedMessage names customer-managed key); literal customer key -\u003e accept; token key -\u003e skipped. AES256 and any other literal algorithm -\u003e accepted.\n- LiteralString helper returns null for a non-string value or a string containing `${Token[`, so resolved tokens are never misread as literals.\n\nSecurity-policy behavior: ExternallyManaged still inspects owned buckets (versioning/encryption) exactly as before - design §14 row unchanged. The Automatic-only cross-stack account/Region guard and AddToResourcePolicy remain bypassed under ExternallyManaged (no bucket-policy statement is generated). No other semantics changed.\n\nRegression tests added to test/LayeredCraft.Cdk.Constructs.Tests/WebFunctionConstructTests.cs (13 new): enabled+S3-managed accepted (asserts synthesized S3::BucketPolicy); disabled (Versioned=false) rejected with versioning message; suspended rejected; tokenized versioning Status skipped (asserts synthesized policy); unrecognized literal versioning Status skipped; AWS-managed KMS (aws/s3) rejected naming aws/s3; customer-managed KMS accepted; tokenized KMS key skipped; DSSE with customer-managed key accepted; DSSE_MANAGED rejected naming customer-managed; DSSE + aws/s3 rejected; unrecognized encryption structure skipped; ExternallyManaged cross-stack owned bucket with unresolved function env does not throw (Automatic-only guard not applied). Existing fixtures retained (owned-bucket policy statements + revision DependsOn on bucket policy, imported-bucket Automatic error, ExternallyManaged no-policy, unversioned, KMS_MANAGED, cross-stack Automatic error). These exercise the real L1 property structs (CfnBucket.VersioningConfigurationProperty / BucketEncryptionProperty) so validation runs against synthesized configuration.\n\nEvidence: dotnet build -c Release -\u003e Build succeeded, 0 Warning(s), 0 Error(s). Full suite per TFM (dotnet run --project test/LayeredCraft.Cdk.Constructs.Tests/ -c Release --no-build): net8.0/net9.0/net10.0/net11.0 each Total 450, Errors 0, Failed 0, Skipped 0 (was 437 before; +13). All 24 golden templates byte-identical (git reports no GoldenTemplates changes); no golden updates required. dotnet format --verify-no-changes reports no issues in the two changed files. Only two files modified. No commit or push performed (per task restrictions).\n\nUnresolved behavior (documented, not code): versioning enabled solely via an escape-hatch property override is not detected (limitation, T6a workaround); imported buckets remain uninspected.","spec_id":"docs/designs/lambda-web-functions-integration.md","status":"closed","priority":2,"issue_type":"task","assignee":"Nick Cipollina","owner":"ncipollina@gmail.com","created_at":"2026-10-23T12:49:20Z","created_by":"Nick Cipollina","updated_at":"2026-10-23T14:43:43Z","started_at":"2026-10-23T14:34:44Z","closed_at":"2026-10-23T14:43:43Z","close_reason":"Owned-bucket inspection hardened per design §14 rev4. Unresolved values (token/unrecognized versioning Status, encryption algorithm, KMS key id, encryption structure) are skipped and never rejected; literal violations still rejected (unversioned/Suspended, KMS_MANAGED aws/s3, DSSE_MANAGED); DSSE with a customer-managed key accepted; messages name the actual problem. ExternallyManaged still inspects owned buckets but emits no policy and keeps the Automatic-only cross-stack guard. 13 new regression tests; Release build 0 warnings; full suite 450/450 on net8.0-net11.0; all 24 goldens unchanged. Not committed (per task).","external_ref":"gh-98","labels":["core","lambda-web-functions","t2"],"dependencies":[{"issue_id":"cdkc-18e.16","depends_on_id":"cdkc-18e","type":"parent-child","created_at":"2026-10-23T12:49:20Z","created_by":"Nick Cipollina","metadata":"{}"},{"issue_id":"cdkc-18e.16","depends_on_id":"cdkc-18e.3","type":"blocks","created_at":"2026-10-23T12:49:20Z","created_by":"Nick Cipollina","metadata":"{}"}],"dependency_count":1,"dependent_count":1,"comment_count":0} {"_type":"issue","id":"cdkc-18e.12","title":"T7b: Create sandbox CDK app and deploy/smoke/destroy scripts (no deployment)","description":"Purpose: sandbox CDK app and smoke-test tooling that exercises the implemented constructs exactly as a consumer would. No deployment in this bead. Design §19.1 item 3 (all sub-items), §9, §12.\n\nDeliverables under samples/web-functions/sandbox/ (not in the library slnx/CI):\n- A CDK app (C#) referencing the library project, with explicit Env (account/region from context or env vars; never hard-coded production values):\n * ArtifactsStack: owned versioned SSE-S3 Bucket used with WebFunctionCodeBucketPolicy.Automatic (bucket stack deployed and artifacts uploaded BEFORE the app stack, because the\n object must exist before the revision is created and Automatic adds the statement to the bucket's own stack).\n * A pre-provisioned \"external\" bucket (created by the script or a separate stack with its own lambda.amazonaws.com read policy) imported via Bucket.FromBucketName and used with ExternallyManaged.\n * AppStack: Next.js Web Function (IamAuth) behind a Distribution via WebFunctionOrigin.WithOriginAccessControl (default uncached + ALL_VIEWER_EXCEPT_HOST_HEADER, /_next/static/* cached);\n ASP.NET Core Web Function (IamAuth) with a second endpoint (for the endpoint-specific denial test) and GrantInvoke to a dedicated \"caller\" IAM role assumable by the operator;\n Blazor Web Function (IamAuth) behind OAC (fingerprinted/static assets cached); context flags to (a) switch artifacts to the v2 build (revision update), (b) add/remove a second\n distribution on the Next.js endpoint (resource-policy lifecycle), (c) optionally add an ExternallyManaged cross-account grant for a second sandbox account.\n * Outputs needed by the smoke script (endpoint URLs/ARNs, distribution domains/ids, caller role ARN). Use the library's naming; prefix all names with a sandbox prefix.\n- smoke.sh (bash, AWS CLI v2 + curl with --aws-sigv4 \"aws:amz:\u003cregion\u003e:lambda\" and header x-amz-content-sha256: UNSIGNED-PAYLOAD) implementing every §19.1 3.x check with expected status codes,\n `aws lambda-web get-resource-policy` inspection, revision/endpoint state checks, and a machine-readable summary; deploy.sh (ordered: artifacts stack → upload zips → app stack) and destroy.sh\n (destroys stacks, empties/deletes buckets incl. all object versions, deletes log groups).\n- README.md: prerequisites, required IAM permissions, non-production account requirement, cost notes, step-by-step run, cleanup, and how to record evidence.\n\nValidation in this bead: `cdk synth` of the sandbox app succeeds locally without deploying (use dummy account/region context); scripts pass shellcheck if available. No AWS deployment.\nExclusions: running against AWS (next bead); changes to library production code (record blockers instead).\n","acceptance_criteria":"- Sandbox CDK app synthesizes using only the public library API and covers every §19.1 item 3 scenario via stacks/context flags.\n- deploy/smoke/destroy scripts and README exist; smoke script checks every §19.1 3.1–3.8 item with explicit expected results; cleanup removes all created resources.\n- No deployment performed; library validation gates still pass.","notes":"## T7b implementation + correction record (no AWS deployment performed)\n\n### Sandbox CDK app (samples/web-functions/sandbox/, 20 files, untracked)\nC# CDK app (net10.0) referencing the real LayeredCraft.Cdk.Constructs project and exercising only the public Web Function API (WebFunctionConstruct, AddEndpoint, WebFunctionOrigin OAC, GrantInvoke, GrantCloudFrontInvoke). Stacks: lccdk-wf-sandbox-{id}-artifacts (versioned SSE-S3 bucket, Automatic), -external (versioned bucket + scoped read policy + 2 imported-caller roles), -app (Next.js/ASP.NET Core/Blazor Web Functions, 4 endpoints, 3 resource policies, 2 CloudFront distributions + OACs, caller/denied/imported roles, 28 outputs). Scripts: common.sh, validate-env.sh, synth.sh, upload-artifacts.sh, deploy.sh, update-to-v2.sh, destroy.sh, smoke.sh, run-workflow.sh + README.md.\n\n### Corrections applied (independent review)\n- B1 repeat-deploy: deploy.sh always synthesizes the COMPLETE app (SANDBOX_COMPONENTS=all) so support-stack cross-stack exports survive; support stacks deployed first with guarded placeholder versions, then upload, then app stack with real versions.\n- B2 destroy: destroy.sh synthesizes with SANDBOX_ALLOW_PLACEHOLDER_VERSIONS=1 so teardown works without a manifest / after partial failure; destroys app-\u003eexternal-\u003eartifacts, verifies each stack is gone before removing the manifest.\n- H1 ownership: fixed namespace lccdk-wf-sandbox in stack names; stack tags lc-webfunction-sandbox-id / lc-webfunction-sandbox-owner on every stack; shell stack_ownership (absent|owned|foreign|error) + assert_stack_owned_or_absent (deploy) / require_stack_owned (destroy); fail-closed on foreign or ambiguous results; every aws call pinned to --region and ambient-region mismatch aborts; mutations require SANDBOX_ALLOW_AWS=1 AND SANDBOX_ACKNOWLEDGE_NON_PRODUCTION=1.\n- M1: stack_exists replaced by stack_ownership (distinguishes not-found from AccessDenied/throttling/expired creds).\n- M2: empty_bucket deletes only object versions + delete markers (never delete-bucket); --expected-bucket-owner on head/list/delete; CloudFormation deletes the buckets; only stack-owned buckets are emptied.\n- M3: artifacts prefix consistent (SandboxConfiguration default key now uses the configured SANDBOX_ARTIFACTS_PREFIX; manifest/upload/CDK agree).\n- M4: CDK CLI pinned to 2.1145.0 (common.sh CDK_CLI_VERSION); SANDBOX_CDK override documented.\n- M5: external bucket policy scoped per function (arn:aws:lambda:{region}:{account}:web-function/{wfsbx-aspnetcore|wfsbx-blazor}/revision/*), no broad web-function/*/revision/*.\n- M6: app stack declares explicit CDK dependencies on artifacts + external (AddStackDependency).\n- SM1-SM7: smoke.sh rewritten - errexit disabled during tests + always writes build/smoke-summary.json + non-zero exit on fail/blocked; live resource-policy validation (BLOCKED, never PASS, when lambda-web API unavailable) checking Principal/Action/Effect/Resource/aws:SourceArn; revision/endpoint state via lambda-web get-web-function; Next.js build-id parser strips the 'Build id: ' label; Blazor sample now exposes id=\"build-id\"; real warm-request and Blazor assertions; denial classification (signature vs access-denied) requiring the matching positive to pass; imported immutable/mutable roles verified to have NO caller-side identity policy; cross-account distinguishes not-configured/missing-setup/negative/positive; SigV4 creds passed via a 600-perm curl -K config (never argv); bounded retry with validated numeric input.\n- Phase 7 misc: missing-flag-value guards, explicit SANDBOX_SECOND_DISTRIBUTION=0 reset, manifest target (sandboxId/account/region/prefix) validated before reuse, README documents CDK bootstrap + AWS CLI + missing lambda-web subcommands + prefix + pinned CLI + non-prod ack.\n\n### Offline validation (no AWS mutations)\n- Offline lifecycle harness with stubbed aws/cdk: 61/61 checks across 16 scenarios (fresh prep, support provisioning, upload+manifest, app deploy, repeat deploy, v1-\u003ev2, second-distribution enable/disable, normal/partial/repeated destroy, account mismatch, foreign-stack refusal, credential/API failure, S3 cleanup failure, manifest missing/foreign, nondefault prefix). Proves destroy never calls s3api delete-bucket.\n- Real cdk synth (npx aws-cdk@2.1145.0): verified stack ownership tags on all three stacks, per-function scoped external bucket policy, app-\u003eartifacts/external dependencies, cloudfront SourceArn resource policies, ASP.NET Core 2 imported-role statements, 28 app outputs. Expected F3006 warnings for the new resource types.\n- bash -n clean on all scripts. shellcheck not installed locally.\n- Library tests: 2140 passed / 0 failed (net8/9/10/11); no golden-template regressions.\n- Generated outputs (cdk.out/bin/obj/build) remain gitignored; git add -n lists exactly the 20 intended files.\n- Read-only identity check used a disposable test account (id withheld); NO deploy/destroy/upload performed.\nSecond independent review (Claude) returned CHANGES REQUIRED. Deploy/update/destroy lifecycle, placeholder mechanism, stack ownership, cross-stack deps, and synthesized IAM policies are independently validated and must NOT be redesigned. Correcting: S1 smoke.sh $4 under set -u; S2 CURL_AUTH omitted on CallerRole/imported-role positives; S3 CloudFront ARN empty region; S4 fail-closed live resource-policy verification (parser crash/omission must FAIL/BLOCKED); S5 imported-role identity-policy checks (list-role-policies failure != no policy; inline+attached; IAM sim); S6 Next.js build-ID extraction (HTML comments); S7 per-function revision/update verification; L1 remove unsafe log-group deletion; L2 prevalidate manifest on --skip-upload before any mutation; L3 first-run workflow without manifest; L4 preserve shell command failures; L5 bound --attempts + cross-account negative authorization. No real AWS mutations; do not start T7c.\n## T7b second-round corrections (independent review) — complete\n\n### S1-S7 (smoke execution correctness)\n- S1: smoke.sh settle() and fetch_until() optional positional args now use ${4:-}; regression scenario 1 proves the first passing check no longer aborts the suite.\n- S2: every IAM-signed positive invocation passes ${CURL_AUTH[@]} (curl -K config file, 0600); credentials are never on the curl argv. Scenario 2 asserts the signed requests reached the endpoint.\n- S3: CloudFront ARNs now use the empty region component arn:aws:cloudfront::\u003caccount\u003e:distribution/\u003cid\u003e; scenario 3 validates the policy checks against that ARN.\n- S4 (fail-closed): policy_report catches parse/schema errors and emits FAIL; unreadable/missing live policies emit FAIL/BLOCKED; a completeness check requires all 3 policy-check records (fewer =\u003e FAIL). Validates Effect=Allow, principal, action lambda:InvokeWebFunctionEndpoint, endpoint Resource ARN, aws:SourceArn; detects duplicate statements and unexpected distribution grants. Scenarios 4-8 cover malformed JSON, parser exception, missing policy, duplicate, extra, and second-distribution-removed.\n- S5: role_invoke_state inspects inline AND attached policies; any lookup failure returns error =\u003e BLOCKED (never PASS); scenario 9 (IAM AccessDenied) asserts BLOCKED.\n- S6: Next.js and Blazor samples render a stable data-build-id attribute; smoke extracts it (immune to SSR HTML comments); scenario 10 rejects a wrong build id.\n- S7: per-function revision tracking (each function queried separately; BLOCKED when the API is unavailable); --revision-baseline compares per-function revision identities before/after an update; run-workflow.sh derives --expect-build-id from the local artifact zip build-id.txt; scenarios 11-12 cover distinct per-function revisions and the v1-\u003ev2 transition (advanced vs unchanged).\n\n### L1-L5\n- L1: destroy.sh no longer deletes log groups by predictable name; CloudFormation deletes the CFN-owned log groups with their stacks. Scenario 13 asserts no log-group deletion API call and no delete-bucket.\n- L2: deploy.sh validates the artifact manifest (existence, sandbox id, account, region, prefix, required keys+versions) BEFORE any support-stack mutation when --skip-upload; a mismatched manifest performs zero AWS mutations. Scenario 14.\n- L3: run-workflow.sh no longer synthesizes before deploy (deploy.sh synthesizes), so a fresh checkout works without an existing manifest; placeholder-version protection is unchanged. Scenario 15.\n- L4: common.sh export_artifact_env assigns then exports (no export VAR=$(cmd) masking of failures under errexit).\n- L5: --attempts is bounded 1..60; cross-account adds the negative half (cross-account role on the alt endpoint =\u003e denied) and never PASSes when unconfigured.\n\n### Files changed (all uncommitted)\nsamples/web-functions/sandbox/: smoke.sh, common.sh, deploy.sh, destroy.sh, run-workflow.sh, synth.sh, upload-artifacts.sh, validate-env.sh, README.md, SandboxConfiguration.cs, SandboxNaming.cs, ArtifactsStack.cs, ExternalStack.cs, AppStack.cs, Program.cs; NEW tests/run-scenarios.sh, tests/run-smoke-scenarios.sh, tests/stubs/{aws,cdk,curl}. Also apps/nextjs/app/page.js, apps/blazor/Components/Pages/Home.razor, apps/blazor/Program.cs (S6 data-build-id). Plus .beads/issues.jsonl.\n\n### Regression test results (stubbed AWS/CDK/curl; no real AWS)\n- tests/run-scenarios.sh: 61 passed / 0 failed (lifecycle: stacks-only, upload, deploy, repeat, v1-\u003ev2, second-dist enable/disable, destroy, partial/repeated destroy, account mismatch, foreign stack, credential/API fail, S3 cleanup fail, manifest missing/mismatch, nondefault prefix).\n- tests/run-smoke-scenarios.sh: 38 passed / 0 failed (S1-S7/L1-L5 smoke correctness, fail-closed policy verification, per-function revisions, v1-\u003ev2, L1/L2/L3).\n\n### Other validation\n- bash -n OK for all 11 sandbox+test scripts; shellcheck not installed (noted).\n- Library tests: 2140 passed / 0 failed (net8.0/9.0/10.0/11.0); no golden-template changes.\n- Offline cdk synth OK (stacks lccdk-wf-sandbox-wfsbx-{artifacts,external,app}); H1 ownership tags on all stacks, M5 external bucket policy scoped per function revision ARN, M6 app-\u003esupport dependencies, resource policies 1/2/1 statements.\n\n### Remaining AWS-only uncertainties (deferred to T7c)\nReal deploy/smoke/destroy not performed. lambda-web CLI subcommands are unavailable in the local CLI, so live revision/policy checks report BLOCKED there. Cross-account requires a second sandbox account. IAM identity-policy propagation timing is only observable against real AWS.","spec_id":"docs/designs/lambda-web-functions-integration.md","status":"closed","priority":2,"issue_type":"task","owner":"ncipollina@gmail.com","created_at":"2026-10-23T01:14:57Z","created_by":"Nick Cipollina","updated_at":"2026-10-24T21:05:54Z","started_at":"2026-10-24T01:31:48Z","closed_at":"2026-10-24T21:05:54Z","close_reason":"T7b second-round corrections complete: S1-S7 and L1-L5 resolved; added stub-driven regression harness (tests/run-scenarios.sh 61/61, tests/run-smoke-scenarios.sh 38/38); bash -n clean; library tests 2140/0; offline synth verified (H1/M5/M6). No AWS mutations; T7c still pending.","external_ref":"gh-98","labels":["lambda-web-functions","samples","sandbox","t7"],"dependencies":[{"issue_id":"cdkc-18e.12","depends_on_id":"cdkc-18e","type":"parent-child","created_at":"2026-10-23T01:14:57Z","created_by":"Nick Cipollina","metadata":"{}"},{"issue_id":"cdkc-18e.12","depends_on_id":"cdkc-18e.11","type":"blocks","created_at":"2026-10-23T01:15:19Z","created_by":"Nick Cipollina","metadata":"{}"},{"issue_id":"cdkc-18e.12","depends_on_id":"cdkc-18e.6","type":"blocks","created_at":"2026-10-23T01:15:18Z","created_by":"Nick Cipollina","metadata":"{}"}],"dependency_count":2,"dependent_count":1,"comment_count":0} From ab2a58bf902b217f29ce02e74f31a194909063f6 Mon Sep 17 00:00:00 2001 From: Nick Cipollina Date: Mon, 23 Nov 2026 21:33:55 -0500 Subject: [PATCH 02/19] fix: pass the option structs CDK expects for function URLs and behaviors LambdaFunctionConstruct passed FunctionUrlProps to Alias.AddFunctionUrl and StaticSiteConstruct passed BehaviorOptions to Distribution.AddBehavior. The jsii runtime in Amazon.CDK.Lib 2.278.0 validates required struct members on conversion, so both now throw (missing 'function' / 'origin'). Use FunctionUrlOptions and AddBehaviorOptions, the declared parameter types. Synthesized templates are unchanged (golden templates byte-identical). Refs #109 (cdkc-2lh.2.1) Co-Authored-By: Claude Opus 5.5 --- src/LayeredCraft.Cdk.Constructs/LambdaFunctionConstruct.cs | 2 +- src/LayeredCraft.Cdk.Constructs/StaticSiteConstruct.cs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/LayeredCraft.Cdk.Constructs/LambdaFunctionConstruct.cs b/src/LayeredCraft.Cdk.Constructs/LambdaFunctionConstruct.cs index 74c2432..c4ba003 100644 --- a/src/LayeredCraft.Cdk.Constructs/LambdaFunctionConstruct.cs +++ b/src/LayeredCraft.Cdk.Constructs/LambdaFunctionConstruct.cs @@ -127,7 +127,7 @@ public LambdaFunctionConstruct(Construct scope, string id, ILambdaFunctionConstr if (props.GenerateUrl) { - var functionUrl = alias.AddFunctionUrl(new FunctionUrlProps + var functionUrl = alias.AddFunctionUrl(new FunctionUrlOptions { AuthType = FunctionUrlAuthType.NONE }); diff --git a/src/LayeredCraft.Cdk.Constructs/StaticSiteConstruct.cs b/src/LayeredCraft.Cdk.Constructs/StaticSiteConstruct.cs index f96f622..91cbda1 100644 --- a/src/LayeredCraft.Cdk.Constructs/StaticSiteConstruct.cs +++ b/src/LayeredCraft.Cdk.Constructs/StaticSiteConstruct.cs @@ -134,7 +134,7 @@ function handler(event) { ProtocolPolicy = OriginProtocolPolicy.HTTPS_ONLY }); - var apiBehaviorOptions = new BehaviorOptions + var apiBehaviorOptions = new AddBehaviorOptions { AllowedMethods = AllowedMethods.ALLOW_ALL, CachePolicy = CachePolicy.CACHING_DISABLED, From ab2483b118a168de8cbb9384ab73c862148a06d5 Mon Sep 17 00:00:00 2001 From: Nick Cipollina Date: Mon, 23 Nov 2026 21:33:55 -0500 Subject: [PATCH 03/19] build!: target net10.0/net11.0, pin SDK 11.0.100 and update dependencies - TargetFrameworks net8.0;net9.0;net10.0;net11.0 -> net10.0;net11.0 - global.json pins SDK 11.0.100 (latestFeature, no prerelease); MTP runner kept - Amazon.CDK.Lib 2.274.0 -> 2.278.0, Microsoft.SourceLink.GitHub 10.0.402 -> 11.0.100, xunit.v3.mtp-v2 3.2.2 -> 4.0.3, Microsoft.NET.Test.Sdk 18.11.0 -> 18.12.0, xunit.runner.visualstudio 3.1.5 -> 4.0.1; Compono/Compono.XunitV3 1.4.0 added centrally for the test migration - VersionPrefix 2.4.0 -> 3.0.0 (local builds; CI versions come from Release Drafter) - Amazon.CDK.Lib 2.278.0 adds same-named Web Function types to Amazon.CDK.AWS.Lambda; file-local using aliases keep this library's public types unambiguous. Public API unchanged. BREAKING CHANGE: .NET 8 and .NET 9 targets are removed; the Amazon.CDK.Lib floor rises to 2.278.0. Refs #109 (cdkc-2lh.2.1) Co-Authored-By: Claude Opus 5.5 --- Directory.Build.props | 2 +- Directory.Packages.props | 12 +++++++----- global.json | 5 +++++ .../LayeredCraft.Cdk.Constructs.csproj | 2 +- .../Models/WebFunctionConstructProps.cs | 5 +++++ .../WebFunctionConstruct.cs | 4 ++++ .../WebFunctionEndpointConstruct.cs | 6 ++++++ .../LayeredCraft.Cdk.Constructs.Tests.csproj | 2 +- .../WebFunctionConstructGoldenTemplateTests.cs | 6 ++++++ .../WebFunctionConstructTests.cs | 6 ++++++ .../WebFunctionSecurityTests.cs | 6 ++++++ 11 files changed, 48 insertions(+), 8 deletions(-) diff --git a/Directory.Build.props b/Directory.Build.props index ac5eda0..2c68843 100644 --- a/Directory.Build.props +++ b/Directory.Build.props @@ -1,6 +1,6 @@ - 2.4.0 + 3.0.0 MIT diff --git a/Directory.Packages.props b/Directory.Packages.props index bf4fe73..e2e3ae8 100644 --- a/Directory.Packages.props +++ b/Directory.Packages.props @@ -3,20 +3,22 @@ true - + - + + + - + - - + + \ No newline at end of file diff --git a/global.json b/global.json index 3140116..269797b 100644 --- a/global.json +++ b/global.json @@ -1,4 +1,9 @@ { + "sdk": { + "version": "11.0.100", + "rollForward": "latestFeature", + "allowPrerelease": false + }, "test": { "runner": "Microsoft.Testing.Platform" } diff --git a/src/LayeredCraft.Cdk.Constructs/LayeredCraft.Cdk.Constructs.csproj b/src/LayeredCraft.Cdk.Constructs/LayeredCraft.Cdk.Constructs.csproj index aaec97f..7919d20 100644 --- a/src/LayeredCraft.Cdk.Constructs/LayeredCraft.Cdk.Constructs.csproj +++ b/src/LayeredCraft.Cdk.Constructs/LayeredCraft.Cdk.Constructs.csproj @@ -3,7 +3,7 @@ enable enable - net8.0;net9.0;net10.0;net11.0 + net10.0;net11.0 default LayeredCraft.Cdk.Constructs LayeredCraft.Cdk.Constructs diff --git a/src/LayeredCraft.Cdk.Constructs/Models/WebFunctionConstructProps.cs b/src/LayeredCraft.Cdk.Constructs/Models/WebFunctionConstructProps.cs index c1b7732..b039cd1 100644 --- a/src/LayeredCraft.Cdk.Constructs/Models/WebFunctionConstructProps.cs +++ b/src/LayeredCraft.Cdk.Constructs/Models/WebFunctionConstructProps.cs @@ -2,6 +2,11 @@ using Amazon.CDK; using Amazon.CDK.AWS.IAM; using Amazon.CDK.AWS.Lambda; +// Amazon.CDK.Lib 2.278.0 adds same-named Web Function types to Amazon.CDK.AWS.Lambda; +// these aliases keep this library's own types unambiguous. +using IWebFunctionEndpointOptions = LayeredCraft.Cdk.Constructs.Models.IWebFunctionEndpointOptions; +using WebFunctionCode = LayeredCraft.Cdk.Constructs.Models.WebFunctionCode; +using WebFunctionRuntime = LayeredCraft.Cdk.Constructs.Models.WebFunctionRuntime; namespace LayeredCraft.Cdk.Constructs.Models; diff --git a/src/LayeredCraft.Cdk.Constructs/WebFunctionConstruct.cs b/src/LayeredCraft.Cdk.Constructs/WebFunctionConstruct.cs index 913c30e..40272d7 100644 --- a/src/LayeredCraft.Cdk.Constructs/WebFunctionConstruct.cs +++ b/src/LayeredCraft.Cdk.Constructs/WebFunctionConstruct.cs @@ -8,6 +8,10 @@ using Amazon.JSII.Runtime.Deputy; using Constructs; using LayeredCraft.Cdk.Constructs.Models; +// Amazon.CDK.Lib 2.278.0 adds same-named Web Function types to Amazon.CDK.AWS.Lambda; +// these aliases keep this library's own types unambiguous. +using IWebFunctionEndpointOptions = LayeredCraft.Cdk.Constructs.Models.IWebFunctionEndpointOptions; +using WebFunctionEndpointType = LayeredCraft.Cdk.Constructs.Models.WebFunctionEndpointType; namespace LayeredCraft.Cdk.Constructs; diff --git a/src/LayeredCraft.Cdk.Constructs/WebFunctionEndpointConstruct.cs b/src/LayeredCraft.Cdk.Constructs/WebFunctionEndpointConstruct.cs index 3eb9b1b..26826ec 100644 --- a/src/LayeredCraft.Cdk.Constructs/WebFunctionEndpointConstruct.cs +++ b/src/LayeredCraft.Cdk.Constructs/WebFunctionEndpointConstruct.cs @@ -6,6 +6,12 @@ using Amazon.CDK.AWS.Lambda; using Constructs; using LayeredCraft.Cdk.Constructs.Models; +// Amazon.CDK.Lib 2.278.0 adds same-named Web Function types to Amazon.CDK.AWS.Lambda; +// these aliases keep this library's own types unambiguous. +using IWebFunctionEndpointOptions = LayeredCraft.Cdk.Constructs.Models.IWebFunctionEndpointOptions; +using WebFunctionAuthType = LayeredCraft.Cdk.Constructs.Models.WebFunctionAuthType; +using WebFunctionEndpointAttributes = LayeredCraft.Cdk.Constructs.Models.WebFunctionEndpointAttributes; +using WebFunctionEndpointType = LayeredCraft.Cdk.Constructs.Models.WebFunctionEndpointType; namespace LayeredCraft.Cdk.Constructs; diff --git a/test/LayeredCraft.Cdk.Constructs.Tests/LayeredCraft.Cdk.Constructs.Tests.csproj b/test/LayeredCraft.Cdk.Constructs.Tests/LayeredCraft.Cdk.Constructs.Tests.csproj index 01897d6..f4ef2e2 100644 --- a/test/LayeredCraft.Cdk.Constructs.Tests/LayeredCraft.Cdk.Constructs.Tests.csproj +++ b/test/LayeredCraft.Cdk.Constructs.Tests/LayeredCraft.Cdk.Constructs.Tests.csproj @@ -5,7 +5,7 @@ enable Exe LayeredCraft.Cdk.Constructs.Tests - net8.0;net9.0;net10.0;net11.0 + net10.0;net11.0 default false