Commit e720a10
ADR: Channel size estimation is not supported (#257)
## Summary
- Adds ADR documenting the decision to not expose
`Channel.estimateSize()` or any size estimation on channels
- The lock-free segment-based algorithm tracks send/receive **attempts**
(not completions), so interrupted operations permanently inflate any
naive `senders - receivers` estimate
- Kotlin's kotlinx.coroutines (same algorithm) deliberately omits any
size method for the same reason
- Users who need channel-level metrics should build external solutions
(e.g., wrapping send/receive with their own counters)
Resolves #189. Supersedes #254.
Co-authored-by: Andrzej Kobyliński <andrzej.kobylinski@extern.corify.de>1 parent 84e145e commit e720a10
1 file changed
+34
-0
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 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 | + | |
0 commit comments