mirror of
https://github.com/onepanelio/onepanel.git
synced 2025-09-27 01:56:03 +08:00
Merge branch 'feat/core.144-workflow.stats' into feat/dev-core-144-workflow.stats
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
FROM golang:1.13.8 AS builder
|
||||
FROM golang:1.13.10 AS builder
|
||||
|
||||
WORKDIR /go/src
|
||||
COPY . .
|
||||
@@ -7,7 +7,7 @@ RUN go get -d -v ./...
|
||||
RUN go install -v ./...
|
||||
|
||||
|
||||
FROM golang:1.13.8
|
||||
FROM golang:1.13.10
|
||||
COPY --from=builder /go/bin/core .
|
||||
COPY --from=builder /go/src/db ./db
|
||||
|
||||
|
@@ -1144,6 +1144,44 @@
|
||||
]
|
||||
}
|
||||
},
|
||||
"/apis/v1beta1/{namespace}/workflow_executions/{name}/statistics": {
|
||||
"post": {
|
||||
"operationId": "AddWorkflowExecutionStatistics",
|
||||
"responses": {
|
||||
"200": {
|
||||
"description": "A successful response.",
|
||||
"schema": {
|
||||
"properties": {}
|
||||
}
|
||||
}
|
||||
},
|
||||
"parameters": [
|
||||
{
|
||||
"name": "namespace",
|
||||
"in": "path",
|
||||
"required": true,
|
||||
"type": "string"
|
||||
},
|
||||
{
|
||||
"name": "name",
|
||||
"in": "path",
|
||||
"required": true,
|
||||
"type": "string"
|
||||
},
|
||||
{
|
||||
"name": "body",
|
||||
"in": "body",
|
||||
"required": true,
|
||||
"schema": {
|
||||
"$ref": "#/definitions/Statistics"
|
||||
}
|
||||
}
|
||||
],
|
||||
"tags": [
|
||||
"WorkflowService"
|
||||
]
|
||||
}
|
||||
},
|
||||
"/apis/v1beta1/{namespace}/workflow_executions/{name}/terminate": {
|
||||
"put": {
|
||||
"operationId": "TerminateWorkflowExecution",
|
||||
@@ -1288,6 +1326,40 @@
|
||||
"required": false,
|
||||
"type": "integer",
|
||||
"format": "int32"
|
||||
},
|
||||
{
|
||||
"name": "stats.total",
|
||||
"in": "query",
|
||||
"required": false,
|
||||
"type": "integer",
|
||||
"format": "int32"
|
||||
},
|
||||
{
|
||||
"name": "stats.lastExecuted",
|
||||
"in": "query",
|
||||
"required": false,
|
||||
"type": "string"
|
||||
},
|
||||
{
|
||||
"name": "stats.running",
|
||||
"in": "query",
|
||||
"required": false,
|
||||
"type": "integer",
|
||||
"format": "int32"
|
||||
},
|
||||
{
|
||||
"name": "stats.completed",
|
||||
"in": "query",
|
||||
"required": false,
|
||||
"type": "integer",
|
||||
"format": "int32"
|
||||
},
|
||||
{
|
||||
"name": "stats.failed",
|
||||
"in": "query",
|
||||
"required": false,
|
||||
"type": "integer",
|
||||
"format": "int32"
|
||||
}
|
||||
],
|
||||
"tags": [
|
||||
@@ -2057,6 +2129,21 @@
|
||||
}
|
||||
}
|
||||
},
|
||||
"Statistics": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"workflowStatus": {
|
||||
"type": "string"
|
||||
},
|
||||
"createdAt": {
|
||||
"type": "string"
|
||||
},
|
||||
"workflowTemplateId": {
|
||||
"type": "string",
|
||||
"format": "int64"
|
||||
}
|
||||
}
|
||||
},
|
||||
"TokenWrapper": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
@@ -2126,6 +2213,30 @@
|
||||
}
|
||||
}
|
||||
},
|
||||
"WorkflowExecutionStatisticReport": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"total": {
|
||||
"type": "integer",
|
||||
"format": "int32"
|
||||
},
|
||||
"lastExecuted": {
|
||||
"type": "string"
|
||||
},
|
||||
"running": {
|
||||
"type": "integer",
|
||||
"format": "int32"
|
||||
},
|
||||
"completed": {
|
||||
"type": "integer",
|
||||
"format": "int32"
|
||||
},
|
||||
"failed": {
|
||||
"type": "integer",
|
||||
"format": "int32"
|
||||
}
|
||||
}
|
||||
},
|
||||
"WorkflowTemplate": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
@@ -2158,6 +2269,9 @@
|
||||
"items": {
|
||||
"$ref": "#/definitions/KeyValue"
|
||||
}
|
||||
},
|
||||
"stats": {
|
||||
"$ref": "#/definitions/WorkflowExecutionStatisticReport"
|
||||
}
|
||||
}
|
||||
},
|
||||
|
@@ -1048,6 +1048,116 @@ func (m *ListFilesResponse) GetParentPath() string {
|
||||
return ""
|
||||
}
|
||||
|
||||
type Statistics struct {
|
||||
WorkflowStatus string `protobuf:"bytes,1,opt,name=workflowStatus,proto3" json:"workflowStatus,omitempty"`
|
||||
CreatedAt string `protobuf:"bytes,2,opt,name=createdAt,proto3" json:"createdAt,omitempty"`
|
||||
WorkflowTemplateId int64 `protobuf:"varint,3,opt,name=workflowTemplateId,proto3" json:"workflowTemplateId,omitempty"`
|
||||
XXX_NoUnkeyedLiteral struct{} `json:"-"`
|
||||
XXX_unrecognized []byte `json:"-"`
|
||||
XXX_sizecache int32 `json:"-"`
|
||||
}
|
||||
|
||||
func (m *Statistics) Reset() { *m = Statistics{} }
|
||||
func (m *Statistics) String() string { return proto.CompactTextString(m) }
|
||||
func (*Statistics) ProtoMessage() {}
|
||||
func (*Statistics) Descriptor() ([]byte, []int) {
|
||||
return fileDescriptor_892c7f566756b0be, []int{18}
|
||||
}
|
||||
|
||||
func (m *Statistics) XXX_Unmarshal(b []byte) error {
|
||||
return xxx_messageInfo_Statistics.Unmarshal(m, b)
|
||||
}
|
||||
func (m *Statistics) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
|
||||
return xxx_messageInfo_Statistics.Marshal(b, m, deterministic)
|
||||
}
|
||||
func (m *Statistics) XXX_Merge(src proto.Message) {
|
||||
xxx_messageInfo_Statistics.Merge(m, src)
|
||||
}
|
||||
func (m *Statistics) XXX_Size() int {
|
||||
return xxx_messageInfo_Statistics.Size(m)
|
||||
}
|
||||
func (m *Statistics) XXX_DiscardUnknown() {
|
||||
xxx_messageInfo_Statistics.DiscardUnknown(m)
|
||||
}
|
||||
|
||||
var xxx_messageInfo_Statistics proto.InternalMessageInfo
|
||||
|
||||
func (m *Statistics) GetWorkflowStatus() string {
|
||||
if m != nil {
|
||||
return m.WorkflowStatus
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
func (m *Statistics) GetCreatedAt() string {
|
||||
if m != nil {
|
||||
return m.CreatedAt
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
func (m *Statistics) GetWorkflowTemplateId() int64 {
|
||||
if m != nil {
|
||||
return m.WorkflowTemplateId
|
||||
}
|
||||
return 0
|
||||
}
|
||||
|
||||
type AddWorkflowExecutionStatisticRequest struct {
|
||||
Namespace string `protobuf:"bytes,1,opt,name=namespace,proto3" json:"namespace,omitempty"`
|
||||
Name string `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty"`
|
||||
Statistics *Statistics `protobuf:"bytes,3,opt,name=statistics,proto3" json:"statistics,omitempty"`
|
||||
XXX_NoUnkeyedLiteral struct{} `json:"-"`
|
||||
XXX_unrecognized []byte `json:"-"`
|
||||
XXX_sizecache int32 `json:"-"`
|
||||
}
|
||||
|
||||
func (m *AddWorkflowExecutionStatisticRequest) Reset() { *m = AddWorkflowExecutionStatisticRequest{} }
|
||||
func (m *AddWorkflowExecutionStatisticRequest) String() string { return proto.CompactTextString(m) }
|
||||
func (*AddWorkflowExecutionStatisticRequest) ProtoMessage() {}
|
||||
func (*AddWorkflowExecutionStatisticRequest) Descriptor() ([]byte, []int) {
|
||||
return fileDescriptor_892c7f566756b0be, []int{19}
|
||||
}
|
||||
|
||||
func (m *AddWorkflowExecutionStatisticRequest) XXX_Unmarshal(b []byte) error {
|
||||
return xxx_messageInfo_AddWorkflowExecutionStatisticRequest.Unmarshal(m, b)
|
||||
}
|
||||
func (m *AddWorkflowExecutionStatisticRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
|
||||
return xxx_messageInfo_AddWorkflowExecutionStatisticRequest.Marshal(b, m, deterministic)
|
||||
}
|
||||
func (m *AddWorkflowExecutionStatisticRequest) XXX_Merge(src proto.Message) {
|
||||
xxx_messageInfo_AddWorkflowExecutionStatisticRequest.Merge(m, src)
|
||||
}
|
||||
func (m *AddWorkflowExecutionStatisticRequest) XXX_Size() int {
|
||||
return xxx_messageInfo_AddWorkflowExecutionStatisticRequest.Size(m)
|
||||
}
|
||||
func (m *AddWorkflowExecutionStatisticRequest) XXX_DiscardUnknown() {
|
||||
xxx_messageInfo_AddWorkflowExecutionStatisticRequest.DiscardUnknown(m)
|
||||
}
|
||||
|
||||
var xxx_messageInfo_AddWorkflowExecutionStatisticRequest proto.InternalMessageInfo
|
||||
|
||||
func (m *AddWorkflowExecutionStatisticRequest) GetNamespace() string {
|
||||
if m != nil {
|
||||
return m.Namespace
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
func (m *AddWorkflowExecutionStatisticRequest) GetName() string {
|
||||
if m != nil {
|
||||
return m.Name
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
func (m *AddWorkflowExecutionStatisticRequest) GetStatistics() *Statistics {
|
||||
if m != nil {
|
||||
return m.Statistics
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
func init() {
|
||||
proto.RegisterType((*CreateWorkflowExecutionRequest)(nil), "api.CreateWorkflowExecutionRequest")
|
||||
proto.RegisterType((*GetWorkflowExecutionRequest)(nil), "api.GetWorkflowExecutionRequest")
|
||||
@@ -1067,95 +1177,104 @@ func init() {
|
||||
proto.RegisterType((*File)(nil), "api.File")
|
||||
proto.RegisterType((*ListFilesRequest)(nil), "api.ListFilesRequest")
|
||||
proto.RegisterType((*ListFilesResponse)(nil), "api.ListFilesResponse")
|
||||
proto.RegisterType((*Statistics)(nil), "api.Statistics")
|
||||
proto.RegisterType((*AddWorkflowExecutionStatisticRequest)(nil), "api.AddWorkflowExecutionStatisticRequest")
|
||||
}
|
||||
|
||||
func init() { proto.RegisterFile("workflow.proto", fileDescriptor_892c7f566756b0be) }
|
||||
|
||||
var fileDescriptor_892c7f566756b0be = []byte{
|
||||
// 1326 bytes of a gzipped FileDescriptorProto
|
||||
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xb4, 0x57, 0xcd, 0x6f, 0xdc, 0x44,
|
||||
0x14, 0x97, 0xb3, 0x49, 0x9b, 0x7d, 0x69, 0x21, 0x19, 0xda, 0x64, 0xeb, 0xa6, 0x69, 0x98, 0x7e,
|
||||
0x10, 0x55, 0x22, 0x6e, 0xcb, 0x87, 0x50, 0x69, 0x29, 0x69, 0x9a, 0x84, 0xaa, 0x29, 0x2d, 0x6e,
|
||||
0xfa, 0x71, 0x43, 0x93, 0xf5, 0x6c, 0x62, 0xc5, 0x6b, 0x1b, 0xcf, 0x6c, 0xd3, 0x25, 0xca, 0x05,
|
||||
0x71, 0xe0, 0x84, 0x90, 0x7a, 0x41, 0x3d, 0x81, 0xc4, 0xdf, 0xc1, 0x09, 0x24, 0xee, 0x9c, 0x10,
|
||||
0x57, 0xfe, 0x02, 0xfe, 0x02, 0x34, 0x6f, 0xc6, 0x5e, 0x6f, 0xd6, 0xde, 0xb4, 0x9b, 0x70, 0xf2,
|
||||
0xcc, 0x7b, 0x33, 0xef, 0xfd, 0xe6, 0x7d, 0x1b, 0xde, 0xd8, 0x8e, 0x92, 0xad, 0x46, 0x10, 0x6d,
|
||||
0xcf, 0xc7, 0x49, 0x24, 0x23, 0x52, 0x61, 0xb1, 0x6f, 0x4f, 0x6f, 0x44, 0xd1, 0x46, 0xc0, 0x1d,
|
||||
0x16, 0xfb, 0x0e, 0x0b, 0xc3, 0x48, 0x32, 0xe9, 0x47, 0xa1, 0xd0, 0x47, 0xec, 0xd3, 0x86, 0x8b,
|
||||
0xbb, 0xf5, 0x56, 0xc3, 0xe1, 0xcd, 0x58, 0xb6, 0x0d, 0x73, 0x2a, 0x95, 0xf7, 0xa5, 0xe4, 0xcd,
|
||||
0x38, 0x60, 0x92, 0x1b, 0xc6, 0xb1, 0x26, 0x97, 0x89, 0x5f, 0x37, 0xbb, 0xb1, 0x80, 0xad, 0xf3,
|
||||
0x40, 0x6f, 0xe8, 0xb7, 0x16, 0xcc, 0x2c, 0x26, 0x9c, 0x49, 0x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0x48, 0x46, 0x50, 0x81, 0xa3, 0x22, 0x94, 0x87, 0xd2,
|
||||
0x38, 0x21, 0xdd, 0xd2, 0x7f, 0x87, 0x60, 0xa2, 0x07, 0xb7, 0x92, 0x56, 0xc7, 0x3a, 0xec, 0x2d,
|
||||
0xc8, 0x54, 0x5a, 0x46, 0x50, 0x65, 0xa8, 0x95, 0xb9, 0x53, 0x2d, 0xb3, 0x60, 0xad, 0xe4, 0x82,
|
||||
0x55, 0xbd, 0x69, 0x93, 0x89, 0x34, 0x45, 0xf4, 0x46, 0x49, 0x16, 0x92, 0x25, 0x5a, 0xf2, 0x88,
|
||||
0x96, 0x9c, 0x11, 0xd4, 0x8b, 0x1b, 0x7e, 0xe8, 0x8b, 0x4d, 0x64, 0x1f, 0x41, 0x76, 0x8e, 0xa2,
|
||||
0x9c, 0xdd, 0x64, 0xa1, 0xdf, 0xe0, 0x42, 0xd6, 0x8e, 0x22, 0x37, 0xdb, 0x93, 0x9b, 0x00, 0x31,
|
||||
0x4b, 0x58, 0x93, 0x4b, 0x9e, 0x88, 0xda, 0x28, 0xfa, 0xe5, 0x6c, 0xb1, 0x5f, 0x1e, 0xa4, 0xe7,
|
||||
0xdc, 0xdc, 0x15, 0xb2, 0x00, 0xe3, 0x7b, 0x83, 0xac, 0x56, 0xc5, 0xde, 0x71, 0xb2, 0x4b, 0x4c,
|
||||
0xca, 0x74, 0x7b, 0x8e, 0x93, 0x0b, 0x70, 0x04, 0xfb, 0x99, 0xa8, 0x01, 0xea, 0x3f, 0x8e, 0x17,
|
||||
0xef, 0xf2, 0xf6, 0x63, 0x16, 0xb4, 0xb8, 0x6b, 0x98, 0x74, 0x19, 0xec, 0x72, 0x4c, 0x99, 0x31,
|
||||
0xad, 0x6e, 0x63, 0x3e, 0x53, 0x22, 0x8c, 0xd1, 0xf5, 0x86, 0x5e, 0x84, 0xf1, 0x4e, 0x53, 0x31,
|
||||
0xc1, 0x4b, 0x60, 0xd8, 0x63, 0x92, 0xe1, 0xed, 0x63, 0x2e, 0xae, 0xe9, 0x6f, 0x16, 0x0c, 0x2f,
|
||||
0xfb, 0x81, 0x49, 0x08, 0xb9, 0x99, 0x8a, 0x56, 0xeb, 0xc2, 0x42, 0x33, 0x0d, 0x55, 0xfe, 0x5c,
|
||||
0xf2, 0x30, 0x97, 0x80, 0x1d, 0x82, 0xba, 0x21, 0xd2, 0x74, 0xab, 0xb8, 0xb8, 0x26, 0xb3, 0x30,
|
||||
0x66, 0x42, 0x6a, 0xad, 0x1d, 0x73, 0xe3, 0xd9, 0x3c, 0x89, 0x50, 0x38, 0x16, 0x30, 0x21, 0xef,
|
||||
0x45, 0x9e, 0xdf, 0xf0, 0xb9, 0x67, 0xbc, 0xdb, 0x45, 0x53, 0x7a, 0x3d, 0x3f, 0xe1, 0x75, 0x19,
|
||||
0x25, 0x6d, 0x74, 0xf0, 0xa8, 0xdb, 0x21, 0xd0, 0xa7, 0x30, 0xae, 0x32, 0x57, 0xbd, 0xe4, 0x00,
|
||||
0x45, 0x34, 0xb5, 0x41, 0xa5, 0x63, 0x03, 0xba, 0x06, 0x13, 0x39, 0xc9, 0xc6, 0x92, 0x67, 0x61,
|
||||
0xa4, 0xa1, 0x08, 0xa6, 0x54, 0x56, 0xd1, 0x97, 0xea, 0x88, 0xab, 0xe9, 0x2a, 0x5a, 0x63, 0x96,
|
||||
0xf0, 0x50, 0x3e, 0x50, 0xf2, 0xb4, 0x8e, 0x1c, 0xe5, 0xea, 0xdf, 0x13, 0xf0, 0x66, 0xea, 0xe7,
|
||||
0x87, 0x3c, 0x79, 0xe6, 0xd7, 0x39, 0xf9, 0xc9, 0x82, 0xa9, 0x92, 0x11, 0x87, 0x9c, 0x43, 0x0d,
|
||||
0xfd, 0x07, 0x20, 0xbb, 0xa4, 0xd4, 0xd0, 0xcf, 0xbe, 0xf9, 0xf3, 0x9f, 0x17, 0x43, 0xb7, 0xe8,
|
||||
0xbb, 0x6a, 0x58, 0x13, 0xce, 0xb3, 0x2b, 0xeb,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xa8, 0xd2, 0x6d, 0x2f, 0x78, 0x5e, 0x7f, 0x48, 0x0b, 0x9e, 0xf7, 0x6a, 0x90, 0xee,
|
||||
0x22, 0xa4, 0x25, 0x7a, 0x10, 0x48, 0xd7, 0xcc, 0x10, 0xa6, 0x3a, 0xf1, 0x8c, 0xcb, 0xe3, 0x80,
|
||||
0xd5, 0x79, 0x19, 0xbc, 0x53, 0x26, 0x33, 0xf1, 0xd0, 0x6b, 0x41, 0xb4, 0x0f, 0x05, 0xe2, 0x4b,
|
||||
0x0b, 0xa6, 0x6f, 0xf3, 0x80, 0xcb, 0x12, 0x84, 0x26, 0xfa, 0xf5, 0x11, 0xa4, 0xec, 0x07, 0xef,
|
||||
0x0e, 0xc2, 0x5b, 0xbc, 0xb4, 0x70, 0x00, 0x78, 0x18, 0xfb, 0xbb, 0xeb, 0x47, 0x30, 0xc3, 0xdf,
|
||||
0xfb, 0x2f, 0x00, 0x00, 0xff, 0xff, 0x30, 0x08, 0xdc, 0x84, 0x39, 0x12, 0x00, 0x00,
|
||||
// 1430 bytes of a gzipped FileDescriptorProto
|
||||
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xb4, 0x57, 0xcd, 0x6f, 0x1b, 0x45,
|
||||
0x14, 0xd7, 0xc4, 0x49, 0x9b, 0x3c, 0xb7, 0x34, 0x9d, 0xb6, 0x89, 0xbb, 0x4d, 0xd3, 0x30, 0xfd,
|
||||
0x20, 0x54, 0xc2, 0xdb, 0x86, 0x0f, 0xa1, 0xd0, 0x52, 0xd2, 0x34, 0x09, 0x55, 0x53, 0x5a, 0x36,
|
||||
0xe9, 0xc7, 0x0d, 0x4d, 0xec, 0x71, 0xb2, 0x8a, 0xbd, 0xbb, 0xec, 0x8c, 0x9b, 0x9a, 0x28, 0x97,
|
||||
0x8a, 0x03, 0x5c, 0x10, 0x52, 0x25, 0x84, 0x7a, 0x02, 0x89, 0x3f, 0x82, 0x13, 0x27, 0x90, 0xb8,
|
||||
0x73, 0xe2, 0xce, 0x5f, 0xc0, 0x5f, 0x80, 0xe6, 0xed, 0xec, 0x7a, 0x6d, 0xef, 0x3a, 0xad, 0x1b,
|
||||
0x4e, 0xbb, 0xf3, 0xde, 0xcc, 0x9b, 0xdf, 0xfb, 0x7e, 0x03, 0x6f, 0xec, 0xf8, 0xe1, 0x76, 0xad,
|
||||
0xee, 0xef, 0x94, 0x83, 0xd0, 0x57, 0x3e, 0x2d, 0xf0, 0xc0, 0xb5, 0xa6, 0x36, 0x7d, 0x7f, 0xb3,
|
||||
0x2e, 0x6c, 0x1e, 0xb8, 0x36, 0xf7, 0x3c, 0x5f, 0x71, 0xe5, 0xfa, 0x9e, 0x8c, 0xb6, 0x58, 0x67,
|
||||
0x0c, 0x17, 0x57, 0x1b, 0xcd, 0x9a, 0x2d, 0x1a, 0x81, 0x6a, 0x19, 0xe6, 0x64, 0x2c, 0xef, 0x0b,
|
||||
0x25, 0x1a, 0x41, 0x9d, 0x2b, 0x61, 0x18, 0x47, 0x1a, 0x42, 0x85, 0x6e, 0xc5, 0xac, 0x8a, 0x75,
|
||||
0xbe, 0x21, 0xea, 0xd1, 0x82, 0x7d, 0x4d, 0x60, 0x7a, 0x31, 0x14, 0x5c, 0x89, 0x47, 0xe6, 0xf0,
|
||||
0xd2, 0x53, 0x51, 0x69, 0xea, 0x3b, 0x1d, 0xf1, 0x65, 0x53, 0x48, 0x45, 0xa7, 0x60, 0xcc, 0xe3,
|
||||
0x0d, 0x21, 0x03, 0x5e, 0x11, 0x25, 0x32, 0x43, 0x66, 0xc7, 0x9c, 0x36, 0x81, 0xde, 0x82, 0xe3,
|
||||
0x3b, 0xdd, 0x27, 0x4b, 0x43, 0x33, 0x64, 0xb6, 0x38, 0x37, 0x51, 0xe6, 0x81, 0x5b, 0xee, 0x95,
|
||||
0xdb, 0x7b, 0x80, 0xdd, 0x83, 0x33, 0x2b, 0x42, 0x0d, 0x08, 0x81, 0xc2, 0xb0, 0x5e, 0xe0, 0xad,
|
||||
0x63, 0x0e, 0xfe, 0xb3, 0xc7, 0x40, 0x57, 0x84, 0x5a, 0x08, 0x95, 0x5b, 0xe3, 0x15, 0x35, 0xb0,
|
||||
0x1c, 0x3a, 0x0e, 0x85, 0x6d, 0xd1, 0x2a, 0x15, 0x90, 0xa4, 0x7f, 0xd9, 0xe7, 0x70, 0xf6, 0x11,
|
||||
0x57, 0x95, 0xad, 0x03, 0x04, 0xbb, 0x0e, 0x33, 0x8e, 0x90, 0xcd, 0x8d, 0x86, 0x7b, 0x90, 0x26,
|
||||
0x78, 0x00, 0x6f, 0xae, 0x8b, 0xb0, 0xe1, 0x7a, 0x83, 0x3b, 0x37, 0x4b, 0xec, 0x73, 0x02, 0xe7,
|
||||
0xb2, 0x7c, 0xb5, 0xea, 0x6f, 0xca, 0xc1, 0xed, 0x5c, 0x82, 0xc3, 0x81, 0x5f, 0xfd, 0x4c, 0x93,
|
||||
0x23, 0x5b, 0xc7, 0x4b, 0x7a, 0x01, 0x8e, 0x56, 0x7c, 0x4f, 0x71, 0xd7, 0x13, 0x21, 0xf2, 0x87,
|
||||
0x91, 0xdf, 0x49, 0x64, 0x01, 0xb0, 0x2c, 0x50, 0x77, 0x31, 0xf0, 0xff, 0x0f, 0x5c, 0x6c, 0x15,
|
||||
0xce, 0xf7, 0xbd, 0x51, 0x06, 0xbe, 0x27, 0x05, 0xbd, 0x08, 0x87, 0xa3, 0xec, 0x93, 0x25, 0x32,
|
||||
0x53, 0x98, 0x2d, 0xce, 0x15, 0x31, 0x2b, 0xa2, 0x6d, 0x4e, 0xcc, 0x63, 0x7f, 0x13, 0x38, 0xbb,
|
||||
0xea, 0xca, 0x5e, 0x79, 0x2f, 0x89, 0xfd, 0x0a, 0x9c, 0x88, 0xb3, 0x6a, 0xdd, 0x24, 0xff, 0x03,
|
||||
0xb7, 0x6a, 0x54, 0xc9, 0x62, 0xd1, 0x0f, 0x61, 0xb2, 0x9b, 0xfc, 0x50, 0x84, 0x52, 0x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 0x0b, 0xd9, 0x87, 0x90,
|
||||
0x9d, 0xa2, 0x68, 0x67, 0x37, 0xb8, 0xe7, 0xd6, 0x84, 0x54, 0xa5, 0xc3, 0xc8, 0x4d, 0xd6, 0xf4,
|
||||
0x06, 0x40, 0xc0, 0x43, 0xde, 0x10, 0x4a, 0x84, 0xb2, 0x34, 0x8a, 0x7e, 0x39, 0x97, 0xed, 0x97,
|
||||
0xfb, 0xf1, 0x3e, 0x27, 0x75, 0x84, 0x2e, 0xc0, 0x78, 0x77, 0x90, 0x95, 0xc6, 0xb0, 0x77, 0x9c,
|
||||
0xea, 0x10, 0x13, 0x33, 0x9d, 0x9e, 0xed, 0xf4, 0x22, 0x1c, 0xc2, 0x7e, 0x26, 0x4b, 0x80, 0xf7,
|
||||
0x1f, 0xc5, 0x83, 0x77, 0x44, 0xeb, 0x21, 0xaf, 0x37, 0x85, 0x63, 0x98, 0x6c, 0x19, 0xac, 0x7c,
|
||||
0x4c, 0x89, 0x31, 0x49, 0xa7, 0x31, 0x9f, 0x68, 0x11, 0xc6, 0xe8, 0xd1, 0x82, 0x5d, 0x82, 0xf1,
|
||||
0x76, 0x53, 0x31, 0xc1, 0x4b, 0x61, 0xb8, 0xca, 0x15, 0xc7, 0xd3, 0x47, 0x1c, 0xfc, 0x67, 0xbf,
|
||||
0x13, 0x18, 0x5e, 0x76, 0xeb, 0x26, 0x21, 0xd4, 0x56, 0x2c, 0x5a, 0xff, 0x67, 0x16, 0x9a, 0x29,
|
||||
0x18, 0x13, 0x4f, 0x95, 0xf0, 0x52, 0x09, 0xd8, 0x26, 0xe8, 0x13, 0x32, 0x4e, 0xb7, 0x82, 0x83,
|
||||
0xff, 0x74, 0x06, 0x8a, 0x26, 0xa4, 0xd6, 0x5b, 0x81, 0x30, 0x9e, 0x4d, 0x93, 0x28, 0x83, 0x23,
|
||||
0x75, 0x2e, 0xd5, 0x5d, 0xbf, 0xea, 0xd6, 0x5c, 0x51, 0x35, 0xde, 0xed, 0xa0, 0x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0x34, 0x10, 0xb6, 0x68, 0xf4, 0xd3, 0xa5, 0xdb, 0xca, 0x6a,
|
||||
0xc7, 0x1d, 0x90, 0x16, 0xaa, 0xd5, 0x97, 0x83, 0x74, 0x07, 0x21, 0x2d, 0xb1, 0xd7, 0x81, 0x34,
|
||||
0x6f, 0xa6, 0x52, 0xdd, 0x89, 0xa7, 0x1d, 0x11, 0xd4, 0x79, 0x45, 0xe4, 0xc1, 0x3b, 0x6d, 0x32,
|
||||
0x13, 0x37, 0xbd, 0x12, 0x44, 0xeb, 0x40, 0x20, 0xbe, 0x20, 0x30, 0x75, 0x4b, 0xd4, 0x85, 0xca,
|
||||
0x41, 0x68, 0xa2, 0x3f, 0xda, 0x82, 0x94, 0xfd, 0xe0, 0xdd, 0x46, 0x78, 0x8b, 0x97, 0x17, 0x5e,
|
||||
0x03, 0x1e, 0xc6, 0xfe, 0x1e, 0xfd, 0x95, 0xc0, 0x74, 0xdf, 0x49, 0x4b, 0xd2, 0xb7, 0x63, 0xf7,
|
||||
0xee, 0x3b, 0x8e, 0xe5, 0xd6, 0x0d, 0x53, 0x8f, 0xd9, 0x8d, 0x81, 0x00, 0xb7, 0x87, 0xb1, 0xf9,
|
||||
0xd4, 0x60, 0xb6, 0x71, 0x08, 0x2f, 0x79, 0xf7, 0xbf, 0x00, 0x00, 0x00, 0xff, 0xff, 0x82, 0xd3,
|
||||
0xb7, 0x03, 0x05, 0x14, 0x00, 0x00,
|
||||
}
|
||||
|
||||
// Reference imports to suppress errors if they are not otherwise used.
|
||||
@@ -1185,6 +1304,7 @@ type WorkflowServiceClient interface {
|
||||
AddWorkflowExecutionLabels(ctx context.Context, in *AddLabelsRequest, opts ...grpc.CallOption) (*GetLabelsResponse, error)
|
||||
ReplaceWorkflowExecutionLabels(ctx context.Context, in *ReplaceLabelsRequest, opts ...grpc.CallOption) (*GetLabelsResponse, error)
|
||||
DeleteWorkflowExecutionLabel(ctx context.Context, in *DeleteLabelRequest, opts ...grpc.CallOption) (*GetLabelsResponse, error)
|
||||
AddWorkflowExecutionStatistics(ctx context.Context, in *AddWorkflowExecutionStatisticRequest, opts ...grpc.CallOption) (*empty.Empty, error)
|
||||
}
|
||||
|
||||
type workflowServiceClient struct {
|
||||
@@ -1367,6 +1487,15 @@ func (c *workflowServiceClient) DeleteWorkflowExecutionLabel(ctx context.Context
|
||||
return out, nil
|
||||
}
|
||||
|
||||
func (c *workflowServiceClient) AddWorkflowExecutionStatistics(ctx context.Context, in *AddWorkflowExecutionStatisticRequest, opts ...grpc.CallOption) (*empty.Empty, error) {
|
||||
out := new(empty.Empty)
|
||||
err := c.cc.Invoke(ctx, "/api.WorkflowService/AddWorkflowExecutionStatistics", in, out, opts...)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
return out, nil
|
||||
}
|
||||
|
||||
// WorkflowServiceServer is the server API for WorkflowService service.
|
||||
type WorkflowServiceServer interface {
|
||||
// Creates a Workflow
|
||||
@@ -1384,6 +1513,7 @@ type WorkflowServiceServer interface {
|
||||
AddWorkflowExecutionLabels(context.Context, *AddLabelsRequest) (*GetLabelsResponse, error)
|
||||
ReplaceWorkflowExecutionLabels(context.Context, *ReplaceLabelsRequest) (*GetLabelsResponse, error)
|
||||
DeleteWorkflowExecutionLabel(context.Context, *DeleteLabelRequest) (*GetLabelsResponse, error)
|
||||
AddWorkflowExecutionStatistics(context.Context, *AddWorkflowExecutionStatisticRequest) (*empty.Empty, error)
|
||||
}
|
||||
|
||||
// UnimplementedWorkflowServiceServer can be embedded to have forward compatible implementations.
|
||||
@@ -1432,6 +1562,9 @@ func (*UnimplementedWorkflowServiceServer) ReplaceWorkflowExecutionLabels(ctx co
|
||||
func (*UnimplementedWorkflowServiceServer) DeleteWorkflowExecutionLabel(ctx context.Context, req *DeleteLabelRequest) (*GetLabelsResponse, error) {
|
||||
return nil, status.Errorf(codes.Unimplemented, "method DeleteWorkflowExecutionLabel not implemented")
|
||||
}
|
||||
func (*UnimplementedWorkflowServiceServer) AddWorkflowExecutionStatistics(ctx context.Context, req *AddWorkflowExecutionStatisticRequest) (*empty.Empty, error) {
|
||||
return nil, status.Errorf(codes.Unimplemented, "method AddWorkflowExecutionStatistics not implemented")
|
||||
}
|
||||
|
||||
func RegisterWorkflowServiceServer(s *grpc.Server, srv WorkflowServiceServer) {
|
||||
s.RegisterService(&_WorkflowService_serviceDesc, srv)
|
||||
@@ -1695,6 +1828,24 @@ func _WorkflowService_DeleteWorkflowExecutionLabel_Handler(srv interface{}, ctx
|
||||
return interceptor(ctx, in, info, handler)
|
||||
}
|
||||
|
||||
func _WorkflowService_AddWorkflowExecutionStatistics_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
|
||||
in := new(AddWorkflowExecutionStatisticRequest)
|
||||
if err := dec(in); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if interceptor == nil {
|
||||
return srv.(WorkflowServiceServer).AddWorkflowExecutionStatistics(ctx, in)
|
||||
}
|
||||
info := &grpc.UnaryServerInfo{
|
||||
Server: srv,
|
||||
FullMethod: "/api.WorkflowService/AddWorkflowExecutionStatistics",
|
||||
}
|
||||
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
|
||||
return srv.(WorkflowServiceServer).AddWorkflowExecutionStatistics(ctx, req.(*AddWorkflowExecutionStatisticRequest))
|
||||
}
|
||||
return interceptor(ctx, in, info, handler)
|
||||
}
|
||||
|
||||
var _WorkflowService_serviceDesc = grpc.ServiceDesc{
|
||||
ServiceName: "api.WorkflowService",
|
||||
HandlerType: (*WorkflowServiceServer)(nil),
|
||||
@@ -1747,6 +1898,10 @@ var _WorkflowService_serviceDesc = grpc.ServiceDesc{
|
||||
MethodName: "DeleteWorkflowExecutionLabel",
|
||||
Handler: _WorkflowService_DeleteWorkflowExecutionLabel_Handler,
|
||||
},
|
||||
{
|
||||
MethodName: "AddWorkflowExecutionStatistics",
|
||||
Handler: _WorkflowService_AddWorkflowExecutionStatistics_Handler,
|
||||
},
|
||||
},
|
||||
Streams: []grpc.StreamDesc{
|
||||
{
|
||||
|
@@ -1164,6 +1164,98 @@ func local_request_WorkflowService_DeleteWorkflowExecutionLabel_0(ctx context.Co
|
||||
|
||||
}
|
||||
|
||||
func request_WorkflowService_AddWorkflowExecutionStatistics_0(ctx context.Context, marshaler runtime.Marshaler, client WorkflowServiceClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {
|
||||
var protoReq AddWorkflowExecutionStatisticRequest
|
||||
var metadata runtime.ServerMetadata
|
||||
|
||||
newReader, berr := utilities.IOReaderFactory(req.Body)
|
||||
if berr != nil {
|
||||
return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr)
|
||||
}
|
||||
if err := marshaler.NewDecoder(newReader()).Decode(&protoReq.Statistics); err != nil && err != io.EOF {
|
||||
return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)
|
||||
}
|
||||
|
||||
var (
|
||||
val string
|
||||
ok bool
|
||||
err error
|
||||
_ = err
|
||||
)
|
||||
|
||||
val, ok = pathParams["namespace"]
|
||||
if !ok {
|
||||
return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "namespace")
|
||||
}
|
||||
|
||||
protoReq.Namespace, err = runtime.String(val)
|
||||
|
||||
if err != nil {
|
||||
return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "namespace", err)
|
||||
}
|
||||
|
||||
val, ok = pathParams["name"]
|
||||
if !ok {
|
||||
return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "name")
|
||||
}
|
||||
|
||||
protoReq.Name, err = runtime.String(val)
|
||||
|
||||
if err != nil {
|
||||
return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "name", err)
|
||||
}
|
||||
|
||||
msg, err := client.AddWorkflowExecutionStatistics(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD))
|
||||
return msg, metadata, err
|
||||
|
||||
}
|
||||
|
||||
func local_request_WorkflowService_AddWorkflowExecutionStatistics_0(ctx context.Context, marshaler runtime.Marshaler, server WorkflowServiceServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {
|
||||
var protoReq AddWorkflowExecutionStatisticRequest
|
||||
var metadata runtime.ServerMetadata
|
||||
|
||||
newReader, berr := utilities.IOReaderFactory(req.Body)
|
||||
if berr != nil {
|
||||
return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr)
|
||||
}
|
||||
if err := marshaler.NewDecoder(newReader()).Decode(&protoReq.Statistics); err != nil && err != io.EOF {
|
||||
return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)
|
||||
}
|
||||
|
||||
var (
|
||||
val string
|
||||
ok bool
|
||||
err error
|
||||
_ = err
|
||||
)
|
||||
|
||||
val, ok = pathParams["namespace"]
|
||||
if !ok {
|
||||
return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "namespace")
|
||||
}
|
||||
|
||||
protoReq.Namespace, err = runtime.String(val)
|
||||
|
||||
if err != nil {
|
||||
return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "namespace", err)
|
||||
}
|
||||
|
||||
val, ok = pathParams["name"]
|
||||
if !ok {
|
||||
return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "name")
|
||||
}
|
||||
|
||||
protoReq.Name, err = runtime.String(val)
|
||||
|
||||
if err != nil {
|
||||
return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "name", err)
|
||||
}
|
||||
|
||||
msg, err := server.AddWorkflowExecutionStatistics(ctx, &protoReq)
|
||||
return msg, metadata, err
|
||||
|
||||
}
|
||||
|
||||
// RegisterWorkflowServiceHandlerServer registers the http handlers for service WorkflowService to "mux".
|
||||
// UnaryRPC :call WorkflowServiceServer directly.
|
||||
// StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906.
|
||||
@@ -1423,6 +1515,26 @@ func RegisterWorkflowServiceHandlerServer(ctx context.Context, mux *runtime.Serv
|
||||
|
||||
})
|
||||
|
||||
mux.Handle("POST", pattern_WorkflowService_AddWorkflowExecutionStatistics_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {
|
||||
ctx, cancel := context.WithCancel(req.Context())
|
||||
defer cancel()
|
||||
inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)
|
||||
rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req)
|
||||
if err != nil {
|
||||
runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)
|
||||
return
|
||||
}
|
||||
resp, md, err := local_request_WorkflowService_AddWorkflowExecutionStatistics_0(rctx, inboundMarshaler, server, req, pathParams)
|
||||
ctx = runtime.NewServerMetadataContext(ctx, md)
|
||||
if err != nil {
|
||||
runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)
|
||||
return
|
||||
}
|
||||
|
||||
forward_WorkflowService_AddWorkflowExecutionStatistics_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)
|
||||
|
||||
})
|
||||
|
||||
return nil
|
||||
}
|
||||
|
||||
@@ -1744,6 +1856,26 @@ func RegisterWorkflowServiceHandlerClient(ctx context.Context, mux *runtime.Serv
|
||||
|
||||
})
|
||||
|
||||
mux.Handle("POST", pattern_WorkflowService_AddWorkflowExecutionStatistics_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {
|
||||
ctx, cancel := context.WithCancel(req.Context())
|
||||
defer cancel()
|
||||
inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)
|
||||
rctx, err := runtime.AnnotateContext(ctx, mux, req)
|
||||
if err != nil {
|
||||
runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)
|
||||
return
|
||||
}
|
||||
resp, md, err := request_WorkflowService_AddWorkflowExecutionStatistics_0(rctx, inboundMarshaler, client, req, pathParams)
|
||||
ctx = runtime.NewServerMetadataContext(ctx, md)
|
||||
if err != nil {
|
||||
runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)
|
||||
return
|
||||
}
|
||||
|
||||
forward_WorkflowService_AddWorkflowExecutionStatistics_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)
|
||||
|
||||
})
|
||||
|
||||
return nil
|
||||
}
|
||||
|
||||
@@ -1775,6 +1907,8 @@ var (
|
||||
pattern_WorkflowService_ReplaceWorkflowExecutionLabels_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 1, 0, 4, 1, 5, 2, 2, 3, 1, 0, 4, 1, 5, 4, 2, 5}, []string{"apis", "v1beta1", "namespace", "workflow_executions", "name", "labels"}, "", runtime.AssumeColonVerbOpt(true)))
|
||||
|
||||
pattern_WorkflowService_DeleteWorkflowExecutionLabel_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 1, 0, 4, 1, 5, 2, 2, 3, 1, 0, 4, 1, 5, 4, 2, 5, 1, 0, 4, 1, 5, 6}, []string{"apis", "v1beta1", "namespace", "workflow_executions", "name", "labels", "key"}, "", runtime.AssumeColonVerbOpt(true)))
|
||||
|
||||
pattern_WorkflowService_AddWorkflowExecutionStatistics_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 1, 0, 4, 1, 5, 2, 2, 3, 1, 0, 4, 1, 5, 4, 2, 5}, []string{"apis", "v1beta1", "namespace", "workflow_executions", "name", "statistics"}, "", runtime.AssumeColonVerbOpt(true)))
|
||||
)
|
||||
|
||||
var (
|
||||
@@ -1805,4 +1939,6 @@ var (
|
||||
forward_WorkflowService_ReplaceWorkflowExecutionLabels_0 = runtime.ForwardResponseMessage
|
||||
|
||||
forward_WorkflowService_DeleteWorkflowExecutionLabel_0 = runtime.ForwardResponseMessage
|
||||
|
||||
forward_WorkflowService_AddWorkflowExecutionStatistics_0 = runtime.ForwardResponseMessage
|
||||
)
|
||||
|
@@ -96,6 +96,13 @@ service WorkflowService {
|
||||
delete: "/apis/v1beta1/{namespace}/workflow_executions/{name}/labels/{key}"
|
||||
};
|
||||
}
|
||||
|
||||
rpc AddWorkflowExecutionStatistics (AddWorkflowExecutionStatisticRequest) returns (google.protobuf.Empty) {
|
||||
option (google.api.http) = {
|
||||
post: "/apis/v1beta1/{namespace}/workflow_executions/{name}/statistics"
|
||||
body: "statistics"
|
||||
};
|
||||
}
|
||||
}
|
||||
|
||||
message CreateWorkflowExecutionRequest {
|
||||
@@ -211,4 +218,16 @@ message ListFilesRequest {
|
||||
message ListFilesResponse {
|
||||
repeated File files = 1;
|
||||
string parentPath = 2;
|
||||
}
|
||||
|
||||
message Statistics {
|
||||
string workflowStatus = 1;
|
||||
string createdAt = 2;
|
||||
int64 workflowTemplateId = 3;
|
||||
}
|
||||
|
||||
message AddWorkflowExecutionStatisticRequest {
|
||||
string namespace = 1;
|
||||
string name = 2;
|
||||
Statistics statistics = 3;
|
||||
}
|
@@ -503,25 +503,97 @@ func (m *ArchiveWorkflowTemplateResponse) GetWorkflowTemplate() *WorkflowTemplat
|
||||
return nil
|
||||
}
|
||||
|
||||
type WorkflowExecutionStatisticReport struct {
|
||||
Total int32 `protobuf:"varint,1,opt,name=total,proto3" json:"total,omitempty"`
|
||||
LastExecuted string `protobuf:"bytes,2,opt,name=lastExecuted,proto3" json:"lastExecuted,omitempty"`
|
||||
Running int32 `protobuf:"varint,3,opt,name=running,proto3" json:"running,omitempty"`
|
||||
Completed int32 `protobuf:"varint,4,opt,name=completed,proto3" json:"completed,omitempty"`
|
||||
Failed int32 `protobuf:"varint,5,opt,name=failed,proto3" json:"failed,omitempty"`
|
||||
XXX_NoUnkeyedLiteral struct{} `json:"-"`
|
||||
XXX_unrecognized []byte `json:"-"`
|
||||
XXX_sizecache int32 `json:"-"`
|
||||
}
|
||||
|
||||
func (m *WorkflowExecutionStatisticReport) Reset() { *m = WorkflowExecutionStatisticReport{} }
|
||||
func (m *WorkflowExecutionStatisticReport) String() string { return proto.CompactTextString(m) }
|
||||
func (*WorkflowExecutionStatisticReport) ProtoMessage() {}
|
||||
func (*WorkflowExecutionStatisticReport) Descriptor() ([]byte, []int) {
|
||||
return fileDescriptor_b9a07547748a96e8, []int{10}
|
||||
}
|
||||
|
||||
func (m *WorkflowExecutionStatisticReport) XXX_Unmarshal(b []byte) error {
|
||||
return xxx_messageInfo_WorkflowExecutionStatisticReport.Unmarshal(m, b)
|
||||
}
|
||||
func (m *WorkflowExecutionStatisticReport) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
|
||||
return xxx_messageInfo_WorkflowExecutionStatisticReport.Marshal(b, m, deterministic)
|
||||
}
|
||||
func (m *WorkflowExecutionStatisticReport) XXX_Merge(src proto.Message) {
|
||||
xxx_messageInfo_WorkflowExecutionStatisticReport.Merge(m, src)
|
||||
}
|
||||
func (m *WorkflowExecutionStatisticReport) XXX_Size() int {
|
||||
return xxx_messageInfo_WorkflowExecutionStatisticReport.Size(m)
|
||||
}
|
||||
func (m *WorkflowExecutionStatisticReport) XXX_DiscardUnknown() {
|
||||
xxx_messageInfo_WorkflowExecutionStatisticReport.DiscardUnknown(m)
|
||||
}
|
||||
|
||||
var xxx_messageInfo_WorkflowExecutionStatisticReport proto.InternalMessageInfo
|
||||
|
||||
func (m *WorkflowExecutionStatisticReport) GetTotal() int32 {
|
||||
if m != nil {
|
||||
return m.Total
|
||||
}
|
||||
return 0
|
||||
}
|
||||
|
||||
func (m *WorkflowExecutionStatisticReport) GetLastExecuted() string {
|
||||
if m != nil {
|
||||
return m.LastExecuted
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
func (m *WorkflowExecutionStatisticReport) GetRunning() int32 {
|
||||
if m != nil {
|
||||
return m.Running
|
||||
}
|
||||
return 0
|
||||
}
|
||||
|
||||
func (m *WorkflowExecutionStatisticReport) GetCompleted() int32 {
|
||||
if m != nil {
|
||||
return m.Completed
|
||||
}
|
||||
return 0
|
||||
}
|
||||
|
||||
func (m *WorkflowExecutionStatisticReport) GetFailed() int32 {
|
||||
if m != nil {
|
||||
return m.Failed
|
||||
}
|
||||
return 0
|
||||
}
|
||||
|
||||
type WorkflowTemplate struct {
|
||||
CreatedAt string `protobuf:"bytes,1,opt,name=createdAt,proto3" json:"createdAt,omitempty"`
|
||||
Uid string `protobuf:"bytes,2,opt,name=uid,proto3" json:"uid,omitempty"`
|
||||
Name string `protobuf:"bytes,3,opt,name=name,proto3" json:"name,omitempty"`
|
||||
Version int32 `protobuf:"varint,4,opt,name=version,proto3" json:"version,omitempty"`
|
||||
Manifest string `protobuf:"bytes,5,opt,name=manifest,proto3" json:"manifest,omitempty"`
|
||||
IsLatest bool `protobuf:"varint,6,opt,name=isLatest,proto3" json:"isLatest,omitempty"`
|
||||
IsArchived bool `protobuf:"varint,7,opt,name=isArchived,proto3" json:"isArchived,omitempty"`
|
||||
Labels []*KeyValue `protobuf:"bytes,8,rep,name=labels,proto3" json:"labels,omitempty"`
|
||||
XXX_NoUnkeyedLiteral struct{} `json:"-"`
|
||||
XXX_unrecognized []byte `json:"-"`
|
||||
XXX_sizecache int32 `json:"-"`
|
||||
CreatedAt string `protobuf:"bytes,1,opt,name=createdAt,proto3" json:"createdAt,omitempty"`
|
||||
Uid string `protobuf:"bytes,2,opt,name=uid,proto3" json:"uid,omitempty"`
|
||||
Name string `protobuf:"bytes,3,opt,name=name,proto3" json:"name,omitempty"`
|
||||
Version int32 `protobuf:"varint,4,opt,name=version,proto3" json:"version,omitempty"`
|
||||
Manifest string `protobuf:"bytes,5,opt,name=manifest,proto3" json:"manifest,omitempty"`
|
||||
IsLatest bool `protobuf:"varint,6,opt,name=isLatest,proto3" json:"isLatest,omitempty"`
|
||||
IsArchived bool `protobuf:"varint,7,opt,name=isArchived,proto3" json:"isArchived,omitempty"`
|
||||
Labels []*KeyValue `protobuf:"bytes,8,rep,name=labels,proto3" json:"labels,omitempty"`
|
||||
Stats *WorkflowExecutionStatisticReport `protobuf:"bytes,9,opt,name=stats,proto3" json:"stats,omitempty"`
|
||||
XXX_NoUnkeyedLiteral struct{} `json:"-"`
|
||||
XXX_unrecognized []byte `json:"-"`
|
||||
XXX_sizecache int32 `json:"-"`
|
||||
}
|
||||
|
||||
func (m *WorkflowTemplate) Reset() { *m = WorkflowTemplate{} }
|
||||
func (m *WorkflowTemplate) String() string { return proto.CompactTextString(m) }
|
||||
func (*WorkflowTemplate) ProtoMessage() {}
|
||||
func (*WorkflowTemplate) Descriptor() ([]byte, []int) {
|
||||
return fileDescriptor_b9a07547748a96e8, []int{10}
|
||||
return fileDescriptor_b9a07547748a96e8, []int{11}
|
||||
}
|
||||
|
||||
func (m *WorkflowTemplate) XXX_Unmarshal(b []byte) error {
|
||||
@@ -598,20 +670,28 @@ func (m *WorkflowTemplate) GetLabels() []*KeyValue {
|
||||
return nil
|
||||
}
|
||||
|
||||
func (m *WorkflowTemplate) GetStats() *WorkflowExecutionStatisticReport {
|
||||
if m != nil {
|
||||
return m.Stats
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
type GetWorkflowTemplateLabelsRequest struct {
|
||||
Namespace string `protobuf:"bytes,1,opt,name=namespace,proto3" json:"namespace,omitempty"`
|
||||
Name string `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty"`
|
||||
Version int32 `protobuf:"varint,3,opt,name=version,proto3" json:"version,omitempty"`
|
||||
XXX_NoUnkeyedLiteral struct{} `json:"-"`
|
||||
XXX_unrecognized []byte `json:"-"`
|
||||
XXX_sizecache int32 `json:"-"`
|
||||
Namespace string `protobuf:"bytes,1,opt,name=namespace,proto3" json:"namespace,omitempty"`
|
||||
Name string `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty"`
|
||||
Version int32 `protobuf:"varint,3,opt,name=version,proto3" json:"version,omitempty"`
|
||||
Stats *WorkflowExecutionStatisticReport `protobuf:"bytes,8,opt,name=stats,proto3" json:"stats,omitempty"`
|
||||
XXX_NoUnkeyedLiteral struct{} `json:"-"`
|
||||
XXX_unrecognized []byte `json:"-"`
|
||||
XXX_sizecache int32 `json:"-"`
|
||||
}
|
||||
|
||||
func (m *GetWorkflowTemplateLabelsRequest) Reset() { *m = GetWorkflowTemplateLabelsRequest{} }
|
||||
func (m *GetWorkflowTemplateLabelsRequest) String() string { return proto.CompactTextString(m) }
|
||||
func (*GetWorkflowTemplateLabelsRequest) ProtoMessage() {}
|
||||
func (*GetWorkflowTemplateLabelsRequest) Descriptor() ([]byte, []int) {
|
||||
return fileDescriptor_b9a07547748a96e8, []int{11}
|
||||
return fileDescriptor_b9a07547748a96e8, []int{12}
|
||||
}
|
||||
|
||||
func (m *GetWorkflowTemplateLabelsRequest) XXX_Unmarshal(b []byte) error {
|
||||
@@ -653,6 +733,13 @@ func (m *GetWorkflowTemplateLabelsRequest) GetVersion() int32 {
|
||||
return 0
|
||||
}
|
||||
|
||||
func (m *GetWorkflowTemplateLabelsRequest) GetStats() *WorkflowExecutionStatisticReport {
|
||||
if m != nil {
|
||||
return m.Stats
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
func init() {
|
||||
proto.RegisterType((*CreateWorkflowTemplateRequest)(nil), "api.CreateWorkflowTemplateRequest")
|
||||
proto.RegisterType((*UpdateWorkflowTemplateVersionRequest)(nil), "api.UpdateWorkflowTemplateVersionRequest")
|
||||
@@ -664,6 +751,7 @@ func init() {
|
||||
proto.RegisterType((*ListWorkflowTemplatesResponse)(nil), "api.ListWorkflowTemplatesResponse")
|
||||
proto.RegisterType((*ArchiveWorkflowTemplateRequest)(nil), "api.ArchiveWorkflowTemplateRequest")
|
||||
proto.RegisterType((*ArchiveWorkflowTemplateResponse)(nil), "api.ArchiveWorkflowTemplateResponse")
|
||||
proto.RegisterType((*WorkflowExecutionStatisticReport)(nil), "api.WorkflowExecutionStatisticReport")
|
||||
proto.RegisterType((*WorkflowTemplate)(nil), "api.WorkflowTemplate")
|
||||
proto.RegisterType((*GetWorkflowTemplateLabelsRequest)(nil), "api.GetWorkflowTemplateLabelsRequest")
|
||||
}
|
||||
@@ -671,62 +759,68 @@ func init() {
|
||||
func init() { proto.RegisterFile("workflow_template.proto", fileDescriptor_b9a07547748a96e8) }
|
||||
|
||||
var fileDescriptor_b9a07547748a96e8 = []byte{
|
||||
// 867 bytes of a gzipped FileDescriptorProto
|
||||
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xbc, 0x97, 0xcd, 0x4e, 0xdb, 0x58,
|
||||
0x14, 0xc7, 0x75, 0x13, 0x02, 0xe4, 0xa0, 0x91, 0xe0, 0xcc, 0x40, 0x8c, 0x27, 0x81, 0x8c, 0x01,
|
||||
0x29, 0x8c, 0x46, 0xb1, 0x60, 0x66, 0xc5, 0x30, 0x1a, 0x42, 0x98, 0x61, 0xa6, 0x64, 0x51, 0xb9,
|
||||
0x85, 0x4a, 0x6c, 0x5a, 0x13, 0xdf, 0x50, 0x0b, 0x63, 0xbb, 0xb1, 0x13, 0x44, 0xd3, 0x48, 0xa5,
|
||||
0x5d, 0x74, 0xd7, 0x4d, 0x3f, 0xd4, 0xaa, 0x52, 0xd7, 0x7d, 0x84, 0xae, 0xfb, 0x0a, 0xbc, 0x42,
|
||||
0xbb, 0xe8, 0xaa, 0xaf, 0x50, 0xf9, 0xda, 0x4e, 0xf3, 0x61, 0xa7, 0xf9, 0x6a, 0x77, 0xb9, 0xf7,
|
||||
0x1e, 0x9f, 0xfb, 0xfb, 0x9f, 0x73, 0x7c, 0x8e, 0x03, 0x89, 0x33, 0xa3, 0x7c, 0x52, 0xd2, 0x8c,
|
||||
0xb3, 0x9b, 0x36, 0x3d, 0x35, 0x35, 0xd9, 0xa6, 0x59, 0xb3, 0x6c, 0xd8, 0x06, 0x46, 0x65, 0x53,
|
||||
0xe5, 0x93, 0xc7, 0x86, 0x71, 0xac, 0x51, 0x51, 0x36, 0x55, 0x51, 0xd6, 0x75, 0xc3, 0x96, 0x6d,
|
||||
0xd5, 0xd0, 0x2d, 0xd7, 0x84, 0x9f, 0xd2, 0xe4, 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fd, 0x89, 0xfc, 0xfd, 0x73, 0x00, 0x00, 0x00, 0xff, 0xff, 0x1a, 0xda, 0xf9, 0xc5, 0x8f,
|
||||
0x0e, 0x00, 0x00,
|
||||
// 975 bytes of a gzipped FileDescriptorProto
|
||||
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xbc, 0x97, 0x4f, 0x6f, 0x1b, 0x45,
|
||||
0x14, 0xc0, 0x35, 0x4e, 0x9d, 0xc6, 0xaf, 0x20, 0xa5, 0x0f, 0x92, 0x6c, 0x96, 0xa4, 0x35, 0xd3,
|
||||
0x44, 0x72, 0x11, 0xb2, 0xd5, 0xc0, 0x29, 0x2d, 0xa2, 0x6e, 0x5a, 0x0a, 0x34, 0x07, 0xb4, 0xa5,
|
||||
0x45, 0xea, 0x05, 0x26, 0xbb, 0xe3, 0x30, 0xea, 0x66, 0x77, 0xf1, 0x8c, 0x13, 0x4a, 0xb0, 0x44,
|
||||
0xe1, 0xc0, 0x8d, 0x0b, 0x7f, 0x04, 0x42, 0xea, 0x19, 0x89, 0x7e, 0x00, 0xce, 0x7c, 0x85, 0x7e,
|
||||
0x05, 0x38, 0xf0, 0x2d, 0xd0, 0xce, 0xee, 0x3a, 0xb1, 0xbd, 0x63, 0xbc, 0xb6, 0xe9, 0xcd, 0x33,
|
||||
0xf3, 0xf6, 0xcd, 0xef, 0xfd, 0x9b, 0xf7, 0x0c, 0x2b, 0x47, 0x61, 0xfb, 0x61, 0xcb, 0x0f, 0x8f,
|
||||
0x3e, 0x56, 0xfc, 0x20, 0xf2, 0x99, 0xe2, 0xf5, 0xa8, 0x1d, 0xaa, 0x10, 0xe7, 0x58, 0x24, 0xec,
|
||||
0xb5, 0xfd, 0x30, 0xdc, 0xf7, 0x79, 0x83, 0x45, 0xa2, 0xc1, 0x82, 0x20, 0x54, 0x4c, 0x89, 0x30,
|
||||
0x90, 0x89, 0x88, 0x7d, 0xce, 0x67, 0x7b, 0xdc, 0x4f, 0x16, 0xf4, 0x2b, 0x02, 0xeb, 0x3b, 0x6d,
|
||||
0xce, 0x14, 0xff, 0x28, 0xd5, 0xf8, 0x61, 0xaa, 0xd0, 0xe1, 0x9f, 0x75, 0xb8, 0x54, 0xb8, 0x06,
|
||||
0x95, 0x80, 0x1d, 0x70, 0x19, 0x31, 0x97, 0x5b, 0xa4, 0x4a, 0x6a, 0x15, 0xe7, 0x64, 0x03, 0x9b,
|
||||
0xb0, 0x78, 0x34, 0xf0, 0xa1, 0x55, 0xaa, 0x92, 0xda, 0xb9, 0xad, 0xa5, 0x3a, 0x8b, 0x44, 0x7d,
|
||||
0x48, 0xeb, 0x90, 0x38, 0xfd, 0x96, 0xc0, 0xc6, 0xbd, 0xc8, 0xcb, 0x41, 0xb8, 0xcf, 0xdb, 0x52,
|
||||
0x84, 0xc1, 0x73, 0x23, 0x69, 0x81, 0x7d, 0x9b, 0xab, 0xc9, 0x1c, 0xb1, 0x08, 0x73, 0x1d, 0xe1,
|
||||
0xe9, 0x1b, 0x2b, 0x4e, 0xfc, 0x13, 0x2d, 0x38, 0x7b, 0x98, 0x18, 0x60, 0xcd, 0x55, 0x49, 0xad,
|
||||
0xec, 0x64, 0x4b, 0xfa, 0x25, 0xac, 0xed, 0xf8, 0x61, 0xc0, 0x67, 0x75, 0x13, 0xc2, 0x99, 0xf8,
|
||||
0x58, 0x5f, 0x53, 0x71, 0xf4, 0xef, 0xd3, 0xb7, 0x9f, 0xe9, 0xbf, 0xfd, 0x1e, 0x5c, 0xda, 0x15,
|
||||
0x52, 0x19, 0x9c, 0x2d, 0x27, 0x84, 0xa0, 0x8f, 0x09, 0x6c, 0x8c, 0xd6, 0x2b, 0xa3, 0x30, 0x90,
|
||||
0x1c, 0x5f, 0x86, 0xb2, 0x1b, 0x76, 0x02, 0xa5, 0x95, 0x96, 0x9d, 0x64, 0x81, 0x3b, 0x70, 0x7e,
|
||||
0x30, 0x1e, 0xd2, 0x2a, 0x55, 0xe7, 0xcc, 0xf1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
||||
0x2c, 0xd1, 0x8d, 0x4f, 0x08, 0xac, 0x1a, 0x7b, 0x1a, 0x6e, 0x9a, 0x8a, 0xb8, 0xaf, 0xe7, 0xd9,
|
||||
0xcb, 0x99, 0x58, 0xb6, 0xdd, 0x0f, 0x88, 0x05, 0x01, 0x13, 0x77, 0xa6, 0x1d, 0xfb, 0x27, 0x02,
|
||||
0xab, 0x4d, 0xcf, 0x33, 0x00, 0x26, 0x89, 0xd1, 0xf4, 0xbc, 0xf1, 0x80, 0xde, 0xd7, 0x40, 0x37,
|
||||
0xe9, 0x14, 0x40, 0xdb, 0xd9, 0x28, 0xf1, 0x84, 0xc0, 0xba, 0xc3, 0x23, 0x9f, 0xb9, 0xdc, 0x00,
|
||||
0xb7, 0xaa, 0x29, 0x52, 0x99, 0x42, 0x80, 0xf6, 0x2c, 0x00, 0x7f, 0x26, 0xf0, 0xca, 0x4d, 0x1e,
|
||||
0x4f, 0x80, 0xb9, 0x7c, 0xb8, 0xa2, 0x19, 0x12, 0x09, 0xbd, 0xf3, 0x5f, 0x70, 0xef, 0x6a, 0xb8,
|
||||
0x1b, 0xaf, 0x5d, 0x9f, 0x1c, 0xae, 0x71, 0xfc, 0x90, 0x3f, 0xea, 0xee, 0xcd, 0xeb, 0xbf, 0xdb,
|
||||
0x6f, 0xfc, 0x1b, 0x00, 0x00, 0xff, 0xff, 0xeb, 0xe1, 0x8a, 0xe9, 0xb9, 0x0f, 0x00, 0x00,
|
||||
}
|
||||
|
||||
// Reference imports to suppress errors if they are not otherwise used.
|
||||
|
@@ -141,6 +141,14 @@ message ArchiveWorkflowTemplateResponse {
|
||||
WorkflowTemplate workflowTemplate = 1;
|
||||
}
|
||||
|
||||
message WorkflowExecutionStatisticReport {
|
||||
int32 total = 1;
|
||||
string lastExecuted = 2;
|
||||
int32 running = 3;
|
||||
int32 completed = 4;
|
||||
int32 failed = 5;
|
||||
}
|
||||
|
||||
message WorkflowTemplate {
|
||||
string createdAt = 1;
|
||||
string uid = 2;
|
||||
@@ -150,10 +158,13 @@ message WorkflowTemplate {
|
||||
bool isLatest = 6;
|
||||
bool isArchived = 7;
|
||||
repeated KeyValue labels = 8;
|
||||
|
||||
WorkflowExecutionStatisticReport stats = 9;
|
||||
}
|
||||
|
||||
message GetWorkflowTemplateLabelsRequest {
|
||||
string namespace = 1;
|
||||
string name = 2;
|
||||
int32 version = 3;
|
||||
WorkflowExecutionStatisticReport stats = 8;
|
||||
}
|
20
db/20200413141037_create_workflow_execution_statistics.sql
Normal file
20
db/20200413141037_create_workflow_execution_statistics.sql
Normal file
@@ -0,0 +1,20 @@
|
||||
-- +goose Up
|
||||
-- +goose StatementBegin
|
||||
CREATE TABLE workflow_executions
|
||||
(
|
||||
id serial PRIMARY KEY,
|
||||
workflow_template_id integer NOT NULL REFERENCES workflow_templates ON DELETE CASCADE,
|
||||
name text NOT NULL CHECK (name <> ''),
|
||||
namespace varchar(36) NOT NULL,
|
||||
|
||||
-- auditing info
|
||||
created_at timestamp NOT NULL DEFAULT (NOW() at time zone 'utc'),
|
||||
finished_at timestamp DEFAULT NULL,
|
||||
failed_at timestamp DEFAULT NULL
|
||||
);
|
||||
-- +goose StatementEnd
|
||||
|
||||
-- +goose Down
|
||||
-- +goose StatementBegin
|
||||
DROP TABLE workflow_executions;
|
||||
-- +goose StatementEnd
|
12
go.mod
12
go.mod
@@ -12,17 +12,16 @@ require (
|
||||
github.com/evanphx/json-patch v4.5.0+incompatible // indirect
|
||||
github.com/ghodss/yaml v1.0.0
|
||||
github.com/go-sql-driver/mysql v1.5.0 // indirect
|
||||
github.com/golang/groupcache v0.0.0-20200121045136-8c9f03a8e57e // indirect
|
||||
github.com/golang/protobuf v1.3.5
|
||||
github.com/golang/protobuf v1.4.0
|
||||
github.com/google/uuid v1.1.1
|
||||
github.com/gorilla/handlers v1.4.2
|
||||
github.com/grpc-ecosystem/go-grpc-middleware v1.2.0
|
||||
github.com/grpc-ecosystem/grpc-gateway v1.13.0
|
||||
github.com/grpc-ecosystem/grpc-gateway v1.14.3
|
||||
github.com/hashicorp/go-uuid v1.0.2 // indirect
|
||||
github.com/hashicorp/golang-lru v0.5.4 // indirect
|
||||
github.com/jmoiron/sqlx v1.2.0
|
||||
github.com/lib/pq v1.3.0
|
||||
github.com/mattn/go-sqlite3 v2.0.2+incompatible // indirect
|
||||
github.com/mattn/go-sqlite3 v2.0.3+incompatible // indirect
|
||||
github.com/minio/minio-go/v6 v6.0.45
|
||||
github.com/pkg/errors v0.9.1
|
||||
github.com/pressly/goose v2.6.0+incompatible
|
||||
@@ -30,11 +29,12 @@ require (
|
||||
github.com/spf13/cobra v0.0.5 // indirect
|
||||
github.com/stretchr/testify v1.4.0
|
||||
github.com/tmc/grpc-websocket-proxy v0.0.0-20200122045848-3419fae592fc
|
||||
google.golang.org/genproto v0.0.0-20200317114155-1f3552e48f24
|
||||
github.com/ziutek/mymysql v1.5.4 // indirect
|
||||
google.golang.org/genproto v0.0.0-20200413115906-b5235f65be36
|
||||
google.golang.org/grpc v1.28.0
|
||||
gopkg.in/yaml.v2 v2.2.8
|
||||
google.golang.org/protobuf v1.21.0
|
||||
k8s.io/api v0.16.4
|
||||
k8s.io/apimachinery v0.16.7-beta.0
|
||||
k8s.io/client-go v0.16.4
|
||||
k8s.io/code-generator v0.16.7-beta.0 // indirect
|
||||
)
|
||||
|
27
go.sum
27
go.sum
@@ -150,6 +150,7 @@ github.com/go-openapi/swag v0.19.5 h1:lTz6Ys4CmqqCQmZPBlbQENR1/GucA2bzYTE12Pw4tF
|
||||
github.com/go-openapi/swag v0.19.5/go.mod h1:POnQmlKehdgb5mhVOsnJFsivZCEZ/vjK9gh66Z9tfKk=
|
||||
github.com/go-sql-driver/mysql v1.4.0/go.mod h1:zAC/RDZ24gD3HViQzih4MyKcchzm+sOG5ZlKdlhCg5w=
|
||||
github.com/go-sql-driver/mysql v1.4.1/go.mod h1:zAC/RDZ24gD3HViQzih4MyKcchzm+sOG5ZlKdlhCg5w=
|
||||
github.com/go-sql-driver/mysql v1.5.0 h1:ozyZYNQW3x3HtqT1jira07DN2PArx2v7/mN66gGcHOs=
|
||||
github.com/go-sql-driver/mysql v1.5.0/go.mod h1:DCzpHaOWr8IXmIStZouvnhqoel9Qv2LBy8hT2VhHyBg=
|
||||
github.com/go-stack/stack v1.8.0/go.mod h1:v0f6uXyyMGvRgIKkXu+yp6POWl0qKG85gN/melR3HDY=
|
||||
github.com/gogo/protobuf v0.0.0-20171007142547-342cbe0a0415/go.mod h1:r8qH/GZQm5c6nD/R0oafs1akxWv10x8SbQlK7atdtwQ=
|
||||
@@ -158,6 +159,7 @@ github.com/gogo/protobuf v1.2.1/go.mod h1:hp+jE20tsWTFYpLwKvXlhS1hjn+gTNwPg2I6zV
|
||||
github.com/gogo/protobuf v1.2.2-0.20190723190241-65acae22fc9d/go.mod h1:SlYgWuQ5SjCEi6WLHjHCa1yvBfUnHcTbrrZtXPKa29o=
|
||||
github.com/gogo/protobuf v1.3.1 h1:DqDEcV5aeaTmdFBePNpYsp3FlcVH/2ISVVM9Qf8PSls=
|
||||
github.com/gogo/protobuf v1.3.1/go.mod h1:SlYgWuQ5SjCEi6WLHjHCa1yvBfUnHcTbrrZtXPKa29o=
|
||||
github.com/golang/glog v0.0.0-20160126235308-23def4e6c14b h1:VKtxabqXZkF25pY9ekfRL6a582T4P37/31XEstQ5p58=
|
||||
github.com/golang/glog v0.0.0-20160126235308-23def4e6c14b/go.mod h1:SBH7ygxi8pfUlaOkMMuAQtPIUF8ecWP5IEl/CR7VP2Q=
|
||||
github.com/golang/groupcache v0.0.0-20160516000752-02826c3e7903/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc=
|
||||
github.com/golang/groupcache v0.0.0-20190702054246-869f871628b6/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc=
|
||||
@@ -177,6 +179,12 @@ github.com/golang/protobuf v1.3.3 h1:gyjaxf+svBWX08ZjK86iN9geUJF0H6gp2IRKX6Nf6/I
|
||||
github.com/golang/protobuf v1.3.3/go.mod h1:vzj43D7+SQXF/4pzW/hwtAqwc6iTitCiVSaWz5lYuqw=
|
||||
github.com/golang/protobuf v1.3.5 h1:F768QJ1E9tib+q5Sc8MkdJi1RxLTbRcTf8LJV56aRls=
|
||||
github.com/golang/protobuf v1.3.5/go.mod h1:6O5/vntMXwX2lRkT1hjjk0nAC1IDOTvTlVgjlRvqsdk=
|
||||
github.com/golang/protobuf v1.4.0-rc.1/go.mod h1:ceaxUfeHdC40wWswd/P6IGgMaK3YpKi5j83Wpe3EHw8=
|
||||
github.com/golang/protobuf v1.4.0-rc.1.0.20200221234624-67d41d38c208/go.mod h1:xKAWHe0F5eneWXFV3EuXVDTCmh+JuBKY0li0aMyXATA=
|
||||
github.com/golang/protobuf v1.4.0-rc.2/go.mod h1:LlEzMj4AhA7rCAGe4KMBDvJI+AwstrUpVNzEA03Pprs=
|
||||
github.com/golang/protobuf v1.4.0-rc.4.0.20200313231945-b860323f09d0/go.mod h1:WU3c8KckQ9AFe+yFwt9sWVRKCVIyN9cPHBJSNnbL67w=
|
||||
github.com/golang/protobuf v1.4.0 h1:oOuy+ugB+P/kBdUnG5QaMXSIyJ1q38wWSojYCb3z5VQ=
|
||||
github.com/golang/protobuf v1.4.0/go.mod h1:jodUvKwWbYaEsadDk5Fwe5c77LiNKVO9IDvqG2KuDX0=
|
||||
github.com/google/btree v0.0.0-20160524151835-7d79101e329e/go.mod h1:lNA+9X1NB3Zf8V7Ke586lFgjr2dZNuvo3lPJSGZ5JPQ=
|
||||
github.com/google/btree v0.0.0-20180813153112-4030bb1f1f0c/go.mod h1:lNA+9X1NB3Zf8V7Ke586lFgjr2dZNuvo3lPJSGZ5JPQ=
|
||||
github.com/google/btree v1.0.0/go.mod h1:lNA+9X1NB3Zf8V7Ke586lFgjr2dZNuvo3lPJSGZ5JPQ=
|
||||
@@ -222,6 +230,8 @@ github.com/grpc-ecosystem/go-grpc-middleware v1.2.0/go.mod h1:mJzapYve32yjrKlk9G
|
||||
github.com/grpc-ecosystem/grpc-gateway v1.12.1/go.mod h1:8XEsbTttt/W+VvjtQhLACqCisSPWTxCZ7sBRjU6iH9c=
|
||||
github.com/grpc-ecosystem/grpc-gateway v1.13.0 h1:sBDQoHXrOlfPobnKw69FIKa1wg9qsLLvvQ/Y19WtFgI=
|
||||
github.com/grpc-ecosystem/grpc-gateway v1.13.0/go.mod h1:8XEsbTttt/W+VvjtQhLACqCisSPWTxCZ7sBRjU6iH9c=
|
||||
github.com/grpc-ecosystem/grpc-gateway v1.14.3 h1:OCJlWkOUoTnl0neNGlf4fUm3TmbEtguw7vR+nGtnDjY=
|
||||
github.com/grpc-ecosystem/grpc-gateway v1.14.3/go.mod h1:6CwZWGDSPRJidgKAtJVvND6soZe6fT7iteq8wDPdhb0=
|
||||
github.com/hashicorp/go-uuid v0.0.0-20180228145832-27454136f036/go.mod h1:6SBZvOh/SIDV7/2o3Jml5SYk/TvGqwFJ/bN7x4byOro=
|
||||
github.com/hashicorp/go-uuid v1.0.1/go.mod h1:6SBZvOh/SIDV7/2o3Jml5SYk/TvGqwFJ/bN7x4byOro=
|
||||
github.com/hashicorp/go-uuid v1.0.2 h1:cfejS+Tpcp13yd5nYHWDI6qVCny6wyX2Mt5SGur2IGE=
|
||||
@@ -238,6 +248,7 @@ github.com/imdario/mergo v0.3.5/go.mod h1:2EnlNZ0deacrJVfApfmtdGgDfMuh/nq6Ok1EcJ
|
||||
github.com/imdario/mergo v0.3.8 h1:CGgOkSJeqMRmt0D9XLWExdT4m4F1vd3FV3VPt+0VxkQ=
|
||||
github.com/imdario/mergo v0.3.8/go.mod h1:2EnlNZ0deacrJVfApfmtdGgDfMuh/nq6Ok1EcJh5FfA=
|
||||
github.com/imkira/go-interpol v1.1.0/go.mod h1:z0h2/2T3XF8kyEPpRgJ3kmNv+C43p+I/CoI+jC3w2iA=
|
||||
github.com/inconshreveable/mousetrap v1.0.0 h1:Z8tu5sraLXCXIcARxBp/8cbvlwVa7Z1NHg9XEKhtSvM=
|
||||
github.com/inconshreveable/mousetrap v1.0.0/go.mod h1:PxqpIevigyE2G7u3NXJIT2ANytuPF1OarO4DADm73n8=
|
||||
github.com/jbenet/go-context v0.0.0-20150711004518-d14ea06fba99/go.mod h1:1lJo3i6rXxKeerYnT8Nvf0QmHCRC1n8sfWVwXF2Frvo=
|
||||
github.com/jcmturner/gofork v0.0.0-20180107083740-2aebee971930/go.mod h1:MK8+TM0La+2rjBD4jE12Kj1pCCxK7d2LK/UM3ncEo0o=
|
||||
@@ -264,6 +275,7 @@ github.com/kisielk/errcheck v1.2.0/go.mod h1:/BMXB+zMLi60iA8Vv6Ksmxu/1UDYcXs4uQL
|
||||
github.com/kisielk/gotool v1.0.0/go.mod h1:XhKaO+MFFWcvkIS/tQcRk01m1F5IRFswLeQ+oQHNcck=
|
||||
github.com/klauspost/compress v1.9.7/go.mod h1:RyIbtBH6LamlWaDj8nUwkbUhJ87Yi3uG0guNDohfE1A=
|
||||
github.com/konsorten/go-windows-terminal-sequences v1.0.1/go.mod h1:T0+1ngSBFLxvqU3pZ+m/2kptfBszLMUkC4ZK/EgS/cQ=
|
||||
github.com/konsorten/go-windows-terminal-sequences v1.0.2 h1:DB17ag19krx9CFsz4o3enTrPXyIXCl+2iCXH/aMAp9s=
|
||||
github.com/konsorten/go-windows-terminal-sequences v1.0.2/go.mod h1:T0+1ngSBFLxvqU3pZ+m/2kptfBszLMUkC4ZK/EgS/cQ=
|
||||
github.com/kr/logfmt v0.0.0-20140226030751-b84e30acd515/go.mod h1:+0opPa2QZZtGFBFZlji/RkVcI2GknAs/DXo4wKdlNEc=
|
||||
github.com/kr/pretty v0.1.0/go.mod h1:dAy3ld7l9f0ibDNOQOHHMYYIIbhfbHSm3C4ZsoJORNo=
|
||||
@@ -287,7 +299,11 @@ github.com/mailru/easyjson v0.0.0-20190626092158-b2ccc519800e/go.mod h1:C1wdFJiN
|
||||
github.com/mattn/go-colorable v0.1.4/go.mod h1:U0ppj6V5qS13XJ6of8GYAs25YV2eR4EVcfRqFIhoBtE=
|
||||
github.com/mattn/go-isatty v0.0.8/go.mod h1:Iq45c/XA43vh69/j3iqttzPXn0bhXyGjM0Hdxcsrc5s=
|
||||
github.com/mattn/go-sqlite3 v1.9.0/go.mod h1:FPy6KqzDD04eiIsT53CuJW3U88zkxoIYsOqkbpncsNc=
|
||||
github.com/mattn/go-sqlite3 v1.13.0 h1:LnJI81JidiW9r7pS/hXe6cFeO5EXNq7KbfvoJLRI69c=
|
||||
github.com/mattn/go-sqlite3 v2.0.2+incompatible h1:qzw9c2GNT8UFrgWNDhCTqRqYUSmu/Dav/9Z58LGpk7U=
|
||||
github.com/mattn/go-sqlite3 v2.0.2+incompatible/go.mod h1:FPy6KqzDD04eiIsT53CuJW3U88zkxoIYsOqkbpncsNc=
|
||||
github.com/mattn/go-sqlite3 v2.0.3+incompatible h1:gXHsfypPkaMZrKbD5209QV9jbUTJKjyR5WD3HYQSd+U=
|
||||
github.com/mattn/go-sqlite3 v2.0.3+incompatible/go.mod h1:FPy6KqzDD04eiIsT53CuJW3U88zkxoIYsOqkbpncsNc=
|
||||
github.com/matttproud/golang_protobuf_extensions v1.0.1/go.mod h1:D8He9yQNgCq6Z5Ld7szi9bcBfOoFv/3dc6xSMkL2PC0=
|
||||
github.com/minio/minio-go v6.0.14+incompatible h1:fnV+GD28LeqdN6vT2XdGKW8Qe/IfjJDswNVuni6km9o=
|
||||
github.com/minio/minio-go v6.0.14+incompatible/go.mod h1:7guKYtitv8dktvNUGrhzmNlA5wrAABTQXCoesZdFQO8=
|
||||
@@ -403,6 +419,8 @@ github.com/yudai/golcs v0.0.0-20170316035057-ecda9a501e82/go.mod h1:lgjkn3NuSvDf
|
||||
github.com/yudai/pp v2.0.1+incompatible/go.mod h1:PuxR/8QJ7cyCkFp/aUDS+JY727OFEZkTdatxwunjIkc=
|
||||
github.com/yuin/goldmark v1.1.25/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74=
|
||||
github.com/yuin/goldmark v1.1.27/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74=
|
||||
github.com/ziutek/mymysql v1.5.4 h1:GB0qdRGsTwQSBVYuVShFBKaXSnSnYYC2d9knnE1LHFs=
|
||||
github.com/ziutek/mymysql v1.5.4/go.mod h1:LMSpPZ6DbqWFxNCHW77HeMg9I646SAhApZ/wKdgO/C0=
|
||||
go.opencensus.io v0.21.0/go.mod h1:mSImk1erAIZhrmZN+AvHh14ztQfjbGwt4TtuofqLduU=
|
||||
go.opencensus.io v0.22.0/go.mod h1:+kGneAE2xo2IficOXnaByMWTGM9T73dGwxeWcUqIpI8=
|
||||
go.opencensus.io v0.22.2/go.mod h1:yxeiOL68Rb0Xd1ddK5vPZ/oVn4vY4Ynel7k9FzqtOIw=
|
||||
@@ -610,6 +628,7 @@ google.golang.org/appengine v1.1.0/go.mod h1:EbEs0AVv82hx2wNQdGPgUI5lhzA/G0D9Ywl
|
||||
google.golang.org/appengine v1.4.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4=
|
||||
google.golang.org/appengine v1.5.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4=
|
||||
google.golang.org/appengine v1.6.1/go.mod h1:i06prIuMbXzDqacNJfV5OdTW448YApPu5ww/cMBSeb0=
|
||||
google.golang.org/appengine v1.6.5 h1:tycE03LOZYQNhDpS27tcQdAzLCVMaj7QT2SXxebnpCM=
|
||||
google.golang.org/appengine v1.6.5/go.mod h1:8WjMMxjGQR8xUklV/ARdw2HLXBOI7O7uCIDZVag1xfc=
|
||||
google.golang.org/genproto v0.0.0-20180817151627-c66870c02cf8/go.mod h1:JiN7NxoALGmiZfu7CAH4rXhgtRTLTxftemlI0sWmxmc=
|
||||
google.golang.org/genproto v0.0.0-20190307195333-5fe7a883aa19/go.mod h1:VzzqZJRnGkLBvHegQrXjBqPurQTc5/KpmUdxsrq26oE=
|
||||
@@ -633,6 +652,8 @@ google.golang.org/genproto v0.0.0-20200218151345-dad8c97a84f5/go.mod h1:55QSHmfG
|
||||
google.golang.org/genproto v0.0.0-20200224152610-e50cd9704f63/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c=
|
||||
google.golang.org/genproto v0.0.0-20200317114155-1f3552e48f24 h1:IGPykv426z7LZSVPlaPufOyphngM4at5uZ7x5alaFvE=
|
||||
google.golang.org/genproto v0.0.0-20200317114155-1f3552e48f24/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c=
|
||||
google.golang.org/genproto v0.0.0-20200413115906-b5235f65be36 h1:j7CmVRD4Kec0+f8VuBAc2Ak2MFfXm5Q2/RxuJLL+76E=
|
||||
google.golang.org/genproto v0.0.0-20200413115906-b5235f65be36/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c=
|
||||
google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZiDr8c=
|
||||
google.golang.org/grpc v1.20.1/go.mod h1:10oTOabMzJvdu6/UiuZezV6QK5dSlG84ov/aaiqXj38=
|
||||
google.golang.org/grpc v1.21.1/go.mod h1:oYelfM1adQP15Ek0mdvEgi9Df8B9CZIaU1084ijfRaM=
|
||||
@@ -645,6 +666,12 @@ google.golang.org/grpc v1.27.0/go.mod h1:qbnxyOmOxrQa7FizSgH+ReBfzJrCY1pSN7KXBS8
|
||||
google.golang.org/grpc v1.27.1/go.mod h1:qbnxyOmOxrQa7FizSgH+ReBfzJrCY1pSN7KXBS8abTk=
|
||||
google.golang.org/grpc v1.28.0 h1:bO/TA4OxCOummhSf10siHuG7vJOiwh7SpRpFZDkOgl4=
|
||||
google.golang.org/grpc v1.28.0/go.mod h1:rpkK4SK4GF4Ach/+MFLZUBavHOvF2JJB5uozKKal+60=
|
||||
google.golang.org/protobuf v0.0.0-20200109180630-ec00e32a8dfd/go.mod h1:DFci5gLYBciE7Vtevhsrf46CRTquxDuWsQurQQe4oz8=
|
||||
google.golang.org/protobuf v0.0.0-20200221191635-4d8936d0db64/go.mod h1:kwYJMbMJ01Woi6D6+Kah6886xMZcty6N08ah7+eCXa0=
|
||||
google.golang.org/protobuf v0.0.0-20200228230310-ab0ca4ff8a60/go.mod h1:cfTl7dwQJ+fmap5saPgwCLgHXTUD7jkjRqWcaiX5VyM=
|
||||
google.golang.org/protobuf v1.20.1-0.20200309200217-e05f789c0967/go.mod h1:A+miEFZTKqfCUM6K7xSMQL9OKL/b6hQv+e19PK+JZNE=
|
||||
google.golang.org/protobuf v1.21.0 h1:qdOKuR/EIArgaWNjetjgTzgVTAZ+S/WXVrq9HW9zimw=
|
||||
google.golang.org/protobuf v1.21.0/go.mod h1:47Nbq4nVaFHyn7ilMalzfO3qCViNmqZ2kzikPIcrTAo=
|
||||
gopkg.in/alecthomas/kingpin.v2 v2.2.6/go.mod h1:FMv+mEhP44yOT+4EoQTLFTRgOQ1FBLkstjWtayDeSgw=
|
||||
gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
|
||||
gopkg.in/check.v1 v1.0.0-20180628173108-788fd7840127/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
|
||||
|
@@ -2,6 +2,9 @@ package v1
|
||||
|
||||
import (
|
||||
"encoding/base64"
|
||||
"errors"
|
||||
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
||||
"regexp"
|
||||
"strconv"
|
||||
|
||||
argoprojv1alpha1 "github.com/argoproj/argo/pkg/client/clientset/versioned/typed/workflow/v1alpha1"
|
||||
@@ -143,3 +146,27 @@ func (c *Client) GetS3Client(namespace string, config map[string]string) (s3Clie
|
||||
|
||||
return
|
||||
}
|
||||
|
||||
func GetBearerToken(namespace string) (string, error) {
|
||||
kubeConfig := NewConfig()
|
||||
client, err := NewClient(kubeConfig, nil)
|
||||
if err != nil {
|
||||
log.Fatalf("Failed to connect to Kubernetes cluster: %v", err)
|
||||
}
|
||||
|
||||
secrets, err := client.CoreV1().Secrets(namespace).List(v1.ListOptions{})
|
||||
if err != nil {
|
||||
log.WithFields(log.Fields{
|
||||
"Namespace": namespace,
|
||||
"Error": err.Error(),
|
||||
}).Error("Failed to get default service account token.")
|
||||
return "", err
|
||||
}
|
||||
re := regexp.MustCompile(`^default-token-`)
|
||||
for _, secret := range secrets.Items {
|
||||
if re.Find([]byte(secret.ObjectMeta.Name)) != nil {
|
||||
return string(secret.Data["token"]), nil
|
||||
}
|
||||
}
|
||||
return "", errors.New("could not find a token")
|
||||
}
|
||||
|
@@ -69,7 +69,7 @@ func (c *Client) UpdateCronWorkflow(namespace string, name string, cronWorkflow
|
||||
|
||||
for _, wf := range workflows {
|
||||
argoCronWorkflow.Spec.WorkflowSpec = wf.Spec
|
||||
argoCreatedCronWorkflow, err := c.updateCronWorkflow(namespace, name, &wf, &argoCronWorkflow, opts)
|
||||
argoCreatedCronWorkflow, err := c.updateCronWorkflow(namespace, name, &workflowTemplate.ID, &wf, &argoCronWorkflow, opts)
|
||||
if err != nil {
|
||||
log.WithFields(log.Fields{
|
||||
"Namespace": namespace,
|
||||
@@ -146,7 +146,7 @@ func (c *Client) CreateCronWorkflow(namespace string, cronWorkflow *CronWorkflow
|
||||
|
||||
for _, wf := range workflows {
|
||||
argoCronWorkflow.Spec.WorkflowSpec = wf.Spec
|
||||
argoCreatedCronWorkflow, err := c.createCronWorkflow(namespace, &wf, &argoCronWorkflow, opts)
|
||||
argoCreatedCronWorkflow, err := c.createCronWorkflow(namespace, &workflowTemplate.ID, &wf, &argoCronWorkflow, opts)
|
||||
if err != nil {
|
||||
log.WithFields(log.Fields{
|
||||
"Namespace": namespace,
|
||||
@@ -311,7 +311,7 @@ func (c *Client) ListCronWorkflows(namespace, workflowTemplateUID string) (cronW
|
||||
return
|
||||
}
|
||||
|
||||
func (c *Client) updateCronWorkflow(namespace string, name string, wf *wfv1.Workflow, cwf *wfv1.CronWorkflow, opts *WorkflowExecutionOptions) (updatedCronWorkflow *wfv1.CronWorkflow, err error) {
|
||||
func (c *Client) updateCronWorkflow(namespace string, name string, workflowTemplateId *uint64, wf *wfv1.Workflow, cwf *wfv1.CronWorkflow, opts *WorkflowExecutionOptions) (updatedCronWorkflow *wfv1.CronWorkflow, err error) {
|
||||
//Make sure the CronWorkflow exists before we edit it
|
||||
toUpdateCWF, err := c.ArgoprojV1alpha1().CronWorkflows(namespace).Get(name, metav1.GetOptions{})
|
||||
if err != nil {
|
||||
@@ -367,6 +367,26 @@ func (c *Client) updateCronWorkflow(namespace string, name string, wf *wfv1.Work
|
||||
if err = c.injectAutomatedFields(namespace, wf, opts); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
exitHandlerStepName, exitHandlerStepTemplate, exitHandlerStepWhen, err, exitHandlerTemplate := GetExitHandlerWorkflowStatistics(c, namespace, workflowTemplateId)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if exitHandlerStepTemplate != "" {
|
||||
exitHandler := wfv1.Template{
|
||||
Name: "exit-handler",
|
||||
Steps: []wfv1.ParallelSteps{
|
||||
{
|
||||
Steps: []wfv1.WorkflowStep{
|
||||
{Name: exitHandlerStepName, Template: exitHandlerStepTemplate, When: exitHandlerStepWhen},
|
||||
},
|
||||
},
|
||||
},
|
||||
}
|
||||
wf.Spec.OnExit = "exit-handler"
|
||||
wf.Spec.Templates = append(wf.Spec.Templates, exitHandler, exitHandlerTemplate)
|
||||
}
|
||||
|
||||
cwf.Spec.WorkflowSpec = wf.Spec
|
||||
cwf.Spec.WorkflowMetadata = &wf.ObjectMeta
|
||||
|
||||
@@ -390,7 +410,7 @@ func (c *Client) updateCronWorkflow(namespace string, name string, wf *wfv1.Work
|
||||
return
|
||||
}
|
||||
|
||||
func (c *Client) createCronWorkflow(namespace string, wf *wfv1.Workflow, cwf *wfv1.CronWorkflow, opts *WorkflowExecutionOptions) (createdCronWorkflow *wfv1.CronWorkflow, err error) {
|
||||
func (c *Client) createCronWorkflow(namespace string, workflowTemplateId *uint64, wf *wfv1.Workflow, cwf *wfv1.CronWorkflow, opts *WorkflowExecutionOptions) (createdCronWorkflow *wfv1.CronWorkflow, err error) {
|
||||
if opts == nil {
|
||||
opts = &WorkflowExecutionOptions{}
|
||||
}
|
||||
@@ -435,6 +455,26 @@ func (c *Client) createCronWorkflow(namespace string, wf *wfv1.Workflow, cwf *wf
|
||||
if err = c.injectAutomatedFields(namespace, wf, opts); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
exitHandlerStepName, exitHandlerStepTemplate, exitHandlerStepWhen, err, exitHandlerTemplate := GetExitHandlerWorkflowStatistics(c, namespace, workflowTemplateId)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if exitHandlerStepTemplate != "" {
|
||||
exitHandler := wfv1.Template{
|
||||
Name: "exit-handler",
|
||||
Steps: []wfv1.ParallelSteps{
|
||||
{
|
||||
Steps: []wfv1.WorkflowStep{
|
||||
{Name: exitHandlerStepName, Template: exitHandlerStepTemplate, When: exitHandlerStepWhen},
|
||||
},
|
||||
},
|
||||
},
|
||||
}
|
||||
wf.Spec.OnExit = "exit-handler"
|
||||
wf.Spec.Templates = append(wf.Spec.Templates, exitHandler, exitHandlerTemplate)
|
||||
}
|
||||
|
||||
cwf.Spec.WorkflowSpec = wf.Spec
|
||||
cwf.Spec.WorkflowMetadata = &wf.ObjectMeta
|
||||
|
||||
|
40
pkg/types.go
40
pkg/types.go
@@ -56,16 +56,36 @@ type CronWorkflow struct {
|
||||
}
|
||||
|
||||
type WorkflowTemplate struct {
|
||||
ID uint64
|
||||
CreatedAt time.Time `db:"created_at"`
|
||||
UID string
|
||||
Name string
|
||||
Manifest string
|
||||
Version int32
|
||||
IsLatest bool
|
||||
IsArchived bool `db:"is_archived"`
|
||||
ArgoWorkflowTemplate *wfv1.WorkflowTemplate
|
||||
Labels map[string]string
|
||||
ID uint64
|
||||
CreatedAt time.Time `db:"created_at"`
|
||||
UID string
|
||||
Name string
|
||||
Manifest string
|
||||
Version int32
|
||||
IsLatest bool
|
||||
IsArchived bool `db:"is_archived"`
|
||||
ArgoWorkflowTemplate *wfv1.WorkflowTemplate
|
||||
Labels map[string]string
|
||||
WorkflowExecutionStatisticReport *WorkflowExecutionStatisticReport
|
||||
}
|
||||
|
||||
type WorkflowExecutionStatisticReport struct {
|
||||
Total int32
|
||||
LastExecuted time.Time
|
||||
Running int32
|
||||
Completed int32
|
||||
Failed int32
|
||||
}
|
||||
|
||||
type WorkflowExecutionStatistic struct {
|
||||
ID uint64
|
||||
WorkflowTemplateId uint64
|
||||
Name string
|
||||
Namespace string
|
||||
//Interface to support null values for timestamps, when scanning from db into structs
|
||||
CreatedAt *time.Time `db:"created_at"`
|
||||
FinishedAt *time.Time `db:"finished_at"`
|
||||
FailedAt *time.Time `db:"failed_at"`
|
||||
}
|
||||
|
||||
func (wt *WorkflowTemplate) GetManifestBytes() []byte {
|
||||
|
@@ -6,7 +6,9 @@ import (
|
||||
"encoding/json"
|
||||
"errors"
|
||||
"fmt"
|
||||
sq "github.com/Masterminds/squirrel"
|
||||
"github.com/ghodss/yaml"
|
||||
"github.com/onepanelio/core/api"
|
||||
"github.com/onepanelio/core/pkg/util/label"
|
||||
"io"
|
||||
"io/ioutil"
|
||||
@@ -190,7 +192,7 @@ func addEnvToTemplate(template *wfv1.Template, key string, value string) {
|
||||
}
|
||||
}
|
||||
|
||||
func (c *Client) createWorkflow(namespace string, wf *wfv1.Workflow, opts *WorkflowExecutionOptions) (createdWorkflow *wfv1.Workflow, err error) {
|
||||
func (c *Client) createWorkflow(namespace string, workflowTemplateId *uint64, wf *wfv1.Workflow, opts *WorkflowExecutionOptions) (createdWorkflow *wfv1.Workflow, err error) {
|
||||
if opts == nil {
|
||||
opts = &WorkflowExecutionOptions{}
|
||||
}
|
||||
@@ -235,6 +237,25 @@ func (c *Client) createWorkflow(namespace string, wf *wfv1.Workflow, opts *Workf
|
||||
return nil, err
|
||||
}
|
||||
|
||||
exitHandlerStepName, exitHandlerStepTemplate, exitHandlerStepWhen, err, exitHandlerTemplate := GetExitHandlerWorkflowStatistics(c, namespace, workflowTemplateId)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if exitHandlerStepTemplate != "" {
|
||||
exitHandler := wfv1.Template{
|
||||
Name: "exit-handler",
|
||||
Steps: []wfv1.ParallelSteps{
|
||||
{
|
||||
Steps: []wfv1.WorkflowStep{
|
||||
{Name: exitHandlerStepName, Template: exitHandlerStepTemplate, When: exitHandlerStepWhen},
|
||||
},
|
||||
},
|
||||
},
|
||||
}
|
||||
wf.Spec.OnExit = "exit-handler"
|
||||
wf.Spec.Templates = append(wf.Spec.Templates, exitHandler, exitHandlerTemplate)
|
||||
}
|
||||
|
||||
createdWorkflow, err = c.ArgoprojV1alpha1().Workflows(namespace).Create(wf)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
@@ -318,7 +339,7 @@ func (c *Client) CreateWorkflowExecution(namespace string, workflow *WorkflowExe
|
||||
|
||||
var createdWorkflows []*wfv1.Workflow
|
||||
for _, wf := range workflows {
|
||||
createdWorkflow, err := c.createWorkflow(namespace, &wf, opts)
|
||||
createdWorkflow, err := c.createWorkflow(namespace, &workflowTemplate.ID, &wf, opts)
|
||||
if err != nil {
|
||||
log.WithFields(log.Fields{
|
||||
"Namespace": namespace,
|
||||
@@ -351,6 +372,49 @@ func (c *Client) CreateWorkflowExecution(namespace string, workflow *WorkflowExe
|
||||
return workflow, nil
|
||||
}
|
||||
|
||||
func (c *Client) AddWorkflowExecutionStatistic(namespace, name string, workflowTemplateID int64, createdAt time.Time, workflowOutcomeIsSuccess bool) (err error) {
|
||||
tx, err := c.DB.Begin()
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
defer tx.Rollback()
|
||||
if workflowOutcomeIsSuccess {
|
||||
_, err := sb.Insert("workflow_executions").
|
||||
SetMap(sq.Eq{
|
||||
"workflow_template_id": workflowTemplateID,
|
||||
"name": name,
|
||||
"namespace": namespace,
|
||||
"created_at": createdAt.UTC(),
|
||||
"finished_at": time.Now().UTC(),
|
||||
}).RunWith(tx).Exec()
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
err = tx.Commit()
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
return err
|
||||
} else {
|
||||
_, err := sb.Insert("workflow_executions").
|
||||
SetMap(sq.Eq{
|
||||
"workflow_template_id": workflowTemplateID,
|
||||
"name": name,
|
||||
"namespace": namespace,
|
||||
"created_at": createdAt.UTC(),
|
||||
"failed_at": time.Now().UTC(),
|
||||
}).RunWith(tx).Exec()
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
err = tx.Commit()
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
return err
|
||||
}
|
||||
}
|
||||
|
||||
func (c *Client) GetWorkflowExecution(namespace, name string) (workflow *WorkflowExecution, err error) {
|
||||
wf, err := c.ArgoprojV1alpha1().Workflows(namespace).Get(name, metav1.GetOptions{})
|
||||
if err != nil {
|
||||
@@ -1052,3 +1116,96 @@ func (c *Client) SetWorkflowTemplateLabels(namespace, name, prefix string, keyVa
|
||||
|
||||
return filteredMap, nil
|
||||
}
|
||||
|
||||
func (c *Client) GetWorkflowExecutionStatisticsForTemplate(workflowTemplate *WorkflowTemplate) (err error) {
|
||||
tx, err := c.DB.Begin()
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
defer tx.Rollback()
|
||||
|
||||
query, args, err := sb.Select("name, created_at, finished_at").
|
||||
From("workflow_executions").Where(sq.Eq{"workflow_template_id": workflowTemplate.ID}).OrderBy("created_at DESC").ToSql()
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
var workflowExecStats []WorkflowExecutionStatistic
|
||||
err = c.DB.Select(&workflowExecStats, query, args...)
|
||||
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
workflowTemplate.WorkflowExecutionStatisticReport = &WorkflowExecutionStatisticReport{}
|
||||
if len(workflowExecStats) == 0 {
|
||||
return
|
||||
}
|
||||
|
||||
//Calculate and set the values
|
||||
workflowTemplate.WorkflowExecutionStatisticReport.Total = int32(len(workflowExecStats))
|
||||
createdAtTime := workflowExecStats[0].CreatedAt
|
||||
workflowTemplate.WorkflowExecutionStatisticReport.LastExecuted = *createdAtTime
|
||||
for _, workflowExecStat := range workflowExecStats {
|
||||
if workflowExecStat.FailedAt != nil {
|
||||
workflowTemplate.WorkflowExecutionStatisticReport.Failed++
|
||||
}
|
||||
if workflowExecStat.FinishedAt == nil {
|
||||
workflowTemplate.WorkflowExecutionStatisticReport.Running++
|
||||
}
|
||||
if workflowExecStat.FinishedAt != nil {
|
||||
workflowTemplate.WorkflowExecutionStatisticReport.Completed++
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
/**
|
||||
Will build a template that makes a CURL request to the onepanel-core API,
|
||||
with statistics about the workflow that was just executed.
|
||||
*/
|
||||
func GetExitHandlerWorkflowStatistics(client *Client, namespace string, workflowTemplateId *uint64) (workflowStepName, workflowStepTemplate, workflowStepWhen string, err error, wfv1Template wfv1.Template) {
|
||||
workflowStepName = "workflow-statistics"
|
||||
workflowStepTemplate = "workflow-statistics-template"
|
||||
host := env.GetEnv("ONEPANEL_CORE_SERVICE_HOST", "")
|
||||
if host == "" {
|
||||
err = errors.New("ONEPANEL_CORE_SERVICE_HOST is empty.")
|
||||
return
|
||||
}
|
||||
port := env.GetEnv("ONEPANEL_CORE_SERVICE_PORT", "")
|
||||
if port == "" {
|
||||
err = errors.New("ONEPANEL_CORE_SERVICE_PORT is empty.")
|
||||
return
|
||||
}
|
||||
curlEndpoint := fmt.Sprintf("http://%s:%s/apis/v1beta1/%s/workflow_executions/{{workflow.name}}/statistics", host, port, namespace)
|
||||
|
||||
jsonRequestStruct := api.Statistics{
|
||||
WorkflowStatus: "{{workflow.status}}",
|
||||
CreatedAt: "{{workflow.creationTimestamp}}",
|
||||
WorkflowTemplateId: int64(*workflowTemplateId),
|
||||
}
|
||||
jsonRequestBytes, err := json.Marshal(jsonRequestStruct)
|
||||
if err != nil {
|
||||
return "", "", "", err, wfv1.Template{}
|
||||
}
|
||||
jsonRequestStr := string(jsonRequestBytes)
|
||||
curlJSONBody := fmt.Sprintf("--data '%s'", jsonRequestStr)
|
||||
|
||||
token, err := GetBearerToken(namespace)
|
||||
if err != nil {
|
||||
return "", "", "", err, wfv1.Template{}
|
||||
}
|
||||
|
||||
wfv1Template = wfv1.Template{
|
||||
Name: workflowStepTemplate,
|
||||
Container: &corev1.Container{
|
||||
Image: "alpine:latest",
|
||||
Command: []string{"sh", "-c"},
|
||||
Args: []string{"apk add curl;" +
|
||||
"curl '" + curlEndpoint + "' -H \"Content-Type: application/json\" -H 'Connection: keep-alive' -H 'Accept: application/json' " +
|
||||
"-H 'Sec-Fetch-Dest: empty' -H 'Authorization: Bearer " + token + "' -H 'User-Agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/80.0.3987.163 Safari/537.36' -H 'Sec-Fetch-Site: same-site' -H 'Sec-Fetch-Mode: cors' -H 'Accept-Language: en-US,en;q=0.9' " +
|
||||
curlJSONBody + " --compressed",
|
||||
},
|
||||
},
|
||||
}
|
||||
return
|
||||
}
|
||||
|
@@ -87,7 +87,9 @@ func (c *Client) workflowTemplatesSelectBuilder(namespace string) sq.SelectBuild
|
||||
}
|
||||
|
||||
func (c *Client) getWorkflowTemplate(namespace, uid string, version int32) (workflowTemplate *WorkflowTemplate, err error) {
|
||||
workflowTemplate = &WorkflowTemplate{}
|
||||
workflowTemplate = &WorkflowTemplate{
|
||||
WorkflowExecutionStatisticReport: &WorkflowExecutionStatisticReport{},
|
||||
}
|
||||
|
||||
sb := c.workflowTemplatesSelectBuilder(namespace).Where(sq.Eq{"wt.uid": uid})
|
||||
query, args, err := sb.ToSql()
|
||||
@@ -121,14 +123,14 @@ func (c *Client) getWorkflowTemplate(namespace, uid string, version int32) (work
|
||||
workflowTemplate.Manifest = string(manifest)
|
||||
workflowTemplate.ArgoWorkflowTemplate = argoWft
|
||||
|
||||
templateVersion, err := strconv.Atoi(argoWft.Labels["onepanel.io/version"])
|
||||
templateVersion, err := strconv.Atoi(argoWft.Labels[label.Version])
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
workflowTemplate.Version = int32(templateVersion)
|
||||
|
||||
return
|
||||
return workflowTemplate, nil
|
||||
}
|
||||
|
||||
func (c *Client) getWorkflowTemplateByName(namespace, name string, version int32) (workflowTemplate *WorkflowTemplate, err error) {
|
||||
@@ -387,6 +389,17 @@ func (c *Client) ListWorkflowTemplates(namespace string) (workflowTemplateVersio
|
||||
return nil, util.NewUserError(codes.NotFound, "Workflow templates not found.")
|
||||
}
|
||||
|
||||
for _, workflowTemplate := range workflowTemplateVersions {
|
||||
err = c.GetWorkflowExecutionStatisticsForTemplate(workflowTemplate)
|
||||
if err != nil {
|
||||
log.WithFields(log.Fields{
|
||||
"Namespace": namespace,
|
||||
"Error": err.Error(),
|
||||
}).Error("Unable to get Workflow Execution Statistic for Template.")
|
||||
return nil, util.NewUserError(codes.NotFound, "Unable to get Workflow Execution Statistic for Template.")
|
||||
}
|
||||
}
|
||||
|
||||
return
|
||||
}
|
||||
|
||||
|
@@ -79,6 +79,31 @@ func (s *WorkflowServer) CreateWorkflowExecution(ctx context.Context, req *api.C
|
||||
return apiWorkflowExecution(wf), nil
|
||||
}
|
||||
|
||||
func (s *WorkflowServer) AddWorkflowExecutionStatistics(ctx context.Context, request *api.AddWorkflowExecutionStatisticRequest) (*empty.Empty, error) {
|
||||
client := ctx.Value("kubeClient").(*v1.Client)
|
||||
workflowOutcomeIsSuccess := false
|
||||
// todo - Succeeded ?
|
||||
if request.Statistics.WorkflowStatus == "Success" {
|
||||
workflowOutcomeIsSuccess = true
|
||||
}
|
||||
|
||||
/*
|
||||
The format from Argo needs to be parsed.
|
||||
It's not RFC3339
|
||||
*/
|
||||
layout := "2006-01-02 15:04:05 -0700 MST"
|
||||
createdAt, err := time.Parse(layout, request.Statistics.CreatedAt)
|
||||
if err != nil {
|
||||
return &empty.Empty{}, err
|
||||
}
|
||||
err = client.AddWorkflowExecutionStatistic(request.Namespace, request.Name,
|
||||
request.Statistics.WorkflowTemplateId, createdAt, workflowOutcomeIsSuccess)
|
||||
if err != nil {
|
||||
return &empty.Empty{}, err
|
||||
}
|
||||
return &empty.Empty{}, nil
|
||||
}
|
||||
|
||||
func (s *WorkflowServer) GetWorkflowExecution(ctx context.Context, req *api.GetWorkflowExecutionRequest) (*api.WorkflowExecution, error) {
|
||||
client := ctx.Value("kubeClient").(*v1.Client)
|
||||
allowed, err := auth.IsAuthorized(client, req.Namespace, "get", "argoproj.io", "workflows", req.Name)
|
||||
|
@@ -24,7 +24,7 @@ func apiWorkflowTemplate(wft *v1.WorkflowTemplate) *api.WorkflowTemplate {
|
||||
manifest = ""
|
||||
}
|
||||
|
||||
return &api.WorkflowTemplate{
|
||||
res := &api.WorkflowTemplate{
|
||||
Uid: wft.UID,
|
||||
CreatedAt: wft.CreatedAt.UTC().Format(time.RFC3339),
|
||||
Name: wft.Name,
|
||||
@@ -33,6 +33,18 @@ func apiWorkflowTemplate(wft *v1.WorkflowTemplate) *api.WorkflowTemplate {
|
||||
IsLatest: wft.IsLatest,
|
||||
IsArchived: wft.IsArchived,
|
||||
}
|
||||
|
||||
if wft.WorkflowExecutionStatisticReport != nil {
|
||||
res.Stats = &api.WorkflowExecutionStatisticReport{
|
||||
Total: wft.WorkflowExecutionStatisticReport.Total,
|
||||
LastExecuted: wft.WorkflowExecutionStatisticReport.LastExecuted.String(),
|
||||
Running: wft.WorkflowExecutionStatisticReport.Running,
|
||||
Completed: wft.WorkflowExecutionStatisticReport.Completed,
|
||||
Failed: wft.WorkflowExecutionStatisticReport.Failed,
|
||||
}
|
||||
}
|
||||
|
||||
return res
|
||||
}
|
||||
|
||||
func mapToKeyValue(input map[string]string) []*api.KeyValue {
|
||||
|
Reference in New Issue
Block a user