+25
−4
+11
−11
Loading
forward_call and the forward functions called engine->define(tag) on every RPC. Each call re-registers the RPC in Mercury (HG_Core_register, 'Overwriting RPC callback'); in the multi-threaded FUSE client this races with responses processed by other threads and gives short reads or HG_FAULT (MN5 bug 4: IO500 ior-easy-read 'EOF prematurely' in 2 of 3 runs with the engine pool). Every tag is now defined once when an engine is added to the pool (PreloadContext::add_rpc_engine(engine, tags)); the remote_procedure objects are kept per engine and looked up with gkfs::rpc::get_rpc(engine, tag). Tags not defined at setup fall back to define(). The procedures are released before their engines (shutdown, fork re-init). PC: no Overwriting-RPC-callback warning left under a 24-process FUSE write/read-back test (old build: 2 with 1 engine, 22 with 4 engines); integration tests unchanged with 1 and 4 engines. Co-Authored-By:Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01VotrDxGfCTADQU5bfhXBjD