Skip to content

feat(api): Mark an egress shard as the NAT64 standby - #38

Draft
privateip wants to merge 1 commit into
mainfrom
feat/egressshard-nat64-standby
Draft

privateip wants to merge 1 commit into
mainfrom
feat/egressshard-nat64-standby

Conversation

@privateip

Copy link
Copy Markdown
Collaborator

Summary

Compute nodes that spread egress across shards place NAT64 tenants on the standby edge shard, whose IPv4 replies all arrive at the primary and are dropped.

This adds an optional, mutable nat64Standby flag that tells them to use such a shard for NAT64 only when no unflagged shard can serve.

The flag requires an IPv4 address on the shard, and leaves NAT66 and ordered mode unchanged.

Test plan

  • A shard with the flag and no IPv4 address is rejected
  • The flag can be set and cleared on a shard whose addresses are fixed

Related to datum-cloud/infra#7033

🤖 Generated with Claude Code

An edge site runs two egress shards, and both announce the site's IPv4 unicast prefix upstream. The standby prepends its announcement, so every IPv4 reply, including replies to the standby's own shardAddressIPv4, arrives at the primary, which holds no session for it and drops it. NAT66 is unaffected because each shard announces its own IPv6 /128.

Compute nodes that spread egress across shards cannot see this from the shard spec, so they hash NAT64 tenants onto the standby and those tenants lose NAT64 entirely.

Add spec.nat64Standby. Compute nodes that spread egress keep NAT64 tenants off a standby shard while any shard without the flag can serve that NAT64 class, and use it only when none can. NAT66 placement is unaffected, and compute nodes in ordered mode ignore it. The field is optional and mutable, and a CEL rule requires shardAddressIPv4 alongside it.

Related to datum-cloud/infra#7033

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
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