btest/broker: Prepare for non-Broker default

This commit is contained in:
Arne Welzel 2025-09-24 12:56:51 +02:00
parent 3dd95b90c1
commit 6ce9a33002
12 changed files with 15 additions and 21 deletions

View file

@ -10,4 +10,3 @@ is_remote should be T, and is, T
receiver got ping: my-message, 4 receiver got ping: my-message, 4
is_remote should be T, and is, T is_remote should be T, and is, T
receiver got ping: my-message, 5 receiver got ping: my-message, 5
[num_peers=1, num_stores=0, num_pending_queries=0, num_events_incoming=5, num_events_outgoing=4, num_logs_incoming=0, num_logs_outgoing=1, num_ids_incoming=0, num_ids_outgoing=0]

View file

@ -10,4 +10,3 @@ is_remote should be T, and is, T
receiver got ping: my-message, 4 receiver got ping: my-message, 4
is_remote should be T, and is, T is_remote should be T, and is, T
receiver got ping: my-message, 5 receiver got ping: my-message, 5
[num_peers=1, num_stores=0, num_pending_queries=0, num_events_incoming=5, num_events_outgoing=4, num_logs_incoming=0, num_logs_outgoing=1, num_ids_incoming=0, num_ids_outgoing=0]

View file

@ -5,4 +5,3 @@ receiver got ping: my-message, 2
receiver got ping: my-message, 3 receiver got ping: my-message, 3
receiver got ping: my-message, 4 receiver got ping: my-message, 4
receiver got ping: my-message, 5 receiver got ping: my-message, 5
[num_peers=1, num_stores=0, num_pending_queries=0, num_events_incoming=5, num_events_outgoing=4, num_logs_incoming=0, num_logs_outgoing=1, num_ids_incoming=0, num_ids_outgoing=0]

View file

@ -18,6 +18,8 @@
# The existence of the environment variable will add a corresponding node # The existence of the environment variable will add a corresponding node
# to Cluster::nodes. # to Cluster::nodes.
# Explicitly set the broker backend here.
redef Cluster::backend = Cluster::CLUSTER_BACKEND_BROKER;
# Redef'ed to F if logger-1 or logger-2 are active. # Redef'ed to F if logger-1 or logger-2 are active.
redef Cluster::manager_is_logger = T; redef Cluster::manager_is_logger = T;

View file

@ -98,10 +98,4 @@ event ping(msg: string, n: count)
local e = Broker::make_event(pong, msg, n); local e = Broker::make_event(pong, msg, n);
Broker::publish("zeek/event/my_topic", e); Broker::publish("zeek/event/my_topic", e);
} }
event zeek_done()
{
print get_broker_stats();
}
# @TEST-END-FILE # @TEST-END-FILE

View file

@ -106,10 +106,4 @@ event ping(msg: string, n: any)
# internals should not wrap n into another Broker::Data record # internals should not wrap n into another Broker::Data record
Broker::publish("zeek/event/my_topic", pong, msg, n); Broker::publish("zeek/event/my_topic", pong, msg, n);
} }
event zeek_done()
{
print get_broker_stats();
}
# @TEST-END-FILE # @TEST-END-FILE

View file

@ -235,10 +235,4 @@ event ping(msg: string, n: count)
local e = Broker::make_event(pong, msg, n); local e = Broker::make_event(pong, msg, n);
Broker::publish("zeek/event/my_topic", e); Broker::publish("zeek/event/my_topic", e);
} }
event zeek_done()
{
print get_broker_stats();
}
# @TEST-END-FILE # @TEST-END-FILE

View file

@ -15,6 +15,9 @@
redef exit_only_after_terminate = T; redef exit_only_after_terminate = T;
# Make the logging framework use broker!
redef Cluster::backend = Cluster::CLUSTER_BACKEND_BROKER;
module Test; module Test;
export { export {

View file

@ -15,6 +15,9 @@
redef exit_only_after_terminate = T; redef exit_only_after_terminate = T;
# Make the logging framework use broker!
redef Cluster::backend = Cluster::CLUSTER_BACKEND_BROKER;
module Test; module Test;
export { export {

View file

@ -15,6 +15,9 @@
redef exit_only_after_terminate = T; redef exit_only_after_terminate = T;
# Make the logging framework use broker!
redef Cluster::backend = Cluster::CLUSTER_BACKEND_BROKER;
module Test; module Test;
export { export {

View file

@ -18,6 +18,9 @@
redef exit_only_after_terminate = T; redef exit_only_after_terminate = T;
# Make the logging framework use broker!
redef Cluster::backend = Cluster::CLUSTER_BACKEND_BROKER;
global quit_receiver: event(); global quit_receiver: event();
module Test; module Test;

View file

@ -14,6 +14,7 @@
# @TEST-START-FILE common.zeek # @TEST-START-FILE common.zeek
@load base/frameworks/cluster @load base/frameworks/cluster
@load base/frameworks/telemetry
@load policy/frameworks/cluster/experimental @load policy/frameworks/cluster/experimental
redef exit_only_after_terminate = T; redef exit_only_after_terminate = T;