diff options
author | arkady-e1ppa <arkady-e1ppa@yandex-team.com> | 2024-12-17 12:07:33 +0300 |
---|---|---|
committer | arkady-e1ppa <arkady-e1ppa@yandex-team.com> | 2024-12-17 12:24:58 +0300 |
commit | ef547e050181b3f6fc77ee0e0e1956ef316861e0 (patch) | |
tree | 0f0d335c547e1eac2b91b39f77b9c9873ae0fdc4 | |
parent | 48bd5f88777f4dc94fd41a7dd22808ed639b985d (diff) | |
download | ydb-ef547e050181b3f6fc77ee0e0e1956ef316861e0.tar.gz |
Move crash handler timeout to the beggining to protect it from hanging during symbolization (and other steps)
commit_hash:af94687a97c9cff320ad057c6d50f1ac8de0dd6a
-rw-r--r-- | yt/yt/core/misc/crash_handler.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/yt/yt/core/misc/crash_handler.cpp b/yt/yt/core/misc/crash_handler.cpp index 4f7eae4440..80e657531e 100644 --- a/yt/yt/core/misc/crash_handler.cpp +++ b/yt/yt/core/misc/crash_handler.cpp @@ -504,6 +504,10 @@ void CrashSignalHandler(int /*signal*/, siginfo_t* si, void* uc) { // All code here _MUST_ be async signal safe unless specified otherwise. + // Actually, it is not okay to hang. + ::signal(SIGALRM, NDetail::CrashTimeoutHandler); + ::alarm(60); + // When did the crash happen? NDetail::DumpTimeInfo(); @@ -532,10 +536,6 @@ void CrashSignalHandler(int /*signal*/, siginfo_t* si, void* uc) WriteToStderr("*** Waiting for logger to shut down\n"); - // Actually, it is not okay to hang. - ::signal(SIGALRM, NDetail::CrashTimeoutHandler); - ::alarm(5); - NLogging::TLogManager::Get()->Shutdown(); WriteToStderr("*** Terminating\n"); |