Documentation ¶
Index ¶
- Constants
- type Manager
- type ProjectUpdateDomainService
- type ProjectUpdateStage
- func (stage ProjectUpdateStage) AreDomainServicesComplete() bool
- func (stage ProjectUpdateStage) Copy() ProjectUpdateStage
- func (stage1 ProjectUpdateStage) Equal(stage2 ProjectUpdateStage) bool
- func (stage ProjectUpdateStage) FindDomainServiceIndex(producerID string) (int, error)
- func (stage ProjectUpdateStage) HasFailedDomainService() bool
- func (stage ProjectUpdateStage) OldestDomainServiceUpdateTime() time.Time
- func (stage ProjectUpdateStage) StartRunning(projectUpdateID string) ProjectUpdateStage
- func (stage ProjectUpdateStage) StopRunning() ProjectUpdateStage
Constants ¶
View Source
const ( RunningState = "running" NotRunningState = "not_running" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Manager ¶
type Manager struct {
// contains filtered or unexported fields
}
Manager - configuration manager for the service
func NewManager ¶
NewManager - create a new config. There should only be one config for the service.
func (*Manager) Close ¶
func (manager *Manager) Close()
Close - to close out the channel for this object. This should only be called when the service is being shutdown
func (*Manager) GetProjectUpdateStage ¶
func (manager *Manager) GetProjectUpdateStage() ProjectUpdateStage
GetProjectUpdateStage - get the project update stage
func (*Manager) UpdateProjectUpdateStage ¶
func (manager *Manager) UpdateProjectUpdateStage(projectUpdateStage ProjectUpdateStage) error
UpdateProjectUpdateStage - update the project update stage
type ProjectUpdateDomainService ¶
type ProjectUpdateDomainService struct { Name string `toml:"name"` PercentageComplete float64 `toml:"percentage_complete"` EstimatedTimeCompelete time.Time `toml:"estimated_time_compelete"` LastUpdate time.Time `toml:"last_update"` Complete bool `toml:"complete"` Failed bool `toml:"failed"` FailureMessage string `toml:"failure_message"` }
type ProjectUpdateStage ¶
type ProjectUpdateStage struct { State string `toml:"state"` ProjectUpdateID string `toml:"project_update_id"` DomainServices []ProjectUpdateDomainService `toml:"domain_services"` FailureMessage string `toml:"failure_message"` Failed bool `toml:"failed"` }
ProjectUpdateStage - the config for project updating The stage is all the data that needs to be remembered if the service is restarted.
func (ProjectUpdateStage) AreDomainServicesComplete ¶
func (stage ProjectUpdateStage) AreDomainServicesComplete() bool
func (ProjectUpdateStage) Copy ¶
func (stage ProjectUpdateStage) Copy() ProjectUpdateStage
func (ProjectUpdateStage) Equal ¶
func (stage1 ProjectUpdateStage) Equal(stage2 ProjectUpdateStage) bool
func (ProjectUpdateStage) FindDomainServiceIndex ¶
func (stage ProjectUpdateStage) FindDomainServiceIndex(producerID string) (int, error)
func (ProjectUpdateStage) HasFailedDomainService ¶
func (stage ProjectUpdateStage) HasFailedDomainService() bool
func (ProjectUpdateStage) OldestDomainServiceUpdateTime ¶
func (stage ProjectUpdateStage) OldestDomainServiceUpdateTime() time.Time
func (ProjectUpdateStage) StartRunning ¶
func (stage ProjectUpdateStage) StartRunning(projectUpdateID string) ProjectUpdateStage
func (ProjectUpdateStage) StopRunning ¶
func (stage ProjectUpdateStage) StopRunning() ProjectUpdateStage
Click to show internal directories.
Click to hide internal directories.