(cobra bots) add a --heartbeat_timeout option to specify when the bot should terminate because no events are received
This commit is contained in:
@ -89,6 +89,7 @@ TEST_CASE("Cobra_to_stdout_bot", "[cobra_bots]")
|
||||
std::string position("$");
|
||||
bool quiet = false;
|
||||
bool enableHeartbeat = false;
|
||||
int heartBeatTimeout = 60;
|
||||
|
||||
// Only run the bot for 3 seconds
|
||||
int runtime = 3;
|
||||
@ -96,8 +97,15 @@ TEST_CASE("Cobra_to_stdout_bot", "[cobra_bots]")
|
||||
// We could try to capture the output ... not sure how.
|
||||
bool fluentd = true;
|
||||
|
||||
int64_t sentCount = ix::cobra_to_stdout_bot(
|
||||
config, channel, filter, position, fluentd, quiet, enableHeartbeat, runtime);
|
||||
int64_t sentCount = ix::cobra_to_stdout_bot(config,
|
||||
channel,
|
||||
filter,
|
||||
position,
|
||||
fluentd,
|
||||
quiet,
|
||||
enableHeartbeat,
|
||||
heartBeatTimeout,
|
||||
runtime);
|
||||
//
|
||||
// We want at least 2 messages to be sent
|
||||
//
|
||||
|
Reference in New Issue
Block a user