* Reset the queue - clears all messages and resets to empty state
()
| 273 | * Reset the queue - clears all messages and resets to empty state |
| 274 | */ |
| 275 | reset(): void { |
| 276 | logger.debug(`[MessageQueue2] reset() called. Clearing ${this.queue.length} messages`); |
| 277 | this.queue = []; |
| 278 | this.closed = false; |
| 279 | |
| 280 | // Clear waiter without calling it since we're not closing |
| 281 | this.waiter = null; |
| 282 | } |
| 283 | |
| 284 | /** |
| 285 | * Close the queue - no more messages can be pushed |
no test coverage detected