mirror of
https://github.com/zeek/zeek.git
synced 2025-10-02 06:38:20 +00:00
BrokerStore<->Zeek tables: &backend works for in-memory stores.
Currently this requires using this with a normal cluster - or sending messages by yourself. It, in principle, should also work with SQLITE - but that is a bit nonsensical without being able to change the storage location.
This commit is contained in:
parent
318a72c303
commit
a220b02722
9 changed files with 118 additions and 33 deletions
|
@ -235,13 +235,15 @@ void Manager::InitializeBrokerStoreForwarding()
|
|||
id->GetVal()->AsTableVal()->SetBrokerStore(storename);
|
||||
AddForwardedStore(storename, {NewRef{}, id->GetVal()->AsTableVal()});
|
||||
|
||||
auto backend = bro_broker::to_backend_type(e);
|
||||
|
||||
// we only create masters here. For clones, we do all the work of setting up
|
||||
// the forwarding - but we do not try to initialize the clone. We can only initialize
|
||||
// the clone, once a node has a connection to a master. This is currently done in scriptland
|
||||
// - check FIXME.
|
||||
if ( zeek_table_manager )
|
||||
MakeMaster(storename, backend, broker::backend_options{});
|
||||
else
|
||||
{
|
||||
MakeClone(storename);
|
||||
auto backend = bro_broker::to_backend_type(e);
|
||||
MakeMaster(storename, backend, broker::backend_options{});
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue