Skip to main content

next

Function next 

Source
pub fn next() -> String
Expand description

Generate a new opaque request id in the shape forge_<counter>_<hex8>. The 8-hex (4 bytes) suffix is random. Falls back to counter bytes if getrandom fails - surfaces a one-shot tracing::warn! so a sandboxed runtime where the entropy source is unreachable (chroot without /dev/urandom, seccomp filter, etc.) is visible to log readers without breaking ID generation.