-
Notifications
You must be signed in to change notification settings - Fork 159
Expand file tree
/
Copy pathsqlc.yaml
More file actions
122 lines (122 loc) · 4.89 KB
/
sqlc.yaml
File metadata and controls
122 lines (122 loc) · 4.89 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
version: "2"
sql:
- engine: "postgresql"
queries: "pkg/database/postgres/queries/*.sql"
schema: "pkg/database/postgres/migrations"
gen:
go:
package: "sqlc"
out: "pkg/database/postgres/sqlc"
emit_db_tags: true
emit_json_tags: true
sql_package: "pgx/v5"
overrides:
- db_type: "uuid"
go_type:
import: "github.com/google/uuid"
type: "UUID"
- column: "blub.bar"
go_type:
type: "Bar"
slice: true
# Use SQLC for jsonb parsing instead of doing it all manually
- engine: "postgresql"
queries: "pkg/controlplane/scheduling/sqlc/*.sql"
schema: "pkg/database/postgres/migrations"
gen:
go:
package: "sqlc"
out: "pkg/controlplane/scheduling/sqlc"
emit_db_tags: true
emit_json_tags: true
sql_package: "pgx/v5"
overrides:
- db_type: "uuid"
go_type:
import: "github.com/google/uuid"
type: "UUID"
# section for test_workflow_executions
- column: "test_workflow_executions.runner_target"
go_type:
type: "ExecutionTarget"
import: "github.com/kubeshop/testkube/pkg/api/v1/testkube"
pointer: true
- column: "test_workflow_executions.runner_original_target"
go_type:
type: "ExecutionTarget"
import: "github.com/kubeshop/testkube/pkg/api/v1/testkube"
pointer: true
- column: "test_workflow_executions.tags"
go_type:
type: "map[string]string"
- column: "test_workflow_executions.running_context"
go_type:
type: "TestWorkflowRunningContext"
import: "github.com/kubeshop/testkube/pkg/api/v1/testkube"
pointer: true
- column: "test_workflow_executions.config_params"
go_type:
# Hacky - can only be used in tandem with another column that does the import.
type: "map[string]testkube.TestWorkflowExecutionConfigValue"
- column: "test_workflow_executions.runtime"
go_type:
type: "TestWorkflowExecutionRuntime"
import: "github.com/kubeshop/testkube/pkg/api/v1/testkube"
pointer: true
- column: "test_workflow_executions.silent_mode"
go_type:
type: "SilentMode"
import: "github.com/kubeshop/testkube/pkg/api/v1/testkube"
pointer: true
# section for test_workflows
- column: "test_workflows.labels"
go_type:
type: "map[string]string"
- column: "test_workflows.annotations"
go_type:
type: "map[string]string"
- column: "test_workflows.spec"
go_type:
type: "TestWorkflowSpec"
import: "github.com/kubeshop/testkube/pkg/api/v1/testkube"
pointer: true
- column: "test_workflows.status"
go_type:
type: "TestWorkflowStatusSummary"
import: "github.com/kubeshop/testkube/pkg/api/v1/testkube"
pointer: true
# section for test_workflow_results
- column: "test_workflow_results.pauses"
go_type:
type: "TestWorkflowPause"
import: "github.com/kubeshop/testkube/pkg/api/v1/testkube"
slice: true
- column: "test_workflow_results.initialization"
go_type:
type: "TestWorkflowStepResult"
import: "github.com/kubeshop/testkube/pkg/api/v1/testkube"
pointer: true
- column: "test_workflow_results.steps"
go_type:
# Hacky - can only be used in tandem with another column that does the import.
type: "map[string]testkube.TestWorkflowStepResult"
# section for test_workflow_outputs
- column: "test_workflow_outputs.value"
go_type:
type: "map[string]interface{}"
# section for test_workflow_reports
- column: "test_workflow_reports.summary"
go_type:
type: "TestWorkflowReportSummary"
import: "github.com/kubeshop/testkube/pkg/api/v1/testkube"
pointer: true
# section for test_workflow_resource_aggregations
- column: "test_workflow_resource_aggregations.global"
go_type:
# Hacky - can only be used in tandem with another column that does the import.
type: "map[string]map[string]testkube.TestWorkflowExecutionResourceAggregations"
- column: "test_workflow_resource_aggregations.step"
go_type:
type: "TestWorkflowExecutionStepResourceAggregations"
import: "github.com/kubeshop/testkube/pkg/api/v1/testkube"
slice: true