pub mod audit;
pub mod check_alert;
pub mod consumer_reset;
pub mod events;
pub mod explode;
pub mod heartbeat;
pub mod history;
pub mod host_perf;
pub mod notifications;
pub mod obs_events;
pub mod process_perf;
pub mod results;
pub mod spec_cache;
pub(crate) fn publish_time(msg: &async_nats::jetstream::Message) -> chrono::DateTime<chrono::Utc> {
msg.info()
.ok()
.and_then(|i| {
chrono::DateTime::from_timestamp(i.published.unix_timestamp(), i.published.nanosecond())
})
.unwrap_or_else(chrono::Utc::now)
}