From 39590c3f0b114b68652fa65bff2135d27038fcf4 Mon Sep 17 00:00:00 2001
From: Tamas Gal <himself@tamasgal.com>
Date: Thu, 15 Dec 2022 16:52:00 +0100
Subject: [PATCH] Add memory observer for ztplot

---
 backend/scripts/ztplot.py | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/backend/scripts/ztplot.py b/backend/scripts/ztplot.py
index 5b30122..7628c7d 100755
--- a/backend/scripts/ztplot.py
+++ b/backend/scripts/ztplot.py
@@ -20,7 +20,7 @@ from __future__ import division
 
 import km3pipe.style
 from km3modules.plot import ztplot
-from km3modules.common import LocalDBService
+from km3modules.common import LocalDBService, MemoryObserver
 from km3modules.communication import ELOGService
 from km3io.tools import is_3dmuon, is_3dshower, is_mxshower
 import km3db
@@ -287,12 +287,13 @@ def main():
     ligier_port = int(args['-p'])
 
     pipe = kp.Pipeline()
+    pipe.attach(MemoryObserver, every=1000)
     pipe.attach(LocalDBService, thread_safety=False)
     pipe.attach(ELOGService)
     pipe.attach(kp.io.ch.CHPump,
                 host=ligier_ip,
                 port=ligier_port,
-                tags='IO_EVT, IO_SUM',
+                tags='IO_EVT',
                 timeout=60 * 60 * 24 * 7,
                 max_queue=2000)
     pipe.attach(kp.io.daq.DAQProcessor)
-- 
GitLab