Commit 05c6b08
fix(audience): gate FlushAsync on _sendInFlight
Two concurrent FlushAsync callers would both call ReadBatch with the
same paths and double-POST. Reuse the timer-tick gate so at most one
SendBatchAsync runs at a time; other callers poll cheaply until the
gate clears.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>1 parent 29cd319 commit 05c6b08
1 file changed
Lines changed: 18 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
445 | 445 | | |
446 | 446 | | |
447 | 447 | | |
448 | | - | |
449 | | - | |
| 448 | + | |
| 449 | + | |
| 450 | + | |
| 451 | + | |
| 452 | + | |
450 | 453 | | |
| 454 | + | |
| 455 | + | |
| 456 | + | |
| 457 | + | |
| 458 | + | |
| 459 | + | |
| 460 | + | |
| 461 | + | |
| 462 | + | |
| 463 | + | |
| 464 | + | |
| 465 | + | |
| 466 | + | |
451 | 467 | | |
452 | 468 | | |
453 | 469 | | |
| |||
0 commit comments