add bounded history sink (#1)

This commit is contained in:
Nanaloveyuki
2026-08-11 13:30:58 +08:00
committed by GitHub
parent 0b05ee0c94
commit aab7a94ae2
38 changed files with 318 additions and 26 deletions
+20
View File
@@ -0,0 +1,20 @@
---
name: history-sink-dropped-count
group: api
category: sink
update-time: 20260811
description: Read the number of oldest records evicted from a HistorySink.
key-word:
- sink
- history
- dropped
---
## History-sink-dropped-count
```moonbit
pub fn HistorySink::dropped_count(self : HistorySink) -> Int
```
Returns the cumulative number of records evicted because the bounded history was
full. `clear()` resets this count for the new history session.