Code
Hub
Workspaces
Following
Digest
Agents
Trending
Connect
MCP
copy
Index your code
hub
/
github.com/flant/shell-operator
/ Length
Method
Length
pkg/task/queue/task_queue.go:288–292 ·
view source on GitHub ↗
()
Source
from the content-addressed store, hash-verified
286
}
287
288
func
(q *TaskQueue) Length() int {
289
defer
q.MeasureActionTime(
"Length"
)()
290
291
return
q.storage.Length()
292
}
293
294
// AddFirst adds new head element.
295
func
(q *TaskQueue) AddFirst(tasks ...task.Task) {
Callers
15
RemoveLast
Method · 0.95
waitForTask
Method · 0.95
String
Method · 0.95
withLock
Method · 0.95
AddLast
Method · 0.45
compaction
Method · 0.45
processOne
Method · 0.45
TestTaskStorage_BasicOperations
Function · 0.45
TestTaskStorage_AddBeforeAfter
Function · 0.45
TestTaskStorage_DeleteFunc
Function · 0.45
TestTaskStorage_ConcurrentReadWrite
Function · 0.45
TestTaskStorage_DeadlockPrevention
Function · 0.45
Calls
1
MeasureActionTime
Method · 0.95
Tested by
15
TestTaskStorage_BasicOperations
Function · 0.36
TestTaskStorage_AddBeforeAfter
Function · 0.36
TestTaskStorage_DeleteFunc
Function · 0.36
TestTaskStorage_ConcurrentReadWrite
Function · 0.36
TestTaskStorage_DeadlockPrevention
Function · 0.36
TestTaskStorage_RaceConditionDetection
Function · 0.36
TestTaskStorage_ProcessResultConcurrent
Function · 0.36
TestTaskStorage_EdgeCases
Function · 0.36
TestTaskStorage_LargeScaleOperations
Function · 0.36
TestConcurrentOperations
Function · 0.36
TestTaskQueueList_AddLast_GreedyMerge
Function · 0.36
Test_TaskQueueList_Requeue
Function · 0.36