# HG changeset patch # User Alain Mazy # Date 1732791591 -3600 # Node ID 1c562a107a8017baea83b6a5c383e1092003fe76 # Parent 1c549458ea5dbf58ad25e259bea5c3a28a081eaf make the DB HK thread resilient to DB disconnection diff -r 1c549458ea5d -r 1c562a107a80 OrthancServer/Sources/ServerIndex.cpp --- a/OrthancServer/Sources/ServerIndex.cpp Wed Nov 27 16:02:42 2024 +0100 +++ b/OrthancServer/Sources/ServerIndex.cpp Thu Nov 28 11:59:51 2024 +0100 @@ -290,7 +290,14 @@ if (count >= countThreshold) { - that->PerformDbHousekeeping(); + try + { + that->PerformDbHousekeeping(); + } + catch (...) + { + LOG(ERROR) << "Error while performing DB Housekeeping"; + } count = 0; }