atproto relay in zig zlay.waow.tech
relay zig atproto

fix cross-Io heap corruption: subscriber pg.Pool access from Evented fibers master

subscriber fibers (Evented) were calling DiskPersist methods that acquire pg.Pool connections via Threaded futex — NULL Thread.current() on Evented fibers caused heap corruption (~16min crash cycle). add MPSC host_ops queue (atomic spinlock, same pattern as BroadcastQueue): - subscriber pushes ops instead of calling dp.* directly - single background thread (std.Thread on pool_io) pops and executes - covers: cursor flush (~450/s), failure tracking, status updates - cursor loaded at spawn time (slurper passes last_seq through) Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>