🐛 fix closed async backlog accounting

This commit is contained in:
Nanaloveyuki
2026-06-14 02:06:59 +08:00
parent d9b609d064
commit 9af489336d
5 changed files with 36 additions and 3 deletions
+1
View File
@@ -36,6 +36,7 @@ Detailed rules explaining key parameters and behaviors
- The count increases when records are accepted into the queue.
- The count decreases as the worker drains records.
- The count is also reset to `0` when queued records are abandoned through clear-close paths such as `close(clear=true)`.
- Log attempts against a closed queue do not create new pending backlog.
- This is a point-in-time metric and may change immediately after it is read.
- Use this helper when a single backlog number is enough and a full `state()` snapshot is unnecessary.