Skip to content

Document that name_prefix must be unique per module call (per AZ) - #8

Merged
hostmaster merged 1 commit into
mainfrom
docs/multi-az-name-prefix-uniqueness
Sep 5, 2026
Merged

hostmaster merged 1 commit into
mainfrom
docs/multi-az-name-prefix-uniqueness

Conversation

@hostmaster

Copy link
Copy Markdown
Owner

Summary

  • REVIEW.md finding 5: the README's multi-AZ guidance implied a second module call only needed a different public_subnet_id/private_route_table_ids. But the Lambda function names, CloudWatch Log Group names, and CloudWatch alarm names are all derived directly from name_prefix -- unlike the ASG/IAM role/EventBridge rule, which get Terraform's own randomized name_prefix suffix -- so two calls sharing the same prefix collide.
  • This module deliberately has no multi-AZ logic of its own (stated non-goal), so an auto-derived uniqueness suffix was out of scope; documented the constraint in both README.md and the variable's own description instead.

Test plan

  • terraform fmt -recursive -diff (no diff)
  • terraform validate (module root and examples/basic)

The README's multi-AZ guidance implied that a second module call only
needed a different public_subnet_id/private_route_table_ids. But the
Lambda function names, CloudWatch Log Group names, and CloudWatch
alarm names are all derived directly from name_prefix -- unlike the
ASG/IAM role/EventBridge rule, which get Terraform's own randomized
name_prefix suffix -- so two calls sharing the same prefix collide.

This module deliberately has no multi-AZ logic of its own (non-goal),
so a naming-scheme change to auto-derive uniqueness was out of scope;
documenting the constraint in both README.md and the variable's own
description is the fix.
@hostmaster
hostmaster merged commit 6f5111a into main Sep 5, 2026
3 checks passed
@hostmaster
hostmaster deleted the docs/multi-az-name-prefix-uniqueness branch September 5, 2026 10:50
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.

1 participant