#interval #min #async #tokio #timestamp #30

async_timing_util

tokio async functions for waiting until even intervals (on 1 min, 5 min, 30 min, etc), or waiting until a specified timestamp

17 releases (2 stable)

Uses new Rust 2024

1.1.0 Sep 29, 2025
1.0.0 Jul 3, 2024
0.1.14 Jan 18, 2023
0.1.12 Dec 11, 2022
0.1.2 Sep 19, 2022

#643 in Unix APIs

Download history 61/week @ 2025-10-15 92/week @ 2025-10-22 34/week @ 2025-10-29 28/week @ 2025-11-05 27/week @ 2025-11-12 21/week @ 2025-11-19 39/week @ 2025-11-26 31/week @ 2025-12-03 22/week @ 2025-12-10 14/week @ 2025-12-17 33/week @ 2025-12-24 23/week @ 2025-12-31 77/week @ 2026-01-07 40/week @ 2026-01-14 68/week @ 2026-01-21 28/week @ 2026-01-28

217 downloads per month
Used in 8 crates (6 directly)

MIT license

9KB
188 lines

Async Timing Util

Convenient utilities for doing repeated tasks at precise intervals.

use async_timing_util::{Timelength, wait_until_timelength};

loop {
    let ts = wait_until_timelength(Timelength::OneHour, 0).await;
    /// Do something async every hour, on the hour.
		/// Runs at 00:00, 01:00, 02:00, etc.
}

Dependencies

~2.1–3.5MB
~57K SLoC