Mercurial > hg > orthanc
changeset 5882:1c562a107a80 find-refactoring
make the DB HK thread resilient to DB disconnection
author | Alain Mazy <am@orthanc.team> |
---|---|
date | Thu, 28 Nov 2024 11:59:51 +0100 |
parents | 1c549458ea5d |
children | 96f49b200c15 |
files | OrthancServer/Sources/ServerIndex.cpp |
diffstat | 1 files changed, 8 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- 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; }