Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Emit events from the PipelineRun controller #2545

Closed
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 10 additions & 2 deletions docs/events.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,13 +27,21 @@ No events are emitted for `Conditions` today (https://github.com/tektoncd/pipeli
successfully, including post-steps injected by Tekton.
- `Failed`: this is triggered if the `TaskRun` is completed, but not successfully.
Causes of failure may be: one the steps failed, the `TaskRun` was cancelled or
the `TaskRun` timed out.
the `TaskRun` timed out. `Failed` events are also triggered in case the `TaskRun`
cannot be executed at all because of validation issues.

## PipelineRuns

`PipelineRun` events are generated for the following `Reasons`:
- `Started`: this is triggered the first time the `PipelineRun` is picked by the
reconciler from its work queue, so it only happens if web-hook validation was
successful. Note that this event does not imply that a step started executing,
as pipeline, task and bound resource validation must be successful first.
- `Running`: this is triggered when the `PipelineRun` passes validation and
actually starts running.
- `Succeeded`: this is triggered once all `Tasks` reachable via the DAG are
executed successfully.
- `Failed`: this is triggered if the `PipelineRun` is completed, but not
successfully. Causes of failure may be: one the `Tasks` failed or the
`PipelineRun` was cancelled.
`PipelineRun` was cancelled or timed out. `Failed` events are also triggered
in case the `PipelineRun` cannot be executed at all because of validation issues.
afrittoli marked this conversation as resolved.
Show resolved Hide resolved
1 change: 1 addition & 0 deletions pkg/reconciler/pipelinerun/controller.go
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,7 @@ func NewController(namespace string, images pipeline.Images) func(context.Contex
KubeClientSet: kubeclientset,
PipelineClientSet: pipelineclientset,
Logger: logger,
Recorder: controller.GetEventRecorder(ctx),
}

c := &Reconciler{
Expand Down
Loading