Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CloudManager ¶ added in v0.5.0
type CloudManager interface {
CreateCloud(*api.Cloud) (*api.Cloud, error)
ListClouds() ([]api.Cloud, error)
DeleteCloud(name string) error
PingCloud(name string) error
ListWorkers(name string, extendInfo string) ([]api.WorkerInstance, error)
}
CloudManager represents the interface to manage cloud.
func NewCloudManager ¶ added in v0.5.0
func NewCloudManager(dataStore *store.DataStore) (CloudManager, error)
NewCloudManager creates a cloud manager.
type EventManager ¶ added in v0.5.0
type EventManager interface {
GetEvent(id string) (*api.Event, error)
SetEvent(event *api.Event) (*api.Event, error)
}
EventManager represents the interface to manage event.
func NewEventManager ¶ added in v0.5.0
func NewEventManager(dataStore *store.DataStore) (EventManager, error)
NewEventManager creates a event manager.
type PipelineManager ¶
type PipelineManager interface {
CreatePipeline(projectName string, pipeline *api.Pipeline) (*api.Pipeline, error)
GetPipeline(projectName string, pipelineName string, recentCount, recentSuccessCount, recentFailedCount int) (*api.Pipeline, error)
GetPipelineByID(id string) (*api.Pipeline, error)
ListPipelines(projectName string, queryParams api.QueryParams, recentCount, recentSuccessCount, recentFailedCount int) ([]api.Pipeline, int, error)
UpdatePipeline(projectName string, pipelineName string, newPipeline *api.Pipeline) (*api.Pipeline, error)
DeletePipeline(projectName string, pipelineName string) error
ClearPipelinesOfProject(projectName string) error
GetStatistics(projectName, pipelineName string, start, end time.Time) (*api.PipelineStatusStats, error)
FindSVNHooksPipelines(repoid string) ([]api.Pipeline, error)
}
PipelineManager represents the interface to manage pipeline.
func NewPipelineManager ¶
func NewPipelineManager(dataStore *store.DataStore, pipelineRecordManager PipelineRecordManager) (PipelineManager, error)
NewPipelineManager creates a pipeline manager.
type PipelineRecordManager ¶
type PipelineRecordManager interface {
CreatePipelineRecord(pipelineRecord *api.PipelineRecord) (*api.PipelineRecord, error)
GetPipelineRecord(pipelineRecordID string) (*api.PipelineRecord, error)
ListPipelineRecords(projectName string, pipelineName string, queryParams api.QueryParams) ([]api.PipelineRecord, int, error)
UpdatePipelineRecord(pipelineRecordID string, pipelineRecord *api.PipelineRecord) (*api.PipelineRecord, error)
DeletePipelineRecord(pipelineRecordID string) error
ClearPipelineRecordsOfPipeline(pipelineID string) error
GetPipelineRecordLogs(pipelineRecordID, stage, task string) (string, error)
GetPipelineRecordTestResult(pipelineRecordID, fileName string) (string, error)
ListPipelineRecordTestResults(pipelineRecordID string) ([]*api.TestResult, int, error)
GetPipelineRecordLogStream(pipelineRecordID, stage, task string, ws *websocket.Conn) error
ReceivePipelineRecordLogStream(pipelineRecordID, stage, task string, ws *websocket.Conn) error
ReceivePipelineRecordTestResult(pipelineRecordID, fileName string, reader io.Reader) error
}
PipelineRecordManager represents the interface to manage pipeline record.
func NewPipelineRecordManager ¶
func NewPipelineRecordManager(dataStore *store.DataStore, threshold int) (PipelineRecordManager, error)
NewPipelineRecordManager creates a pipeline record manager.
type ProjectManager ¶
type ProjectManager interface {
CreateProject(project *api.Project) (*api.Project, error)
GetProject(projectName string) (*api.Project, error)
GetProjectByID(id string) (*api.Project, error)
ListProjects(queryParams api.QueryParams) ([]api.Project, int, error)
UpdateProject(projectName string, newProject *api.Project) (*api.Project, error)
DeleteProject(projectName string) error
ListRepos(projectName string) ([]api.Repository, error)
ListBranches(projectName string, repo string) ([]string, error)
ListTags(projectName string, repo string) ([]string, error)
GetTemplateType(projectName string, repo string) (string, error)
GetStatistics(projectName string, start, end time.Time) (*api.PipelineStatusStats, error)
}
ProjectManager represents the interface to manage project.
func NewProjectManager ¶
func NewProjectManager(dataStore *store.DataStore, pipelineManager PipelineManager) (ProjectManager, error)
NewProjectManager creates a project manager.
Click to show internal directories.
Click to hide internal directories.