Skip to content

Commit

Permalink
Merge pull request #1930 from Expensify/main
Browse files Browse the repository at this point in the history
Update expensify_prod branch
  • Loading branch information
jasperhuangg authored Nov 1, 2024
2 parents 6064bd4 + 583a5cb commit cd57d92
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion sqlitecluster/SQLiteNode.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1652,8 +1652,9 @@ void SQLiteNode::_onMESSAGE(SQLitePeer* peer, const SData& message) {
// and waiting for the transaction that failed will be stuck in an infinite loop. To prevent that
// we're changing the state to SEARCHING and sending the cancelAfter property to drop all threads
// that depend on the transaction that failed to be threaded.
_changeState(SQLiteNodeState::SEARCHING, message.calcU64("NewCount") - 1);
_replicationThreadCount.fetch_sub(1);
SWARN("Caught system_error starting _replicate thread with " << _replicationThreadCount.load() << " threads. e.what()=" << e.what());
_changeState(SQLiteNodeState::SEARCHING, message.calcU64("NewCount") - 1);
STHROW("Error starting replicate thread so giving up and reconnecting.");
}
SDEBUG("Done spawning concurrent replicate thread: " << threadID);
Expand Down

0 comments on commit cd57d92

Please sign in to comment.