MCPcopy Create free account
hub / github.com/base/base / clear

Method clear

crates/consensus/engine/src/task_queue/core.rs:553–558  ·  view source on GitHub ↗

Clears the task queue.

(&mut self)

Source from the content-addressed store, hash-verified

551
552 /// Clears the task queue.
553 pub fn clear(&mut self) {
554 self.tasks.clear();
555 self.next_task_sequence = 0;
556 self.task_queue_length.send_replace(0);
557 Metrics::engine_task_queue_depth().set(0.0);
558 }
559
560 /// Attempts to drain the queue by executing all [`EngineTask`]s in-order. If any task returns
561 /// an error along the way, it is not popped from the queue (in case it must be retried) and

Calls 1

setMethod · 0.45

Tested by 1