* Flush pending client events (writeEvent queue). Call before close() * when the caller needs delivery confirmation — close() abandons the * queue. Resolves once the uploader drains or rejects; returns * regardless of whether individual POSTs succeeded (check server state * separately if
()
| 829 | * separately if that matters). |
| 830 | */ |
| 831 | async flush(): Promise<void> { |
| 832 | await this.flushStreamEventBuffer() |
| 833 | return this.eventUploader.flush() |
| 834 | } |
| 835 | |
| 836 | /** |
| 837 | * Read foreground agent internal events from |
no test coverage detected