TableSync: don't raise &on_change, smaller fixes

This addresses PR feedback. The main component in this commit is to
disable &on_change notifications when &backend loads a table from sqlite
on startup.
This commit is contained in:
Johanna Amann 2020-07-17 14:21:27 -07:00
parent 930a5c8ebd
commit 36db9d8369
8 changed files with 43 additions and 20 deletions

View file

@ -1029,6 +1029,16 @@ public:
*/
void SetBrokerStore(const std::string& store) { broker_store = store; }
/**
* Disable change notification processing of &on_change until re-enabled.
*/
void DisableChangeNotifications() { in_change_func = true; }
/**
* Re-enables change notifcations after being disabled by DisableChangeNotifications.
*/
void EnableChangeNotifications() { in_change_func = false; }
protected:
void Init(zeek::TableTypePtr t);