ADR-046 Phase 2: Naming & identity
Part of #853
Implement the alias registry and name resolution from ADR-046 §0 .
Tasks
Define AliasBinding and AliasAppConfig proto/schema types
Define AliasType enum (ROLE, CALLSIGN, SLOT, CLAIMED)
Reserve and create system collections _aliases/{app_id}.{alias} and _alias_config/{app_id}
Implement NameResolver trait: resolve, resolve_selector, watch_alias, watch_selector
Implement NameBinder trait: bind, unbind, claim, release
Implement alias resolution in WriteOptions: target_aliases → target_nodes per the timing decision in the epic
Add aliases: repeated string and labels: map<string,string> fields to Beacon schema
Enforce APP_ID/alias format and length rules (validation in bind / claim)
Reserved APP_IDs (peat, system) rejected at bind time
Unit + integration tests: bind, claim, watch, resolve, conflict (LWW), TTL expiry
Friendly-mesh scope reductions (per epic #853 )
Only implement BindAuthority::OPEN and ConflictPolicy::LAST_WRITE_WINS for v1
Keep the other enum variants in the proto for future extension; return Unimplemented if requested
No authority check on bind() — any peer can bind
Blocking design decisions (see epic #853 )
Acceptance
bind / resolve / watch integration test passes across two peat-protocol instances
Beacon advertisement carries aliases and labels
Reserved APP_IDs are rejected
ADR-046 Phase 2: Naming & identity
Part of #853
Implement the alias registry and name resolution from ADR-046 §0.
Tasks
AliasBindingandAliasAppConfigproto/schema typesAliasTypeenum (ROLE,CALLSIGN,SLOT,CLAIMED)_aliases/{app_id}.{alias}and_alias_config/{app_id}NameResolvertrait:resolve,resolve_selector,watch_alias,watch_selectorNameBindertrait:bind,unbind,claim,releaseWriteOptions:target_aliases → target_nodesper the timing decision in the epicaliases: repeated stringandlabels: map<string,string>fields toBeaconschemabind/claim)peat,system) rejected at bind timeFriendly-mesh scope reductions (per epic #853)
BindAuthority::OPENandConflictPolicy::LAST_WRITE_WINSfor v1Unimplementedif requestedbind()— any peer can bindBlocking design decisions (see epic #853)
Acceptance
bind/resolve/watchintegration test passes across twopeat-protocolinstances