MCPcopy Create free account
hub / github.com/cortexproject/cortex / Length

Method Length

pkg/util/priority_queue.go:56–60  ·  view source on GitHub ↗

Length returns the length of the queue.

()

Source from the content-addressed store, hash-verified

54
55// Length returns the length of the queue.
56func (pq *PriorityQueue) Length() int {
57 pq.lock.Lock()
58 defer pq.lock.Unlock()
59 return len(pq.queue)
60}
61
62// Close signals that the queue should be closed when it is empty.
63// A closed queue will not accept new items.

Callers 2

TestPriorityQueueBasicFunction · 0.95
lengthMethod · 0.80

Calls

no outgoing calls

Tested by 1

TestPriorityQueueBasicFunction · 0.76