mirror of
https://github.com/zeek/zeek.git
synced 2025-10-17 05:58:20 +00:00
Add Broker::max_threads and Broker::max_sleep tuning options
The former replaces the pcap vs. live versions of the same tuning option. If a user does not change these, Bro makes some internal decisions that may help avoid performance problems on systems with high core counts: the number of CAF threads is capped at 8 and the maximum sleep duration for under-utilized threads is increased to 64ms (CAF's default is 10ms).
This commit is contained in:
parent
197ea03f8f
commit
e578c1c231
4 changed files with 46 additions and 24 deletions
|
@ -51,21 +51,15 @@ export {
|
|||
## all peers.
|
||||
const ssl_keyfile = "" &redef;
|
||||
|
||||
## Max number of threads to use for Broker/CAF functionality when
|
||||
## operating on a live interface. Using zero will cause this to
|
||||
## be automatically determined based on number of available CPUs.
|
||||
const max_live_threads = 0 &redef;
|
||||
## Max number of threads to use for Broker/CAF functionality.
|
||||
## Using zero will cause this to be automatically determined
|
||||
## based on number of available CPUs.
|
||||
const max_threads = 0 &redef;
|
||||
|
||||
## Max number of threads to use for Broker/CAF functionality when
|
||||
## operating on a pcap file. Using zero will cause this to be
|
||||
## automaticallu determined based on number of available CPUs.
|
||||
# TODO: on systems where number of CPUs starts exceeding ~10,
|
||||
# simply creating a caf::actor_system and not using it incurs
|
||||
# significant performance overhead. Can CAF be updated to
|
||||
# be more efficient in the case where the application isn't
|
||||
# actually making much use of most of those threads instead
|
||||
# of hardcoding this to the minimal 4 threads?
|
||||
const max_pcap_threads = 4 &redef;
|
||||
## Max number of microseconds for under-utilized Broker/CAF
|
||||
## threads to sleep. Using zero will cause this to be automatically
|
||||
## determined or just use CAF's default setting.
|
||||
const max_sleep = 0 &redef;
|
||||
|
||||
## Forward all received messages to subscribing peers.
|
||||
const forward_messages = F &redef;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue