Skip to content

Commit

Permalink
Set REP_watcher yaml option default to True
Browse files Browse the repository at this point in the history
  • Loading branch information
jeffbass committed Dec 20, 2020
1 parent 5405289 commit da5a718
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 4 deletions.
7 changes: 4 additions & 3 deletions docs/settings-yaml.rst
Original file line number Diff line number Diff line change
Expand Up @@ -187,7 +187,7 @@ There is 5 optional ``node`` settings:
heartbeat: an integer number of minutes; how often to send a heartbeat to hub
patience: maximum number of seconds to wait for a reply from
REP_watcher: True or False to start a REP_watcher thread
REP_watcher: True or False to start a REP_watcher thread (default is True)
stall_watcher: True or False to start a 'stall_watcher' sub-process
(default is False)
send_threading: True or False to send images & messages in a separate thread
Expand Down Expand Up @@ -232,7 +232,8 @@ imagehub restarts itself or the ZMQ link gets out of sync, a REP may never be
received and the send_frame function will stall forever. Setting
this option to ``True`` will start a thread that tracks the time
of each REQ and each REP. Then, if a REP is not received for ``patience``
seconds, the fix_comm_link() method will be called.
seconds, the fix_comm_link() method will be called. The default for
``REP_watcher`` is ``True``.

If the ``stall_watcher`` setting is set to ``True``, then a sub-process is
started that watches the main imagenode process for "slow downs" or "stalls".
Expand All @@ -249,7 +250,7 @@ the ``stall_watcher`` option is set to ``True``, the 2nd process will end the
service can restart **imagenode**. An example **imagenode.service** file that
provides for restarting (using systemd / systemctl) is in the main directory.
The ``patience`` option (above) sets the number of seconds between "stall"
checks.
checks. The default for ``stall_watcher`` is ``False``.

All 4 of the above options are about longer term reliability of **imagenodes** when
running for long periods of time in a production environment. My **imagenodes** are
Expand Down
2 changes: 1 addition & 1 deletion imagenode/tools/imaging.py
Original file line number Diff line number Diff line change
Expand Up @@ -1378,7 +1378,7 @@ def __init__(self):
if 'REP_watcher' in self.config['node']:
self.REP_watcher = self.config['node']['REP_watcher']
else:
self.REP_watcher = False
self.REP_watcher = True
if 'send_threading' in self.config['node']:
self.send_threading = self.config['node']['send_threading']
else:
Expand Down

0 comments on commit da5a718

Please sign in to comment.