diff options
| author | Dan Engelbrecht <[email protected]> | 2026-01-12 12:53:50 +0100 |
|---|---|---|
| committer | GitHub Enterprise <[email protected]> | 2026-01-12 12:53:50 +0100 |
| commit | a3eb59b18643919ec97439c7f45e4f72e5326faf (patch) | |
| tree | e33dc27b1fc09b1c34afd988974ea9365c933d58 | |
| parent | 5.7.16-pre0 (diff) | |
| download | zen-a3eb59b18643919ec97439c7f45e4f72e5326faf.tar.xz zen-a3eb59b18643919ec97439c7f45e4f72e5326faf.zip | |
if we fail to create the server mutex, gracefully report error without sending error to Sentry (#705)
| -rw-r--r-- | CHANGELOG.md | 1 | ||||
| -rw-r--r-- | src/zenserver/zenserver.cpp | 4 |
2 files changed, 4 insertions, 1 deletions
diff --git a/CHANGELOG.md b/CHANGELOG.md index dec3a3029..70ad053e9 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -8,6 +8,7 @@ - Improvement: Use decompress to composite to avoid allocating a new memory buffer for uncompressed chunks during oplog import - Improvement: Reduce memory buffer size and allocate it on demand when writing multiple chunks to block store - Improvement: Reduce lock contention when fetching/checking existence of chunks in block store +- Improvement: If we fail to create the server mutex, gracefully report the problem and exit without sending error to Sentry - Bugfix: Upstream propagation of Put operations would not retain the overwrite cache policy if it was used ## 5.7.15 diff --git a/src/zenserver/zenserver.cpp b/src/zenserver/zenserver.cpp index ab8dbb16b..95ea114bb 100644 --- a/src/zenserver/zenserver.cpp +++ b/src/zenserver/zenserver.cpp @@ -122,7 +122,9 @@ ZenServerBase::Initialize(const ZenServerConfig& ServerOptions, ZenServerState:: if (m_ServerMutex.Create(MutexName) == false) { - ThrowLastError(fmt::format("Failed to create mutex '{}'", MutexName).c_str()); + std::error_code Ec = MakeErrorCodeFromLastError(); + ZEN_WARN("Failed to create server mutex '{}'. Reason: '{}' ({})", MutexName, Ec.message(), Ec.value()); + return -1; } EnqueueSigIntTimer(); |