Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Queue ¶
type Queue struct { Queue []*QueueEntry // contains filtered or unexported fields }
Queue is the qaiting queue
func (*Queue) GetLastSuccess ¶
GetLastSuccess fetches the commit hash of the last successful build
func (*Queue) Pop ¶
func (q *Queue) Pop(r *Running, maxBuilds int) *QueueEntry
Pop pops the index 0 of the queue if it can run
func (*Queue) SaveLastSuccess ¶
SaveLastSuccess saves the commits of the last successful build on a branch of a project
type QueueEntry ¶
type QueueEntry struct { Project string Branch string PrevCommit string CurrCommit string CreatedAt time.Time FinishedAt time.Time Status string }
QueueEntry is an entry in the waiting and running queue
type Running ¶
type Running struct { Builds []*QueueEntry Alive map[aliveKey]*QueueEntry KeepAlive map[aliveKey]bool }
Running is the running queue
Click to show internal directories.
Click to hide internal directories.