Skip to content

fix(tree): skip self in WebSocket attachment candidates (#120) - #121

Merged
TickTockBent merged 2 commits into
mainfrom
fix/120-ws-self-attachment
May 10, 2026
Merged

fix(tree): skip self in WebSocket attachment candidates (#120)#121
TickTockBent merged 2 commits into
mainfrom
fix/120-ws-self-attachment

Conversation

@TickTockBent

Copy link
Copy Markdown
Owner

Summary

Closes #120.

Root cause

The omega signed root list includes the node's own address. The WS attachment logic iterated all seeds without a self-skip, so the node connected to its own WS server. This made it both substrate and transient for itself. cluster.ts put() checks treeManager.parent — with a self-WS parent, PUTs went through WS to self instead of HTTP broadcast to peers. Go nodes never received the PUT, the 5s write timeout fired, and ACKs arrived too late. Result: 100% 202 on all TS-originated writes.

Test plan

  • New unit test: tryAlternatives skips self-matching entries (#120)
  • All 390 TS tests pass
  • All Go tests pass
  • Rebuild TS image, restart node-c, verify 201s on TS-originated writes in burn-in cluster

// ticktockbent

The omega signed root list (or REPRAM_PEERS) can include the local
node's own address. Without a self-skip, the node attaches to itself
via WebSocket — becoming both substrate and transient for itself —
and routes all PUTs through the self-WS connection instead of
broadcasting to peers, causing 100% quorum timeout (202).

Mirrors the self-skip already in bootstrapFromPeers (#87, PR #103)
for the HTTP gossip path. Covers both initial attachment (index.ts)
and the reattach loop's seed-list layer (tree.ts tryAlternatives).

// ticktockbent
@vercel

vercel Bot commented May 10, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
repram Ready Ready Preview, Comment May 10, 2026 11:00pm

Request Review

@TickTockBent
TickTockBent merged commit 58453aa into main May 10, 2026
4 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.

WebSocket attachment to self causes 100% quorum timeout on TS-originated writes

1 participant