Skip to content

Commit

Permalink
refactor(stats): log stats update skip decision (#967)
Browse files Browse the repository at this point in the history
* feat: log update skip

* log(stats): debug log the timestamps to clearly see the decision process
  • Loading branch information
bragov4ik authored Jul 2, 2024
1 parent c4261d0 commit 08b38a5
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions stats/stats/src/data_source/kinds/local_db/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -154,7 +154,16 @@ where
// no need to perform update.
// mostly catches second call to update e.g. when both
// dependency and this source are in one group and enabled.
tracing::debug!(
"Not updating the chart because it was already handled within ongoing update"
);
return Ok(());
} else {
tracing::debug!(
last_updated_at =? last_updated_at,
update_timestamp =? cx.time,
"Performing an update"
);
}
}
let chart_id = metadata.id;
Expand Down

0 comments on commit 08b38a5

Please sign in to comment.