1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
use *;
/// Returns the current Unix timestamp in milliseconds.
///
/// # Returns
///
/// - `u64` - Milliseconds since Unix epoch (`0` if the system clock precedes the epoch).
pub
/// Returns whether a message has passed its optional TTL deadline.
///
/// # Arguments
///
/// - `&MqMessage` - Message to inspect.
/// - `u64` - Current Unix timestamp in milliseconds.
///
/// # Returns
///
/// - `bool` - `true` when `expires_at_ms` is set and `<= now_ms`.
pub
/// Formats the dead-letter queue key for `topic` using `config`.
///
/// # Arguments
///
/// - `&str` - Base topic name.
/// - `&MqConfig` - Broker configuration holding `dlq_suffix`.
///
/// # Returns
///
/// - `String` - Dead-letter queue key.
pub