MCPcopy
hub / github.com/panjf2000/ants / insert

Method insert

worker_queue.go:45–45  ·  view source on GitHub ↗
(worker)

Source from the content-addressed store, hash-verified

43 len() int
44 isEmpty() bool
45 insert(worker) error
46 detach() worker
47 refresh(duration time.Duration) []worker // clean up the stale workers and return them
48 reset()

Callers 6

TestWorkerStackFunction · 0.65
TestSearchFunction · 0.65
TestLoopQueueFunction · 0.65
TestRotatedQueueSearchFunction · 0.65
TestRetrieveExpiryFunction · 0.65
revertWorkerMethod · 0.65

Implementers 2

loopQueueworker_loop_queue.go
workerStackworker_stack.go

Calls

no outgoing calls

Tested by 5

TestWorkerStackFunction · 0.52
TestSearchFunction · 0.52
TestLoopQueueFunction · 0.52
TestRotatedQueueSearchFunction · 0.52
TestRetrieveExpiryFunction · 0.52