Currently doc mix-use Result UID as both name and UID of result. The terminology should be sorted out, otherwise users may get confused.
About terminology
name of Result
Here result name refer to the name decided by the clients of Results API Server. And (from implementation aspect) currently Watcher use Taskrun/Pipelinerun UID as result name.
UID of Result
UID refer to the id decided by Results API Server when inserting Result object.
Actual Behavior
While GetResultRequest needs specifying result name to query Result, OpenAPI document that get /v1alpha2/parents/{parent}/results/{result_uid} get a single result given the UID.
There are also same wrong description about update, delete of Result
GRPC service definition:
rpc GetResult(GetResultRequest) returns (Result) {
option (google.api.http) = {
get: "/apis/results.tekton.dev/v1alpha2/parents/{name=*/results/*}"
};
}
message GetResultRequest {
string name = 1 [
(google.api.field_behavior) = REQUIRED,
(google.api.resource_reference) = {
type: "tekton.results.v1alpha2/Result"
}];
}
OpenAPI doc:
/v1alpha2/parents/{parent}/results/{result_uid}:
summary: Get, Create, Delete or update result
get:
tags:
- Results
responses:
"200":
content:
application/json:
schema:
$ref: "#/components/schemas/Result"
description: Default response
operationId: get_result_by_uid
summary: Get a single result given the UID
description: ""
Expected Behavior
OpenAPI summary of get /v1alpha2/parents/{parent}/results/{result_uid} change Get a single result given the UID to Get a single result given name and so on.
Steps to Reproduce the Problem
Additional Info
-
Kubernetes version:
Output of kubectl version:
-
Tekton Pipeline version:
Output of tkn version or kubectl get pods -n tekton-pipelines -l app=tekton-pipelines-controller -o=jsonpath='{.items[0].metadata.labels.version}'
-
Tekton Results version:
current main branch
Currently doc mix-use Result UID as both name and UID of result. The terminology should be sorted out, otherwise users may get confused.
About terminology
name of
ResultHere result
namerefer to the name decided by the clients of Results API Server. And (from implementation aspect) currently Watcher useTaskrun/PipelinerunUID as resultname.UID of
ResultUIDrefer to the id decided by Results API Server when insertingResultobject.Actual Behavior
While
GetResultRequestneeds specifying result name to queryResult, OpenAPI document thatget /v1alpha2/parents/{parent}/results/{result_uid}get a single result given the UID.There are also same wrong description about update, delete of
ResultGRPC service definition:
OpenAPI doc:
Expected Behavior
OpenAPI
summaryofget /v1alpha2/parents/{parent}/results/{result_uid}changeGet a single result given the UIDtoGet a single result given nameand so on.Steps to Reproduce the Problem
Additional Info
Kubernetes version:
Output of
kubectl version:Tekton Pipeline version:
Output of
tkn versionorkubectl get pods -n tekton-pipelines -l app=tekton-pipelines-controller -o=jsonpath='{.items[0].metadata.labels.version}'Tekton Results version:
current
mainbranch