[Service] Remove global.gc() 21/244321/5
authorDongHyun Song <dh81.song@samsung.com>
Thu, 17 Sep 2020 07:52:51 +0000 (16:52 +0900)
committerYoungsoo Choi <kenshin.choi@samsung.com>
Fri, 18 Sep 2020 02:26:07 +0000 (19:26 -0700)
LowMemoryNotification() with repeat timer will replace global.gc()
in JavascriptEnvironment side.

Related chromium-efl patch:
  https://review.tizen.org/gerrit/244329

Change-Id: I18864ed3de3b3c7ac367f4d247e3e1b81a9c9564
Signed-off-by: DongHyun Song <dh81.song@samsung.com>
wrt_app/common/service_manager.ts

index 9637542..ea6e1df 100644 (file)
@@ -21,14 +21,6 @@ export function startService(id: string, filename: string) {
     if (isMainThread) {
       let startService = __dirname + '/service_runner.js';
       workers[id] = new Worker(startService, { workerData: { id: id, filename: filename } });
-      workers[id].on('exit', () => {
-        try {
-          global.gc();
-          console.log(`global.gc() is called by ${id}`);
-        } catch (e) {
-          console.log(`${e.name}: ${e.message}`);
-        }
-      });
     }
   }
 }