mirror of
https://github.com/zeek/zeek.git
synced 2025-10-13 20:18:20 +00:00
GH-837: emit Reporter errors for Broker errors
Instead of only writing them in broker.log, which may be easy to overlook.
This commit is contained in:
parent
7e03233d55
commit
c84a51ac09
1 changed files with 3 additions and 1 deletions
|
@ -71,10 +71,12 @@ event Broker::error(code: ErrorCode, msg: string)
|
|||
ev = subst_string(ev, "Broker::", "");
|
||||
ev = subst_string(ev, "_", "-");
|
||||
ev = to_lower(ev);
|
||||
|
||||
|
||||
Log::write(Broker::LOG, [$ts = network_time(),
|
||||
$ev = ev,
|
||||
$ty = ERROR,
|
||||
$message = msg]);
|
||||
|
||||
Reporter::error(fmt("Broker error (%s): %s", code, msg));
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue