Skip to content

Commit

Permalink
Increased throtteling time to half an hour
Browse files Browse the repository at this point in the history
  • Loading branch information
JoukoVirtanen committed Jan 25, 2024
1 parent 45ecc63 commit 0c69cf3
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions collector/lib/SysdigService.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -216,12 +216,12 @@ void LogUnreasonableEventTime(int64_t time_micros, sinsp_evt* evt) {

time_diff = time_micros - evt_ts;
if (time_diff > max_past_time) {
CLOG_THROTTLED(WARNING, std::chrono::seconds(10)) << "Event of type " << evt->get_type() << " is unreasonably old. It's timestamp is " << google::protobuf::util::TimeUtil::MicrosecondsToTimestamp(evt_ts);
CLOG_THROTTLED(WARNING, std::chrono::seconds(1800)) << "Event of type " << evt->get_type() << " is unreasonably old. It's timestamp is " << google::protobuf::util::TimeUtil::MicrosecondsToTimestamp(evt_ts);
COUNTER_INC(CollectorStats::event_timestamp_distant_past);
}

if (time_diff < -max_future_time) {
CLOG_THROTTLED(WARNING, std::chrono::seconds(10)) << "Event of type " << evt->get_type() << " is in the future. It's timestamp is " << google::protobuf::util::TimeUtil::MicrosecondsToTimestamp(evt_ts);
CLOG_THROTTLED(WARNING, std::chrono::seconds(1800)) << "Event of type " << evt->get_type() << " is in the future. It's timestamp is " << google::protobuf::util::TimeUtil::MicrosecondsToTimestamp(evt_ts);
COUNTER_INC(CollectorStats::event_timestamp_future);
}
}
Expand Down

0 comments on commit 0c69cf3

Please sign in to comment.