mirror of
https://github.com/zeek/zeek.git
synced 2025-10-02 06:38:20 +00:00
Management framework: control output-to-console in Supervisor
It helps during testing to be able to control whether the Supervisor process also routs node output to the console, in addition to writing to output files. Since the Supervisor runs as the main process in Docker containers, its output becomes visible in "docker logs" that way, simplifying diagnostics.
This commit is contained in:
parent
5592beaf31
commit
0c20f16055
2 changed files with 16 additions and 4 deletions
|
@ -70,8 +70,8 @@ hook Supervisor::stdout_hook(node: string, msg: string)
|
|||
# Update the sliding window of recent output lines.
|
||||
Queue::put(g_outputs[node]$stdout, msg);
|
||||
|
||||
# Don't print this message in the Supervisor's own stdout
|
||||
break;
|
||||
if ( ! print_stdout )
|
||||
break;
|
||||
}
|
||||
|
||||
hook Supervisor::stderr_hook(node: string, msg: string)
|
||||
|
@ -87,8 +87,8 @@ hook Supervisor::stderr_hook(node: string, msg: string)
|
|||
|
||||
Queue::put(g_outputs[node]$stderr, msg);
|
||||
|
||||
# Don't print this message in the Supervisor's own stdout
|
||||
break;
|
||||
if ( ! print_stderr )
|
||||
break;
|
||||
}
|
||||
|
||||
event Supervisor::node_status(node: string, pid: count)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue