Skip to content

Commit d9974e2

Browse files
waveywavestekton-robot
authored andcommitted
feat: promote StepActions to GA
Upgrade StepActions feature from beta to stable to make sure that it is enabled by default. StepActions has been in beta for a while and is also has good adoption among the community. It is pretty stable as a feature based on the regular usage. Moving it to GA will make sure that users will have access to better pipeline composability from the get-go. The following changes were made: - set enable-step-actions to "true" by default - updated to reflect that StepActions are now enabled by default - changed the feature flag stability from BetaAPIFields to StableAPIFields in feature_flags.go - updated feature flags, e2e tests and test data - moved relevant examples to stable examples - added relevant documentation for the move from beta to stable - make enable-step-actions into no-op feature flag. This change makes StepActions a stable, first-class feature in Tekton Pipelines.
1 parent 5d7aa0e commit d9974e2

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

47 files changed

+146
-811
lines changed

config/300-crds/300-pipelinerun.yaml

+4
Original file line numberDiff line numberDiff line change
@@ -2198,6 +2198,7 @@ spec:
21982198
enableProvenanceInStatus:
21992199
type: boolean
22002200
enableStepActions:
2201+
description: EnableStepActions is a no-op flag since StepActions are stable
22012202
type: boolean
22022203
enforceNonfalsifiability:
22032204
type: string
@@ -2610,6 +2611,7 @@ spec:
26102611
enableProvenanceInStatus:
26112612
type: boolean
26122613
enableStepActions:
2614+
description: EnableStepActions is a no-op flag since StepActions are stable
26132615
type: boolean
26142616
enforceNonfalsifiability:
26152617
type: string
@@ -2896,6 +2898,7 @@ spec:
28962898
enableProvenanceInStatus:
28972899
type: boolean
28982900
enableStepActions:
2901+
description: EnableStepActions is a no-op flag since StepActions are stable
28992902
type: boolean
29002903
enforceNonfalsifiability:
29012904
type: string
@@ -5115,6 +5118,7 @@ spec:
51155118
enableProvenanceInStatus:
51165119
type: boolean
51175120
enableStepActions:
5121+
description: EnableStepActions is a no-op flag since StepActions are stable
51185122
type: boolean
51195123
enforceNonfalsifiability:
51205124
type: string

config/300-crds/300-stepaction.yaml

+2-8
Original file line numberDiff line numberDiff line change
@@ -263,10 +263,7 @@ spec:
263263
description: Results are values that this StepAction can output
264264
type: array
265265
items:
266-
description: |-
267-
StepResult used to describe the Results of a Step.
268-
269-
This is field is at an BETA stability level and gated by "enable-step-actions" feature flag.
266+
description: StepResult used to describe the Results of a Step.
270267
type: object
271268
required:
272269
- name
@@ -803,10 +800,7 @@ spec:
803800
description: Results are values that this StepAction can output
804801
type: array
805802
items:
806-
description: |-
807-
StepResult used to describe the Results of a Step.
808-
809-
This is field is at an BETA stability level and gated by "enable-step-actions" feature flag.
803+
description: StepResult used to describe the Results of a Step.
810804
type: object
811805
required:
812806
- name

config/300-crds/300-task.yaml

+2-12
Original file line numberDiff line numberDiff line change
@@ -3855,17 +3855,12 @@ spec:
38553855
description: |-
38563856
Results declares StepResults produced by the Step.
38573857
3858-
This is field is at an ALPHA stability level and gated by "enable-step-actions" feature flag.
3859-
38603858
It can be used in an inlined Step when used to store Results to $(step.results.resultName.path).
38613859
It cannot be used when referencing StepActions using [v1beta1.Step.Ref].
38623860
The Results declared by the StepActions will be stored here instead.
38633861
type: array
38643862
items:
3865-
description: |-
3866-
StepResult used to describe the Results of a Step.
3867-
3868-
This is field is at an BETA stability level and gated by "enable-step-actions" feature flag.
3863+
description: StepResult used to describe the Results of a Step.
38693864
type: object
38703865
required:
38713866
- name
@@ -6865,17 +6860,12 @@ spec:
68656860
description: |-
68666861
Results declares StepResults produced by the Step.
68676862
6868-
This is field is at an ALPHA stability level and gated by "enable-step-actions" feature flag.
6869-
68706863
It can be used in an inlined Step when used to store Results to $(step.results.resultName.path).
68716864
It cannot be used when referencing StepActions using [v1.Step.Ref].
68726865
The Results declared by the StepActions will be stored here instead.
68736866
type: array
68746867
items:
6875-
description: |-
6876-
StepResult used to describe the Results of a Step.
6877-
6878-
This is field is at an BETA stability level and gated by "enable-step-actions" feature flag.
6868+
description: StepResult used to describe the Results of a Step.
68796869
type: object
68806870
required:
68816871
- name

config/300-crds/300-taskrun.yaml

+5-6
Original file line numberDiff line numberDiff line change
@@ -1774,6 +1774,7 @@ spec:
17741774
enableProvenanceInStatus:
17751775
type: boolean
17761776
enableStepActions:
1777+
description: EnableStepActions is a no-op flag since StepActions are stable
17771778
type: boolean
17781779
enforceNonfalsifiability:
17791780
type: string
@@ -2060,6 +2061,7 @@ spec:
20602061
enableProvenanceInStatus:
20612062
type: boolean
20622063
enableStepActions:
2064+
description: EnableStepActions is a no-op flag since StepActions are stable
20632065
type: boolean
20642066
enforceNonfalsifiability:
20652067
type: string
@@ -3763,6 +3765,7 @@ spec:
37633765
enableProvenanceInStatus:
37643766
type: boolean
37653767
enableStepActions:
3768+
description: EnableStepActions is a no-op flag since StepActions are stable
37663769
type: boolean
37673770
enforceNonfalsifiability:
37683771
type: string
@@ -4015,6 +4018,7 @@ spec:
40154018
enableProvenanceInStatus:
40164019
type: boolean
40174020
enableStepActions:
4021+
description: EnableStepActions is a no-op flag since StepActions are stable
40184022
type: boolean
40194023
enforceNonfalsifiability:
40204024
type: string
@@ -6487,17 +6491,12 @@ spec:
64876491
description: |-
64886492
Results declares StepResults produced by the Step.
64896493
6490-
This is field is at an ALPHA stability level and gated by "enable-step-actions" feature flag.
6491-
64926494
It can be used in an inlined Step when used to store Results to $(step.results.resultName.path).
64936495
It cannot be used when referencing StepActions using [v1.Step.Ref].
64946496
The Results declared by the StepActions will be stored here instead.
64956497
type: array
64966498
items:
6497-
description: |-
6498-
StepResult used to describe the Results of a Step.
6499-
6500-
This is field is at an BETA stability level and gated by "enable-step-actions" feature flag.
6499+
description: StepResult used to describe the Results of a Step.
65016500
type: object
65026501
required:
65036502
- name

config/config-feature-flags.yaml

+2-3
Original file line numberDiff line numberDiff line change
@@ -113,9 +113,6 @@ data:
113113
keep-pod-on-cancel: "false"
114114
# Setting this flag to "true" will enable the CEL evaluation in WhenExpression
115115
enable-cel-in-whenexpression: "false"
116-
# Setting this flag to "true" will enable the use of StepActions in Steps
117-
# This feature is in preview mode and not implemented yet. Please check #7259 for updates.
118-
enable-step-actions: "false"
119116
# Setting this flag to "true" will enable the use of Artifacts in Steps
120117
# This feature is in preview mode and not implemented yet. Please check #7693 for updates.
121118
enable-artifacts: "false"
@@ -131,3 +128,5 @@ data:
131128
enable-concise-resolver-syntax: "false"
132129
# Setthing this flag to "true" will enable native Kubernetes Sidecar support
133130
enable-kubernetes-sidecar: "false"
131+
# Setting this flag to "false" will have no effect since StepActions are a stable feature
132+
enable-step-actions: "true"

docs/additional-configs.md

+1-2
Original file line numberDiff line numberDiff line change
@@ -391,15 +391,14 @@ Features currently in "beta" are:
391391
| [Isolated `Step` & `Sidecar` `Workspaces`](./workspaces.md#isolated-workspaces) | [TEP-0029](https://github.com/tektoncd/community/blob/main/teps/0029-step-workspaces.md) | [v0.24.0](https://github.com/tektoncd/pipeline/releases/tag/v0.24.0) | [v0.50.0](https://github.com/tektoncd/pipeline/releases/tag/v0.50.0) | |
392392
| [Matrix](./matrix.md) | [TEP-0090](https://github.com/tektoncd/community/blob/main/teps/0090-matrix.md) | [v0.38.0](https://github.com/tektoncd/pipeline/releases/tag/v0.38.0) | [v0.53.0](https://github.com/tektoncd/pipeline/releases/tag/v0.53.0) | |
393393
| [Task-level Resource Requirements](compute-resources.md#task-level-compute-resources-configuration) | [TEP-0104](https://github.com/tektoncd/community/blob/main/teps/0104-tasklevel-resource-requirements.md) | [v0.39.0](https://github.com/tektoncd/pipeline/releases/tag/v0.39.0) | [v0.53.0](https://github.com/tektoncd/pipeline/releases/tag/v0.53.0) | |
394-
| [Reusable Steps via StepActions](./stepactions.md) | [TEP-0142](https://github.com/tektoncd/community/blob/main/teps/0142-enable-step-reusability.md) | [v0.54.0](https://github.com/tektoncd/pipeline/releases/tag/v0.54.0) | `enable-step-actions` |
395394
| [Larger Results via Sidecar Logs](#enabling-larger-results-using-sidecar-logs) | [TEP-0127](https://github.com/tektoncd/community/blob/main/teps/0127-larger-results-via-sidecar-logs.md) | [v0.43.0](https://github.com/tektoncd/pipeline/releases/tag/v0.43.0) | [v0.61.0](https://github.com/tektoncd/pipeline/releases/tag/v0.61.0) | `results-from` |
396395
| [Step and Sidecar Overrides](./taskruns.md#overriding-task-steps-and-sidecars) | [TEP-0094](https://github.com/tektoncd/community/blob/main/teps/0094-specifying-resource-requirements-at-runtime.md) | [v0.34.0](https://github.com/tektoncd/pipeline/releases/tag/v0.34.0) | | [v0.61.0](https://github.com/tektoncd/pipeline/releases/tag/v0.61.0) | |
397396
| [Ignore Task Failure](./pipelines.md#using-the-onerror-field) | [TEP-0050](https://github.com/tektoncd/community/blob/main/teps/0050-ignore-task-failures.md) | [v0.55.0](https://github.com/tektoncd/pipeline/releases/tag/v0.55.0) | [v0.62.0](https://github.com/tektoncd/pipeline/releases/tag/v0.62.0) | N/A |
398397

399398
## Enabling larger results using sidecar logs
400399

401400
**Note**: The maximum size of a Task's results is limited by the container termination message feature of Kubernetes,
402-
as results are passed back to the controller via this mechanism. At present, the limit is per task is 4096 bytes. All
401+
as results are passed back to the controller via this mechanism. At present, the limit is per task is "4096 bytes". All
403402
results produced by the task share this upper limit.
404403

405404
To exceed this limit of 4096 bytes, you can enable larger results using sidecar logs. By enabling this feature, you will

docs/pipeline-api.md

-3
Original file line numberDiff line numberDiff line change
@@ -4680,7 +4680,6 @@ Params
46804680
<td>
46814681
<em>(Optional)</em>
46824682
<p>Results declares StepResults produced by the Step.</p>
4683-
<p>This is field is at an ALPHA stability level and gated by &ldquo;enable-step-actions&rdquo; feature flag.</p>
46844683
<p>It can be used in an inlined Step when used to store Results to $(step.results.resultName.path).
46854684
It cannot be used when referencing StepActions using [v1.Step.Ref].
46864685
The Results declared by the StepActions will be stored here instead.</p>
@@ -4739,7 +4738,6 @@ string
47394738
</p>
47404739
<div>
47414740
<p>StepResult used to describe the Results of a Step.</p>
4742-
<p>This is field is at an BETA stability level and gated by &ldquo;enable-step-actions&rdquo; feature flag.</p>
47434741
</div>
47444742
<table>
47454743
<thead>
@@ -13977,7 +13975,6 @@ Params
1397713975
<td>
1397813976
<em>(Optional)</em>
1397913977
<p>Results declares StepResults produced by the Step.</p>
13980-
<p>This is field is at an ALPHA stability level and gated by &ldquo;enable-step-actions&rdquo; feature flag.</p>
1398113978
<p>It can be used in an inlined Step when used to store Results to $(step.results.resultName.path).
1398213979
It cannot be used when referencing StepActions using [v1beta1.Step.Ref].
1398313980
The Results declared by the StepActions will be stored here instead.</p>

docs/stepactions.md

+1-3
Original file line numberDiff line numberDiff line change
@@ -20,8 +20,7 @@ weight: 201
2020
- [Specifying Remote StepActions](#specifying-remote-stepactions)
2121

2222
## Overview
23-
> :seedling: **`StepActions` is an [beta](additional-configs.md#beta-features) feature.**
24-
> The `enable-step-actions` feature flag must be set to `"true"` to specify a `StepAction` in a `Step`.
23+
> **`StepActions` is a stable feature.**
2524
2625
A `StepAction` is the reusable and scriptable unit of work that is performed by a `Step`.
2726

@@ -417,7 +416,6 @@ status:
417416
podName: step-action-run-pod
418417
provenance:
419418
featureFlags:
420-
EnableStepActions: true
421419
...
422420
startTime: "2023-10-24T20:28:32Z"
423421
steps:

pkg/apis/config/feature_flags.go

+9-18
Original file line numberDiff line numberDiff line change
@@ -97,8 +97,6 @@ const (
9797
KeepPodOnCancel = "keep-pod-on-cancel"
9898
// EnableCELInWhenExpression is the flag to enabled CEL in WhenExpression
9999
EnableCELInWhenExpression = "enable-cel-in-whenexpression"
100-
// EnableStepActions is the flag to enable the use of StepActions in Steps
101-
EnableStepActions = "enable-step-actions"
102100
// EnableArtifacts is the flag to enable the use of Artifacts in Steps
103101
EnableArtifacts = "enable-artifacts"
104102
// EnableParamEnum is the flag to enabled enum in params
@@ -109,6 +107,8 @@ const (
109107
EnableKubernetesSidecar = "enable-kubernetes-sidecar"
110108
// DefaultEnableKubernetesSidecar is the default value for EnableKubernetesSidecar
111109
DefaultEnableKubernetesSidecar = false
110+
// EnableStepActions is the flag to enable step actions (no-op since it's stable)
111+
EnableStepActions = "enable-step-actions"
112112

113113
// DisableInlineSpec is the flag to disable embedded spec
114114
// in Taskrun or Pipelinerun
@@ -150,13 +150,6 @@ var (
150150
Enabled: DefaultAlphaFeatureEnabled,
151151
}
152152

153-
// DefaultEnableStepActions is the default PerFeatureFlag value for EnableStepActions
154-
DefaultEnableStepActions = PerFeatureFlag{
155-
Name: EnableStepActions,
156-
Stability: BetaAPIFields,
157-
Enabled: DefaultBetaFeatureEnabled,
158-
}
159-
160153
// DefaultEnableArtifacts is the default PerFeatureFlag value for EnableArtifacts
161154
DefaultEnableArtifacts = PerFeatureFlag{
162155
Name: EnableArtifacts,
@@ -204,12 +197,13 @@ type FeatureFlags struct {
204197
SetSecurityContextReadOnlyRootFilesystem bool `json:"setSecurityContextReadOnlyRootFilesystem,omitempty"`
205198
Coschedule string `json:"coschedule,omitempty"`
206199
EnableCELInWhenExpression bool `json:"enableCELInWhenExpression,omitempty"`
207-
EnableStepActions bool `json:"enableStepActions,omitempty"`
208-
EnableParamEnum bool `json:"enableParamEnum,omitempty"`
209-
EnableArtifacts bool `json:"enableArtifacts,omitempty"`
210-
DisableInlineSpec string `json:"disableInlineSpec,omitempty"`
211-
EnableConciseResolverSyntax bool `json:"enableConciseResolverSyntax,omitempty"`
212-
EnableKubernetesSidecar bool `json:"enableKubernetesSidecar,omitempty"`
200+
// EnableStepActions is a no-op flag since StepActions are stable
201+
EnableStepActions bool `json:"enableStepActions,omitempty"`
202+
EnableParamEnum bool `json:"enableParamEnum,omitempty"`
203+
EnableArtifacts bool `json:"enableArtifacts,omitempty"`
204+
DisableInlineSpec string `json:"disableInlineSpec,omitempty"`
205+
EnableConciseResolverSyntax bool `json:"enableConciseResolverSyntax,omitempty"`
206+
EnableKubernetesSidecar bool `json:"enableKubernetesSidecar,omitempty"`
213207
}
214208

215209
// GetFeatureFlagsConfigName returns the name of the configmap containing all
@@ -298,9 +292,6 @@ func NewFeatureFlagsFromMap(cfgMap map[string]string) (*FeatureFlags, error) {
298292
if err := setPerFeatureFlag(EnableCELInWhenExpression, DefaultEnableCELInWhenExpression, &tc.EnableCELInWhenExpression); err != nil {
299293
return nil, err
300294
}
301-
if err := setPerFeatureFlag(EnableStepActions, DefaultEnableStepActions, &tc.EnableStepActions); err != nil {
302-
return nil, err
303-
}
304295
if err := setPerFeatureFlag(EnableParamEnum, DefaultEnableParamEnum, &tc.EnableParamEnum); err != nil {
305296
return nil, err
306297
}

0 commit comments

Comments
 (0)