Ignore:
Timestamp:
07/01/2026 12:45:51 AM (2 months ago)
Author:
Robin Genis <roboburr@…>
Branches:
main
Children:
e1c4f3e
Parents:
0f2d441
Message:

fix(federation): deliver Follow via the retry queue (byh)

followActor() sent the Follow with a plain deliver() (fire-and-forget), so a
first-attempt failure (peer down/timeout/transient 5xx) left the follow stuck
on 'pending' forever — the Accept can only come back once the Follow lands.
Route it through deliverWithRetry() like deliverCreate/unfollowActor already do:
immediate attempt, then backoff retries via the ap_delivery queue (the worker
re-signs from the slug key).

  • src/services/ActivityPubService.js — followActor Follow delivery -> deliverWithRetry
  • CHANGELOG.md / .nl / .de — Unreleased Fixed: follow-retry + this session's cover/right-click/boost fixes

Co-Authored-By: Claude <noreply@…>

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/services/ActivityPubService.js

    r0f2d441 r1b1cc89  
    16621662  fwStmts().ins.run(site.slug, actor.id, ai.handle, ai.name, ai.icon, ai.url, actor.inbox, followId, 'pending', autoBoost ? 1 : 0);
    16631663  const follow = { '@context': AP_CONTEXT, id: followId, type: 'Follow', actor: me, object: actor.id };
    1664   try { await deliver(actor.inbox, follow, `${me}#main-key`, keys.private_pem); }
    1665   catch (e) { console.warn('[AP] follow deliver failed:', e.message); }
     1664  // Deliver via the retry queue: a Follow that fails the first attempt (peer down,
     1665  // timeout, transient 5xx) is retried with backoff instead of staying stuck on
     1666  // 'pending' forever — the Accept can only come back once the Follow lands.
     1667  await deliverWithRetry(site.slug, actor.inbox, follow, `${me}#main-key`, keys.private_pem);
    16661668  console.log('[AP] follow', site.slug, '→', actor.id);
    16671669  // Follow + feature in one step → backfill their recent posts into the Cirkel right away.
Note: See TracChangeset for help on using the changeset viewer.