From 0febea97772934edc8ffc72f88b1fad9a213214a Mon Sep 17 00:00:00 2001 From: Thamim Razith Date: Tue, 4 Feb 2025 20:24:29 +0000 Subject: [PATCH] RDKTV-35412 : ResidentApp is not restarted automatically when it was crashed Reason for change: Thread Restart Logic due to recent Monitor plugin sync with ThunderNanoServices. Bring back the Thread Restart Logic. Test Procedure: Verified in Jenkins Build Risks: High Signed-off-by: Thamim Razith --- Monitor/CHANGELOG.md | 4 ++++ Monitor/Monitor.cpp | 4 ++-- Monitor/Monitor.h | 4 ++-- 3 files changed, 8 insertions(+), 4 deletions(-) diff --git a/Monitor/CHANGELOG.md b/Monitor/CHANGELOG.md index 9b6601c36b..5a8d137920 100644 --- a/Monitor/CHANGELOG.md +++ b/Monitor/CHANGELOG.md @@ -16,6 +16,10 @@ All notable changes to this RDK Service will be documented in this file. * For more details, refer to [versioning](https://github.com/rdkcentral/rdkservices#versioning) section under Main README. +## [2.0.1] - 2025-02-04 +### Changed +- Bring back the Delay changes in Thread Restart Logic + ## [2.0.0] - 2024-12-12 ### Changed - Synced Monitor Plugin with WebPlatformForEmbedded/ThunderNanoServicesRDK/tree/R4_4/Monitor diff --git a/Monitor/Monitor.cpp b/Monitor/Monitor.cpp index 56a1fbcc16..7dc57eb89f 100644 --- a/Monitor/Monitor.cpp +++ b/Monitor/Monitor.cpp @@ -21,7 +21,7 @@ #define API_VERSION_NUMBER_MAJOR 2 #define API_VERSION_NUMBER_MINOR 0 -#define API_VERSION_NUMBER_PATCH 0 +#define API_VERSION_NUMBER_PATCH 1 namespace WPEFramework { namespace Plugin { @@ -163,4 +163,4 @@ namespace Plugin { return (result); } } -} \ No newline at end of file +} diff --git a/Monitor/Monitor.h b/Monitor/Monitor.h index a43e7cd1bd..15869662d6 100644 --- a/Monitor/Monitor.h +++ b/Monitor/Monitor.h @@ -787,7 +787,7 @@ POP_WARNING() _service->Notify(message); _parent.event_action(callsign, "Activate", "Automatic"); TRACE(Trace::Error, (_T("Restarting %s again because we detected it misbehaved."), callsign.c_str())); - Core::IWorkerPool::Instance().Submit(PluginHost::IShell::Job::Create(service, PluginHost::IShell::ACTIVATED, PluginHost::IShell::AUTOMATIC)); + Core::IWorkerPool::Instance().Schedule(Core::Time::Now().Add(5000), PluginHost::IShell::Job::Create(service, PluginHost::IShell::ACTIVATED, PluginHost::IShell::AUTOMATIC)); } } } @@ -1049,4 +1049,4 @@ POP_WARNING() } } -#endif // __MONITOR_H \ No newline at end of file +#endif // __MONITOR_H