Skip to content

infra(hub): latency alarm from the hub log; maintenance window after the backup run (D-196) - #155

Merged
blove merged 1 commit into
mainfrom
blove/alarm-latency-and-maintenance-window
Nov 9, 2026
Merged

blove merged 1 commit into
mainfrom
blove/alarm-latency-and-maintenance-window

Conversation

@blove

@blove blove commented Nov 9, 2026

Copy link
Copy Markdown
Contributor
  • latency-p99 was in ALARM in both accounts since 2026-11-02: the ALB p99 is the 25 s sync long-poll. A CloudWatch Logs metric filter on /b4hub/<env>/hub publishes elapsed_ms for every request complete line except /v1/changes and /v1/devices/self/link; the alarm is p99 > 2000 ms for ten minutes on that metric.
  • Every Sunday backup failed in both accounts ("too close to the weekly maintenance window"): the RDS maintenance window moves from sun:06:30 to sun:09:00 UTC.
  • Runbook 9 alarm table and D-072 notes updated (the us-west-2 policy exception was narrowed today).

Module tests: 53 pass; tflint, terraform fmt clean. Expected plan per account: 1 metric filter to add, the latency alarm replaced (namespace change), the RDS instance modified in place (window; apply_immediately = false, so it takes effect at the next window).

🤖 Generated with Claude Code

…ance window after the backup run (D-196)

The latency-p99 alarm on the ALB's TargetResponseTime was in ALARM from the
first day: the 25 s sync long-poll and the WebSocket upgrade dominate the
p99. A log metric filter now publishes elapsed_ms of every other request as
RequestLatencyMs and the alarm watches that. Every Sunday's AWS Backup job
failed because the 06:00 UTC run was too close to the sun:06:30 RDS
maintenance window; the window moves to sun:09:00. The us-west-2 region
policy exception is narrowed to listed actions (recorded in D-072's notes).

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
@blove
blove enabled auto-merge November 9, 2026 22:33
@github-actions

github-actions Bot commented Nov 9, 2026

Copy link
Copy Markdown

Terraform plan: test

Plan: 1 to add, 2 to change, 0 to destroy (a replacement counts as both an add and a destroy).

  • module.hub.aws_cloudwatch_log_metric_filter.request_latency: create
  • module.hub.aws_cloudwatch_metric_alarm.latency_p99: update
  • module.hub.aws_db_instance.hub: update

The full plan is in the workflow run log.

@github-actions

github-actions Bot commented Nov 9, 2026

Copy link
Copy Markdown

Terraform plan: prod

Plan: 3 to add, 3 to change, 0 to destroy (a replacement counts as both an add and a destroy).

  • module.hub.aws_cloudwatch_event_rule.backup_copy_failed: create
  • module.hub.aws_cloudwatch_event_target.backup_copy_failed: create
  • module.hub.aws_cloudwatch_log_metric_filter.request_latency: create
  • module.hub.aws_cloudwatch_metric_alarm.latency_p99: update
  • module.hub.aws_db_instance.hub: update
  • module.hub.aws_sns_topic_policy.alerts: update

The full plan is in the workflow run log.

@blove
blove merged commit f367fb8 into main Nov 9, 2026
10 checks passed
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