-
Notifications
You must be signed in to change notification settings - Fork 1.8k
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
Update API spec doc to reflect the new fields introduced from TEP75&76 #5511
Conversation
@Yongxuanzhang Please take a look. Let me know if I miss anything. Thanks |
/kind doc |
@chuangw6: The label(s) In response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
/kind documentation |
/approve |
I don't think we want to mark array results and object params + results as required for conformance especially since these fields are still in alpha. TEP-0012 says that we may add "an optional process to very mature supported features, to potentially mark them as required by the spec", and TEP-0033 states that "Fields should not be added to the Tekton conformance surface until they are promoted to the same stability level as the CRD impacted". This doc also states that "In general a resource or field should not be added as REQUIRED directly, as this may cause unsuspecting previously-conformant implementations to suddenly no longer be conformant". Maybe "recommended" would be better. |
Thanks for the pointers @lbernick ! We are not marking specifically array result, object param + result as required. It's the |
If supporting "type" is required, doesn't that imply that supporting object params + results is required? It wouldn't make sense to allow users to define a "type" but have it not do anything. Unless the only "type" value that is required to be supported is type string? This is making me realize that for enum fields, we probably need to specify which values of the enum should be supported, rather than specifying conformance requirements for the field as a whole.
This is a detail of our current implementation of the Tekton API, but the conformance spec dictates what fields all implementations must support.
I think "description" and "default" have been around for much longer and we are much more confident in the stability of those fields. Since we already have these fields as required, I don't see a good reason to downgrade them to "recommended". |
a9b7a9a
to
d7e80a3
Compare
@lbernick I see. I've updated to mark the type field in |
Implementation of TEP75&76 supported object type param, object type result and array type result, which introduced some changes to the API spec i.e. `ParamSpec`, `TaskResult` and `TaskRunResult`. This PR updates the doc to reflect the changes. Signed-off-by: Chuang Wang <[email protected]>
d7e80a3
to
a714e0c
Compare
|
||
### `TaskRunResult` | ||
|
||
| Field Name | Field Type | Requirement | | ||
|------------|------------|-------------| | ||
| `name` | string | REQUIRED | | ||
| `value` | string | REQUIRED | | ||
| `type` | Enum:<br>- `"string"` (default)<br>- `"array"` <br>- `"object"` | RECOMMENDED (Each of the values is RECOMMENDED.) | | ||
| `value` | `ParamValue` | REQUIRED | |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
it's a bit unfortunate that we're changing the type of a required field but since we only have one primary implementation of tekton currently it's probably OK?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I guess so because it's a backward compatible change. String type result is still supported as the way it was supported before.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just to clarify, if there were other implementations of the Tekton API, this would be a problem. The reason is that they might support the field "value" as a string, but with this change they are "required" to support value as a "ParamValue". This would mean an implementation that was previously conformant would not be conformant after this change. But since we have one main implementation, it doesn't matter too much.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the clarification!
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: abayer, lbernick The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
/lgtm since andrew previously approved. |
/lgtm |
/test check-pr-has-kind-label |
@chuangw6: The specified target(s) for
The following commands are available to trigger optional jobs:
Use In response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
/retest |
Changes
Implementation of TEP75&76 supported object type param, object type result and array type result, which introduced some changes to the API spec i.e.
ParamSpec
,TaskResult
andTaskRunResult
.This PR updates the doc to reflect the changes.
Signed-off-by: Chuang Wang [email protected]
Submitter Checklist
As the author of this PR, please check off the items in this checklist:
functionality, content, code)
/kind <type>
. Valid types are bug, cleanup, design, documentation, feature, flake, misc, question, tepRelease Notes