package
0.4.0
Repository: https://github.com/maxatome/cds.git
Documentation: pkg.go.dev

# Packages

No description provided by the author

# Functions

AWOLPipelineKiller will search in database for actions : - Having building status - Without any logs ouput in the last 15 minutes.
BuildExists checks if a build already exist.
CheckParameterInPipeline check if the parameter is already in the pipeline or not.
CheckPrerequisites verifies that all prerequisite are matched before scheduling.
CountPipelineByProject Count the number of pipelines for the given project.
CountStageByPipelineID Count the number of stages for the given pipeline.
CurrentAndPreviousPipelineBuildNumberAndHash returns a struct with BuildNumber, Commit Hash and Branchfor the current pipeline build and the previous one on the same branch.Returned pointers may be null if pipeline build are not found.
DeleteActionBuild Delete Action Build.
DeleteAllParameterFromPipeline Delete all parameters from the given pipeline.
DeleteAllStage Delete all stages from pipeline ID.
DeleteBuild Delete a build.
DeleteBuildLogs delete build log.
DeleteJob Delete a job ( action + pipeline_action ).
DeleteParameterFromPipeline Delete a parameter from the given pipeline.
DeletePipeline remove given pipeline and all history from database.
DeletePipelineAction Delete an action in a pipeline.
DeletePipelineActionByStage Delete all action from a stage.
DeletePipelineBuild deletes a pipeline build and generated artifacts.
DeletePipelineBuildArtifact Delete artifact for the current build.
DeletePipelineTestResults removes from database test results for a specific pipeline.
DeleteStageByID Delete stage with associated pipeline action.
DeleteTestResults removes from database test results for a specific pipeline build.
ExistPipeline Check if the given pipeline exist in database.
GetAllLastBuildByApplication Get the last build result for all pipelines in the given application.
GetAllLastBuildByApplicationAndVersion Get the last build for current application/branch/version.
GetAllParametersInPipeline Get all parameters for the given pipeline.
GetBranches from pipeline build and pipeline history for the given application.
GetBranchHistory Get last build for all branches.
GetDeploymentHistory Get all last deployment.
GetLastBuildNumber Get the last build number for the given pipeline.
GetProbableLastBuildNumber returns the last build number at the time of query.
GetVersions Get version for the given application and branch.
Import insert the pipeline in the project of check if the template is the same as existing.
InsertBuildVariable adds a variable exported in user scripts and forwarded by building worker.
InsertJob Insert a new Job ( pipeline_action + joinedAction ).
InsertLog insert build log into database.
InsertParameterInPipeline Insert a new parameter in the given pipeline.
InsertPipeline inserts pipeline informations in database.
InsertPipelineAction insert an action in a pipeline.
InsertPipelineBuild insert build informations in database so Scheduler can pick it up.
InsertPipelineJob insert data in pipeline_action table DEPRECATED.
InsertStage insert given stage into given database.
InsertStagePrequisites insert prequisite for given stage in database.
InsertTestResults inserts test results of a specific pipeline build in database.
LoadActionBuild Load an action_build by ID.
LoadActionStatus Load status of action_build for the given pipeline_action.
LoadBuildByPipelineBuildID Load all actions_build by pipeline ID.
LoadBuildIDsToArchive Load build to archive.
LoadBuildingPipelines retrieves pipelines in database having a build running.
LoadCompletePipelineBuildToArchive Load all information about a build.
No description provided by the author
LoadGroupWaitingQueue loads action build in queue accessbible to given group.
LoadLogs retrieves build logs from databse given an offset and a size.
LoadPipeline loads a pipeline from database.
LoadPipelineActionBuildLogs Load log for the given pipeline action.
LoadPipelineBuild retrieves informations about a specific build.
LoadPipelineBuildByHash look for a pipeline build triggered by a change with given hash.
LoadPipelineBuildByID look for a pipeline build by pipelineBuildID.
LoadPipelineBuildChildren load triggered pipeline from given build.
LoadPipelineBuildHistoryByApplication Load application history DEPRECATED! See: project.LoadBuildActivity.
LoadPipelineBuildHistoryByApplicationAndPipeline Load pipeline history.
LoadPipelineBuildLogs Load pipeline build logs by pipeline ID.
LoadPipelineByGroup loads all pipelines where group has access.
LoadPipelineByID loads a pipeline from database.
LoadPipelineHistoryBuild retrieves informations about a specific build in pipeline_history.
LoadPipelines loads all pipelines in a project.
No description provided by the author
LoadRecentPipelineBuild retrieves pipelines in database having a build running or finished less than a minute ago.
LoadStage Get a stage from its ID and pipeline ID.
LoadStages Get all stages for the given pipeline.
LoadTestResults retrieves tests on a specific build in database.
LoadUserBuildingPipelines retrieves all building pipelines user has access to.
LoadUserRecentPipelineBuild retrieves all user accessible pipeline build finished less than a minute ago.
LoadUserWaitingQueue loads action build in queue where user has access.
LoadWaitingQueue Load Waiting action_build.
MoveStage Move a stage.
ProcessPipelineBuildVariables gathers together parameters from: - RunRequest -> add "cds.pip." prefix to them - Trigger parameters - Default PipelineApplication parameters - Builtin cds variables (.cds.* and .git.*).
RestartActionBuild destroy action build data and queue it up again.
RestartPipelineBuild restarts failed actions build.
SavePipelineBuildHistory Archive current build.
SelectBuildForUpdate Select a build and lock a build.
SelectBuildInHistory load history of the given build.
SelectBuildsInHistory load history.
StopPipelineBuild fails all currently building actions.
TakeActionBuild Take an action build for update.
UpdateActionBuildStatus Update status of an action_build.
UpdateJob updates the job by actionData.PipelineActionID and actionData.ID.
UpdateParameterInPipeline Update a parameter in the given pipeline.
UpdatePipeline update the pipeline.
UpdatePipelineAction Update an action in a pipeline.
UpdatePipelineBuildStatus Update status of pipeline_build.
UpdatePipelineLastModified Update last_modified date on pipeline.
UpdateStage update Stage and all its prequisites.
UpdateTestResults update test results of a specific pipeline build in database.
WithParameters set boolean to load parameters.
WithStages set boolean to load stages.

# Constants

LoadPipelineBuildRequest Load pipeline build activities.
LoadPipelineBuildStage Load pipeline build stage + action builds.
LoadPipelineBuildWithActions loads pipelines builds with its stages and action builds.
LoadPipelineHistoryRequest Load pipeline history request without json data.

# Variables

ErrAlreadyTaken Action already taken by a worker.
ErrNoStage when request requires specific stage but it does not exist.

# Structs

BuildNumberAndHash represents BuildNumber, Commit Hash and Branch for a Pipeline Build.

# Type aliases

FuncArg defines the base type for functional argument of pipeline funcs.