Skip to content

chore(ingestion): put the raw zone in us-west4, beside Cloud SQL - #843

Merged
jirhiker merged 1 commit into
stagingfrom
chore/raw-zone-in-us-west4
Aug 19, 2026
Merged

chore(ingestion): put the raw zone in us-west4, beside Cloud SQL#843
jirhiker merged 1 commit into
stagingfrom
chore/raw-zone-in-us-west4

Conversation

@jirhiker

Copy link
Copy Markdown
Member

The buckets landed in US-CENTRAL1, from a default I chose before the database
region was known. The dataservices instance is in us-west4, so every Mode B
replay would read across regions and pay egress to reach the loader.

This replaces the buckets

Bucket location is immutable. terraform apply will destroy and recreate
both.

That is safe right now and only right now — I verified both are empty before
making the change:

ocotillo-ingestion-production: 0 objects
ocotillo-ingestion-staging:    0 objects

Once a backfill has landed, changing regions means copying objects across and
re-pointing the pipeline, not editing a variable. The resource now carries that
warning so the next person does not learn it from a plan output.

Applying

cd automated_ingestion/iac
terraform apply -var project_id=waterdatainitiative-271000 -var cloud_sql_instance=dataservices

Read the plan before confirming. It should show two buckets replaced and
their IAM members recreated, and nothing else destroyed. force_destroy is
false, so if either bucket has acquired objects since I checked, Terraform will
refuse rather than delete data — which is the intended behaviour.

Passing cloud_sql_instance also creates the Cloud SQL grants and the IAM
database user, which database_connectivity needs next. That variable takes the
bare instance name, unlike CLOUD_SQL_INSTANCE_NAME, which needs the full
PROJECT:REGION:INSTANCE connection string.

🤖 Generated with Claude Code

The buckets were created in US-CENTRAL1 from a default chosen before the
database region was known. The dataservices instance is in us-west4, so every
Mode B replay would have read across regions and paid egress to reach the
loader.

Bucket location is immutable, so applying this replaces both buckets. Verified
empty first -- zero objects in each -- which makes now the only cheap moment to
do it. After a backfill has landed, moving regions means copying objects and
re-pointing the pipeline rather than editing a variable, which the comment on
the resource now says.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
@github-actions

github-actions Bot commented Aug 19, 2026

Copy link
Copy Markdown
Contributor

Coverage

79.27% total — gate is 75%.

@github-actions

github-actions Bot commented Aug 19, 2026

Copy link
Copy Markdown
Contributor

Your pull request is automatically being deployed to Dagster Cloud.

Location Status Link Updated
ocotillo-automated-ingestion View in Cloud Aug 19, 2026 at 03:47 AM (UTC)

@jirhiker
jirhiker merged commit 9e990ec into staging Aug 19, 2026
10 checks passed
@jirhiker
jirhiker deleted the chore/raw-zone-in-us-west4 branch August 19, 2026 03:46
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