mirror of
https://github.com/zeek/zeek.git
synced 2025-10-02 14:48:21 +00:00
Implement the zeek_init handler.
Implements the change and a test.
This commit is contained in:
parent
f96bc81f85
commit
8cefb9be42
118 changed files with 229 additions and 165 deletions
|
@ -359,7 +359,7 @@ event Broker::peer_lost(endpoint: Broker::EndpointInfo, msg: string) &priority=1
|
|||
}
|
||||
}
|
||||
|
||||
event bro_init() &priority=5
|
||||
event zeek_init() &priority=5
|
||||
{
|
||||
# If a node is given, but it's an unknown name we need to fail.
|
||||
if ( node != "" && node !in nodes )
|
||||
|
|
|
@ -324,7 +324,7 @@ function mark_pool_node_dead(pool: Pool, name: string): bool
|
|||
return T;
|
||||
}
|
||||
|
||||
event bro_init()
|
||||
event zeek_init()
|
||||
{
|
||||
worker_pool = register_pool(worker_pool_spec);
|
||||
proxy_pool = register_pool(proxy_pool_spec);
|
||||
|
@ -344,8 +344,8 @@ function pool_sorter(a: Pool, b: Pool): int
|
|||
return strcmp(a$spec$topic, b$spec$topic);
|
||||
}
|
||||
|
||||
# Needs to execute before the bro_init in setup-connections
|
||||
event bro_init() &priority=-5
|
||||
# Needs to execute before the zeek_init in setup-connections
|
||||
event zeek_init() &priority=-5
|
||||
{
|
||||
if ( ! Cluster::is_enabled() )
|
||||
return;
|
||||
|
|
|
@ -42,7 +42,7 @@ function connect_peers_with_type(node_type: NodeType)
|
|||
}
|
||||
}
|
||||
|
||||
event bro_init() &priority=-10
|
||||
event zeek_init() &priority=-10
|
||||
{
|
||||
if ( getenv("BROCTL_CHECK_CONFIG") != "" )
|
||||
return;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue