Skip to content

Commit

Permalink
feat: add status field to artifacts (#4909)
Browse files Browse the repository at this point in the history
  • Loading branch information
povilasv authored Jan 18, 2024
1 parent b9a4211 commit 3e2aaad
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 1 deletion.
8 changes: 7 additions & 1 deletion api/v1/testkube.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4306,6 +4306,12 @@ components:
type: string
description: execution name that produced the artifact
example: "test-1"
status:
type: string
enum:
- ready
- processing
- failed

ExecutionsResult:
description: the result for a page of executions
Expand Down Expand Up @@ -6133,4 +6139,4 @@ components:
- execution
filePath:
type: string
example: folder/file.txt
example: folder/file.txt
1 change: 1 addition & 0 deletions pkg/api/v1/testkube/model_artifact.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,4 +17,5 @@ type Artifact struct {
Size int32 `json:"size,omitempty"`
// execution name that produced the artifact
ExecutionName string `json:"executionName,omitempty"`
Status string `json:"status,omitempty"`
}
3 changes: 3 additions & 0 deletions pkg/executor/scraper/extractor.go
Original file line number Diff line number Diff line change
Expand Up @@ -41,4 +41,7 @@ type FilesMeta struct {
type FileStat struct {
Name string `json:"name"`
Size int64 `json:"size"`
// Status shows if file is ready to be downloaded
// One of: ready, processing, error
Status string `json:"status,omitempty"`
}

0 comments on commit 3e2aaad

Please sign in to comment.