Documentation ¶
Index ¶
- Constants
- func Main()
- type ActivityHandler
- type ActivityStore
- type BoltDBIndex
- type BoltDBIndexTransaction
- type BroadcastHandler
- type Clock
- type Environment
- type Environments
- type InMemoryIndex
- type Index
- type IndexTransaction
- type Job
- type Jobs
- type Operation
- type Operations
- type Organization
- type Project
- type ProjectCard
- type ProjectCards
- type Projector
- type Projects
- type Response
- type StructuredLog
- func (self *StructuredLog) Each(do func(entry *StructuredLogEntry)) *StructuredLog
- func (self *StructuredLog) Errf(format string, args ...interface{}) error
- func (self *StructuredLog) Fatal(thing interface{})
- func (self *StructuredLog) Infof(format string, args ...interface{}) error
- func (self *StructuredLog) LogMessage(level string, text string) *StructuredLog
- func (self *StructuredLog) RenderHTML(w io.Writer)
- func (self *StructuredLog) RenderText(w io.Writer)
- type StructuredLogEntry
- type Task
- type Tasks
- type TypeError
Constants ¶
View Source
const ProgramName = "projector"
Variables ¶
This section is empty.
Functions ¶
Types ¶
type ActivityHandler ¶
type ActivityHandler interface { SubscribedTo() []string HandleActivity(IndexTransaction, *domain.Activity) error }
type ActivityStore ¶
type BoltDBIndex ¶
type BoltDBIndex struct {
// contains filtered or unexported fields
}
func NewBoltDBIndex ¶
func NewBoltDBIndex(db *bolt.DB) *BoltDBIndex
func (*BoltDBIndex) Update ¶
func (self *BoltDBIndex) Update(do func(tx IndexTransaction) error) error
type BoltDBIndexTransaction ¶
type BoltDBIndexTransaction struct {
// contains filtered or unexported fields
}
func NewBoltDBIndexTransaction ¶
func NewBoltDBIndexTransaction(tx *bolt.Tx, bucketName string) *BoltDBIndexTransaction
func (*BoltDBIndexTransaction) Get ¶
func (self *BoltDBIndexTransaction) Get(uuid string, dest interface{}) error
func (*BoltDBIndexTransaction) Put ¶
func (self *BoltDBIndexTransaction) Put(uuid string, src interface{}) error
type BroadcastHandler ¶
type BroadcastHandler struct {
// contains filtered or unexported fields
}
func NewBroadcastHandler ¶
func NewBroadcastHandler(log logger.Logger) *BroadcastHandler
func (*BroadcastHandler) Add ¶
func (self *BroadcastHandler) Add(handler ActivityHandler) *BroadcastHandler
func (*BroadcastHandler) HandleActivity ¶
func (self *BroadcastHandler) HandleActivity(tx IndexTransaction, activity *domain.Activity) error
func (*BroadcastHandler) LogStatus ¶
func (self *BroadcastHandler) LogStatus()
func (*BroadcastHandler) SubscribedTo ¶
func (self *BroadcastHandler) SubscribedTo() []string
type Environment ¶
type Environments ¶
type Environments struct { }
func NewEnvironments ¶
func NewEnvironments() *Environments
func (*Environments) HandleActivity ¶
func (self *Environments) HandleActivity(tx IndexTransaction, activity *domain.Activity) error
func (*Environments) SubscribedTo ¶
func (self *Environments) SubscribedTo() []string
type InMemoryIndex ¶
type InMemoryIndex struct {
// contains filtered or unexported fields
}
func NewInMemoryIndex ¶
func NewInMemoryIndex() *InMemoryIndex
func (*InMemoryIndex) Get ¶
func (self *InMemoryIndex) Get(uuid string, dest interface{}) error
func (*InMemoryIndex) Put ¶
func (self *InMemoryIndex) Put(uuid string, src interface{}) error
func (*InMemoryIndex) Update ¶
func (self *InMemoryIndex) Update(do func(tx IndexTransaction) error) error
type Index ¶
type Index interface {
Update(func(tx IndexTransaction) error) error
}
type IndexTransaction ¶
type Job ¶
type Job struct { Uuid string EnvironmentUuid string EnvironmentName string TaskUuid string TaskName string }
func (*Job) UpdateEnvironment ¶
func (self *Job) UpdateEnvironment(uuid string, index IndexTransaction) error
func (*Job) UpdateTask ¶
func (self *Job) UpdateTask(uuid string, index IndexTransaction) error
type Jobs ¶
type Jobs struct {
// contains filtered or unexported fields
}
func (*Jobs) HandleActivity ¶
func (self *Jobs) HandleActivity(tx IndexTransaction, activity *domain.Activity) error
func (*Jobs) SubscribedTo ¶
type Operation ¶
func (*Operation) ProjectUuid ¶
func (self *Operation) ProjectUuid(index IndexTransaction) string
type Operations ¶
func NewOperations ¶
func NewOperations() *Operations
func (*Operations) HandleActivity ¶
func (self *Operations) HandleActivity(tx IndexTransaction, activity *domain.Activity) error
func (*Operations) SubscribedTo ¶
func (self *Operations) SubscribedTo() []string
type Organization ¶
type Organization struct { Uuid string ProjectCards map[string]*ProjectCard }
type ProjectCard ¶
type ProjectCard struct { OrganizationUuid string `json:"organizationUuid"` ProjectUuid string `json:"projectUuid"` ProjectName string `json:"projectName"` LastTaskUuid string `json:"lastTaskUuid"` LastTaskName string `json:"lastTaskName"` LastTaskRunAt *time.Time `json:"lastTaskRunAt"` LastTaskStatus string `json:"lastTaskStatus"` // contains filtered or unexported fields }
type ProjectCards ¶
type ProjectCards struct { }
func NewProjectCards ¶
func NewProjectCards() *ProjectCards
func (*ProjectCards) HandleActivity ¶
func (self *ProjectCards) HandleActivity(tx IndexTransaction, activity *domain.Activity) error
func (*ProjectCards) IndexCard ¶
func (self *ProjectCards) IndexCard(tx IndexTransaction, card *ProjectCard) error
func (*ProjectCards) SubscribedTo ¶
func (self *ProjectCards) SubscribedTo() []string
type Projector ¶
type Projector struct {
// contains filtered or unexported fields
}
func (*Projector) HandleActivity ¶
func (self *Projector) HandleActivity(tx IndexTransaction, activity *domain.Activity) error
func (*Projector) SubscribedTo ¶
func (*Projector) Update ¶
func (self *Projector) Update(activityStore ActivityStore) error
type Projects ¶
type Projects struct { }
func NewProjects ¶
func NewProjects() *Projects
func (*Projects) HandleActivity ¶
func (self *Projects) HandleActivity(tx IndexTransaction, activity *domain.Activity) error
func (*Projects) SubscribedTo ¶
type Response ¶
type Response struct { Error string `json:"error"` Subject interface{} `json:"subject,omitempty"` Collection interface{} `json:"collection,omitempty"` }
type StructuredLog ¶
type StructuredLog struct {
// contains filtered or unexported fields
}
func NewStructuredLog ¶
func NewStructuredLog(size int, clock Clock) *StructuredLog
func (*StructuredLog) Each ¶
func (self *StructuredLog) Each(do func(entry *StructuredLogEntry)) *StructuredLog
func (*StructuredLog) Errf ¶
func (self *StructuredLog) Errf(format string, args ...interface{}) error
func (*StructuredLog) Fatal ¶
func (self *StructuredLog) Fatal(thing interface{})
func (*StructuredLog) Infof ¶
func (self *StructuredLog) Infof(format string, args ...interface{}) error
func (*StructuredLog) LogMessage ¶
func (self *StructuredLog) LogMessage(level string, text string) *StructuredLog
func (*StructuredLog) RenderHTML ¶
func (self *StructuredLog) RenderHTML(w io.Writer)
func (*StructuredLog) RenderText ¶
func (self *StructuredLog) RenderText(w io.Writer)
type StructuredLogEntry ¶
func (*StructuredLogEntry) Parse ¶
func (self *StructuredLogEntry) Parse(level string, now time.Time, text string)
func (*StructuredLogEntry) String ¶
func (self *StructuredLogEntry) String() string
type Tasks ¶
type Tasks struct { }
func (*Tasks) HandleActivity ¶
func (self *Tasks) HandleActivity(tx IndexTransaction, activity *domain.Activity) error
func (*Tasks) SubscribedTo ¶
Click to show internal directories.
Click to hide internal directories.