Loading src/cluster.cpp +3 −3 Changes for src/cluster.cpp: 3 added lines, 3 removed lines. Original line number Diff line number Diff line Loading @@ -374,8 +374,6 @@ namespace authdb { } void Cluster::pushSession(const SessionData &sess) { if (!pclient_) return; auto data = SessionBlock::serialize(sess); uuid::uuid sid, uid, did; Loading @@ -386,10 +384,12 @@ namespace authdb { uint64_t sgid = sessionGroupId(uid, did); uint64_t sid_gid = sidGroupId(sid); // Store under both uid+did key and SID key // Always store locally so hasSessionBySid() can find it store_->store(sgid, 0, data.data(), data.size()); store_->store(sid_gid, 0, data.data(), data.size()); if (!pclient_) return; // Replicate raw data to all peer nodes under both keys try { std::unique_lock<std::timed_mutex> lock(client_mutex_, std::chrono::seconds(5)); if (!lock.owns_lock()) throw std::runtime_error("cluster client lock timeout"); Loading Loading
src/cluster.cpp +3 −3 Changes for src/cluster.cpp: 3 added lines, 3 removed lines. Original line number Diff line number Diff line Loading @@ -374,8 +374,6 @@ namespace authdb { } void Cluster::pushSession(const SessionData &sess) { if (!pclient_) return; auto data = SessionBlock::serialize(sess); uuid::uuid sid, uid, did; Loading @@ -386,10 +384,12 @@ namespace authdb { uint64_t sgid = sessionGroupId(uid, did); uint64_t sid_gid = sidGroupId(sid); // Store under both uid+did key and SID key // Always store locally so hasSessionBySid() can find it store_->store(sgid, 0, data.data(), data.size()); store_->store(sid_gid, 0, data.data(), data.size()); if (!pclient_) return; // Replicate raw data to all peer nodes under both keys try { std::unique_lock<std::timed_mutex> lock(client_mutex_, std::chrono::seconds(5)); if (!lock.owns_lock()) throw std::runtime_error("cluster client lock timeout"); Loading