job

package
v1.5.6 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 8, 2024 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

View Source
const (
	Job_InitDatabase_FullMethodName   = "/job.Job/initDatabase"
	Job_CreateTask_FullMethodName     = "/job.Job/createTask"
	Job_UpdateTask_FullMethodName     = "/job.Job/updateTask"
	Job_GetTaskList_FullMethodName    = "/job.Job/getTaskList"
	Job_GetTaskById_FullMethodName    = "/job.Job/getTaskById"
	Job_DeleteTask_FullMethodName     = "/job.Job/deleteTask"
	Job_CreateTaskLog_FullMethodName  = "/job.Job/createTaskLog"
	Job_UpdateTaskLog_FullMethodName  = "/job.Job/updateTaskLog"
	Job_GetTaskLogList_FullMethodName = "/job.Job/getTaskLogList"
	Job_GetTaskLogById_FullMethodName = "/job.Job/getTaskLogById"
	Job_DeleteTaskLog_FullMethodName  = "/job.Job/deleteTaskLog"
)

Variables

View Source
var Job_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "job.Job",
	HandlerType: (*JobServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "initDatabase",
			Handler:    _Job_InitDatabase_Handler,
		},
		{
			MethodName: "createTask",
			Handler:    _Job_CreateTask_Handler,
		},
		{
			MethodName: "updateTask",
			Handler:    _Job_UpdateTask_Handler,
		},
		{
			MethodName: "getTaskList",
			Handler:    _Job_GetTaskList_Handler,
		},
		{
			MethodName: "getTaskById",
			Handler:    _Job_GetTaskById_Handler,
		},
		{
			MethodName: "deleteTask",
			Handler:    _Job_DeleteTask_Handler,
		},
		{
			MethodName: "createTaskLog",
			Handler:    _Job_CreateTaskLog_Handler,
		},
		{
			MethodName: "updateTaskLog",
			Handler:    _Job_UpdateTaskLog_Handler,
		},
		{
			MethodName: "getTaskLogList",
			Handler:    _Job_GetTaskLogList_Handler,
		},
		{
			MethodName: "getTaskLogById",
			Handler:    _Job_GetTaskLogById_Handler,
		},
		{
			MethodName: "deleteTaskLog",
			Handler:    _Job_DeleteTaskLog_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "job.proto",
}

Job_ServiceDesc is the grpc.ServiceDesc for Job service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)

Functions

func RegisterJobServer

func RegisterJobServer(s grpc.ServiceRegistrar, srv JobServer)

Types

type BaseIDResp

type BaseIDResp struct {
	Id  uint64 `protobuf:"varint,1,opt,name=id,proto3" json:"id"`
	Msg string `protobuf:"bytes,2,opt,name=msg,proto3" json:"msg"`
	// contains filtered or unexported fields
}

func (*BaseIDResp) Descriptor deprecated

func (*BaseIDResp) Descriptor() ([]byte, []int)

Deprecated: Use BaseIDResp.ProtoReflect.Descriptor instead.

func (*BaseIDResp) GetId

func (x *BaseIDResp) GetId() uint64

func (*BaseIDResp) GetMsg

func (x *BaseIDResp) GetMsg() string

func (*BaseIDResp) ProtoMessage

func (*BaseIDResp) ProtoMessage()

func (*BaseIDResp) ProtoReflect

func (x *BaseIDResp) ProtoReflect() protoreflect.Message

func (*BaseIDResp) Reset

func (x *BaseIDResp) Reset()

func (*BaseIDResp) String

func (x *BaseIDResp) String() string

type BaseResp

type BaseResp struct {
	Msg string `protobuf:"bytes,1,opt,name=msg,proto3" json:"msg"`
	// contains filtered or unexported fields
}

func (*BaseResp) Descriptor deprecated

func (*BaseResp) Descriptor() ([]byte, []int)

Deprecated: Use BaseResp.ProtoReflect.Descriptor instead.

func (*BaseResp) GetMsg

func (x *BaseResp) GetMsg() string

func (*BaseResp) ProtoMessage

func (*BaseResp) ProtoMessage()

func (*BaseResp) ProtoReflect

func (x *BaseResp) ProtoReflect() protoreflect.Message

func (*BaseResp) Reset

func (x *BaseResp) Reset()

func (*BaseResp) String

func (x *BaseResp) String() string

type BaseUUIDResp

type BaseUUIDResp struct {
	Id  string `protobuf:"bytes,1,opt,name=id,proto3" json:"id"`
	Msg string `protobuf:"bytes,2,opt,name=msg,proto3" json:"msg"`
	// contains filtered or unexported fields
}

func (*BaseUUIDResp) Descriptor deprecated

func (*BaseUUIDResp) Descriptor() ([]byte, []int)

Deprecated: Use BaseUUIDResp.ProtoReflect.Descriptor instead.

func (*BaseUUIDResp) GetId

func (x *BaseUUIDResp) GetId() string

func (*BaseUUIDResp) GetMsg

func (x *BaseUUIDResp) GetMsg() string

func (*BaseUUIDResp) ProtoMessage

func (*BaseUUIDResp) ProtoMessage()

func (*BaseUUIDResp) ProtoReflect

func (x *BaseUUIDResp) ProtoReflect() protoreflect.Message

func (*BaseUUIDResp) Reset

func (x *BaseUUIDResp) Reset()

func (*BaseUUIDResp) String

func (x *BaseUUIDResp) String() string

type Empty

type Empty struct {
	// contains filtered or unexported fields
}

base message

func (*Empty) Descriptor deprecated

func (*Empty) Descriptor() ([]byte, []int)

Deprecated: Use Empty.ProtoReflect.Descriptor instead.

func (*Empty) ProtoMessage

func (*Empty) ProtoMessage()

func (*Empty) ProtoReflect

func (x *Empty) ProtoReflect() protoreflect.Message

func (*Empty) Reset

func (x *Empty) Reset()

func (*Empty) String

func (x *Empty) String() string

type IDReq

type IDReq struct {
	Id uint64 `protobuf:"varint,1,opt,name=id,proto3" json:"id"`
	// contains filtered or unexported fields
}

func (*IDReq) Descriptor deprecated

func (*IDReq) Descriptor() ([]byte, []int)

Deprecated: Use IDReq.ProtoReflect.Descriptor instead.

func (*IDReq) GetId

func (x *IDReq) GetId() uint64

func (*IDReq) ProtoMessage

func (*IDReq) ProtoMessage()

func (*IDReq) ProtoReflect

func (x *IDReq) ProtoReflect() protoreflect.Message

func (*IDReq) Reset

func (x *IDReq) Reset()

func (*IDReq) String

func (x *IDReq) String() string

type IDsReq

type IDsReq struct {
	Ids []uint64 `protobuf:"varint,1,rep,packed,name=ids,proto3" json:"ids"`
	// contains filtered or unexported fields
}

func (*IDsReq) Descriptor deprecated

func (*IDsReq) Descriptor() ([]byte, []int)

Deprecated: Use IDsReq.ProtoReflect.Descriptor instead.

func (*IDsReq) GetIds

func (x *IDsReq) GetIds() []uint64

func (*IDsReq) ProtoMessage

func (*IDsReq) ProtoMessage()

func (*IDsReq) ProtoReflect

func (x *IDsReq) ProtoReflect() protoreflect.Message

func (*IDsReq) Reset

func (x *IDsReq) Reset()

func (*IDsReq) String

func (x *IDsReq) String() string

type JobClient

type JobClient interface {
	// group: base
	InitDatabase(ctx context.Context, in *Empty, opts ...grpc.CallOption) (*BaseResp, error)
	// Task management
	// group: task
	CreateTask(ctx context.Context, in *TaskInfo, opts ...grpc.CallOption) (*BaseIDResp, error)
	// group: task
	UpdateTask(ctx context.Context, in *TaskInfo, opts ...grpc.CallOption) (*BaseResp, error)
	// group: task
	GetTaskList(ctx context.Context, in *TaskListReq, opts ...grpc.CallOption) (*TaskListResp, error)
	// group: task
	GetTaskById(ctx context.Context, in *IDReq, opts ...grpc.CallOption) (*TaskInfo, error)
	// group: task
	DeleteTask(ctx context.Context, in *IDsReq, opts ...grpc.CallOption) (*BaseResp, error)
	// TaskLog management
	// group: tasklog
	CreateTaskLog(ctx context.Context, in *TaskLogInfo, opts ...grpc.CallOption) (*BaseIDResp, error)
	// group: tasklog
	UpdateTaskLog(ctx context.Context, in *TaskLogInfo, opts ...grpc.CallOption) (*BaseResp, error)
	// group: tasklog
	GetTaskLogList(ctx context.Context, in *TaskLogListReq, opts ...grpc.CallOption) (*TaskLogListResp, error)
	// group: tasklog
	GetTaskLogById(ctx context.Context, in *IDReq, opts ...grpc.CallOption) (*TaskLogInfo, error)
	// group: tasklog
	DeleteTaskLog(ctx context.Context, in *IDsReq, opts ...grpc.CallOption) (*BaseResp, error)
}

JobClient is the client API for Job service.

For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.

func NewJobClient

func NewJobClient(cc grpc.ClientConnInterface) JobClient

type JobServer

type JobServer interface {
	// group: base
	InitDatabase(context.Context, *Empty) (*BaseResp, error)
	// Task management
	// group: task
	CreateTask(context.Context, *TaskInfo) (*BaseIDResp, error)
	// group: task
	UpdateTask(context.Context, *TaskInfo) (*BaseResp, error)
	// group: task
	GetTaskList(context.Context, *TaskListReq) (*TaskListResp, error)
	// group: task
	GetTaskById(context.Context, *IDReq) (*TaskInfo, error)
	// group: task
	DeleteTask(context.Context, *IDsReq) (*BaseResp, error)
	// TaskLog management
	// group: tasklog
	CreateTaskLog(context.Context, *TaskLogInfo) (*BaseIDResp, error)
	// group: tasklog
	UpdateTaskLog(context.Context, *TaskLogInfo) (*BaseResp, error)
	// group: tasklog
	GetTaskLogList(context.Context, *TaskLogListReq) (*TaskLogListResp, error)
	// group: tasklog
	GetTaskLogById(context.Context, *IDReq) (*TaskLogInfo, error)
	// group: tasklog
	DeleteTaskLog(context.Context, *IDsReq) (*BaseResp, error)
	// contains filtered or unexported methods
}

JobServer is the server API for Job service. All implementations must embed UnimplementedJobServer for forward compatibility

type PageInfoReq

type PageInfoReq struct {
	Page     uint64 `protobuf:"varint,1,opt,name=page,proto3" json:"page"`
	PageSize uint64 `protobuf:"varint,2,opt,name=page_size,json=pageSize,proto3" json:"page_size"`
	// contains filtered or unexported fields
}

func (*PageInfoReq) Descriptor deprecated

func (*PageInfoReq) Descriptor() ([]byte, []int)

Deprecated: Use PageInfoReq.ProtoReflect.Descriptor instead.

func (*PageInfoReq) GetPage

func (x *PageInfoReq) GetPage() uint64

func (*PageInfoReq) GetPageSize

func (x *PageInfoReq) GetPageSize() uint64

func (*PageInfoReq) ProtoMessage

func (*PageInfoReq) ProtoMessage()

func (*PageInfoReq) ProtoReflect

func (x *PageInfoReq) ProtoReflect() protoreflect.Message

func (*PageInfoReq) Reset

func (x *PageInfoReq) Reset()

func (*PageInfoReq) String

func (x *PageInfoReq) String() string

type TaskInfo

type TaskInfo struct {
	Id             *uint64 `protobuf:"varint,1,opt,name=id,proto3,oneof" json:"id"`
	CreatedAt      *int64  `protobuf:"varint,2,opt,name=created_at,json=createdAt,proto3,oneof" json:"created_at"`
	UpdatedAt      *int64  `protobuf:"varint,3,opt,name=updated_at,json=updatedAt,proto3,oneof" json:"updated_at"`
	Status         *uint32 `protobuf:"varint,4,opt,name=status,proto3,oneof" json:"status"`
	Name           *string `protobuf:"bytes,5,opt,name=name,proto3,oneof" json:"name"`
	TaskGroup      *string `protobuf:"bytes,6,opt,name=task_group,json=taskGroup,proto3,oneof" json:"task_group"`
	CronExpression *string `protobuf:"bytes,7,opt,name=cron_expression,json=cronExpression,proto3,oneof" json:"cron_expression"`
	Pattern        *string `protobuf:"bytes,8,opt,name=pattern,proto3,oneof" json:"pattern"`
	Payload        *string `protobuf:"bytes,9,opt,name=payload,proto3,oneof" json:"payload"`
	// contains filtered or unexported fields
}

func (*TaskInfo) Descriptor deprecated

func (*TaskInfo) Descriptor() ([]byte, []int)

Deprecated: Use TaskInfo.ProtoReflect.Descriptor instead.

func (*TaskInfo) GetCreatedAt

func (x *TaskInfo) GetCreatedAt() int64

func (*TaskInfo) GetCronExpression

func (x *TaskInfo) GetCronExpression() string

func (*TaskInfo) GetId

func (x *TaskInfo) GetId() uint64

func (*TaskInfo) GetName

func (x *TaskInfo) GetName() string

func (*TaskInfo) GetPattern

func (x *TaskInfo) GetPattern() string

func (*TaskInfo) GetPayload

func (x *TaskInfo) GetPayload() string

func (*TaskInfo) GetStatus

func (x *TaskInfo) GetStatus() uint32

func (*TaskInfo) GetTaskGroup

func (x *TaskInfo) GetTaskGroup() string

func (*TaskInfo) GetUpdatedAt

func (x *TaskInfo) GetUpdatedAt() int64

func (*TaskInfo) ProtoMessage

func (*TaskInfo) ProtoMessage()

func (*TaskInfo) ProtoReflect

func (x *TaskInfo) ProtoReflect() protoreflect.Message

func (*TaskInfo) Reset

func (x *TaskInfo) Reset()

func (*TaskInfo) String

func (x *TaskInfo) String() string

type TaskListReq

type TaskListReq struct {
	Page      uint64  `protobuf:"varint,1,opt,name=page,proto3" json:"page"`
	PageSize  uint64  `protobuf:"varint,2,opt,name=page_size,json=pageSize,proto3" json:"page_size"`
	Name      *string `protobuf:"bytes,3,opt,name=name,proto3,oneof" json:"name"`
	TaskGroup *string `protobuf:"bytes,4,opt,name=task_group,json=taskGroup,proto3,oneof" json:"task_group"`
	// contains filtered or unexported fields
}

func (*TaskListReq) Descriptor deprecated

func (*TaskListReq) Descriptor() ([]byte, []int)

Deprecated: Use TaskListReq.ProtoReflect.Descriptor instead.

func (*TaskListReq) GetName

func (x *TaskListReq) GetName() string

func (*TaskListReq) GetPage

func (x *TaskListReq) GetPage() uint64

func (*TaskListReq) GetPageSize

func (x *TaskListReq) GetPageSize() uint64

func (*TaskListReq) GetTaskGroup

func (x *TaskListReq) GetTaskGroup() string

func (*TaskListReq) ProtoMessage

func (*TaskListReq) ProtoMessage()

func (*TaskListReq) ProtoReflect

func (x *TaskListReq) ProtoReflect() protoreflect.Message

func (*TaskListReq) Reset

func (x *TaskListReq) Reset()

func (*TaskListReq) String

func (x *TaskListReq) String() string

type TaskListResp

type TaskListResp struct {
	Total uint64      `protobuf:"varint,1,opt,name=total,proto3" json:"total"`
	Data  []*TaskInfo `protobuf:"bytes,2,rep,name=data,proto3" json:"data"`
	// contains filtered or unexported fields
}

func (*TaskListResp) Descriptor deprecated

func (*TaskListResp) Descriptor() ([]byte, []int)

Deprecated: Use TaskListResp.ProtoReflect.Descriptor instead.

func (*TaskListResp) GetData

func (x *TaskListResp) GetData() []*TaskInfo

func (*TaskListResp) GetTotal

func (x *TaskListResp) GetTotal() uint64

func (*TaskListResp) ProtoMessage

func (*TaskListResp) ProtoMessage()

func (*TaskListResp) ProtoReflect

func (x *TaskListResp) ProtoReflect() protoreflect.Message

func (*TaskListResp) Reset

func (x *TaskListResp) Reset()

func (*TaskListResp) String

func (x *TaskListResp) String() string

type TaskLogInfo

type TaskLogInfo struct {
	Id         *uint64 `protobuf:"varint,1,opt,name=id,proto3,oneof" json:"id"`
	CreatedAt  *int64  `protobuf:"varint,2,opt,name=created_at,json=createdAt,proto3,oneof" json:"created_at"`
	UpdatedAt  *int64  `protobuf:"varint,3,opt,name=updated_at,json=updatedAt,proto3,oneof" json:"updated_at"`
	StartedAt  *int64  `protobuf:"varint,4,opt,name=started_at,json=startedAt,proto3,oneof" json:"started_at"`
	FinishedAt *int64  `protobuf:"varint,5,opt,name=finished_at,json=finishedAt,proto3,oneof" json:"finished_at"`
	Result     *uint32 `protobuf:"varint,6,opt,name=result,proto3,oneof" json:"result"`
	// contains filtered or unexported fields
}

func (*TaskLogInfo) Descriptor deprecated

func (*TaskLogInfo) Descriptor() ([]byte, []int)

Deprecated: Use TaskLogInfo.ProtoReflect.Descriptor instead.

func (*TaskLogInfo) GetCreatedAt added in v1.0.9

func (x *TaskLogInfo) GetCreatedAt() int64

func (*TaskLogInfo) GetFinishedAt

func (x *TaskLogInfo) GetFinishedAt() int64

func (*TaskLogInfo) GetId

func (x *TaskLogInfo) GetId() uint64

func (*TaskLogInfo) GetResult

func (x *TaskLogInfo) GetResult() uint32

func (*TaskLogInfo) GetStartedAt

func (x *TaskLogInfo) GetStartedAt() int64

func (*TaskLogInfo) GetUpdatedAt added in v1.0.9

func (x *TaskLogInfo) GetUpdatedAt() int64

func (*TaskLogInfo) ProtoMessage

func (*TaskLogInfo) ProtoMessage()

func (*TaskLogInfo) ProtoReflect

func (x *TaskLogInfo) ProtoReflect() protoreflect.Message

func (*TaskLogInfo) Reset

func (x *TaskLogInfo) Reset()

func (*TaskLogInfo) String

func (x *TaskLogInfo) String() string

type TaskLogListReq

type TaskLogListReq struct {
	Page     uint64  `protobuf:"varint,1,opt,name=page,proto3" json:"page"`
	PageSize uint64  `protobuf:"varint,2,opt,name=page_size,json=pageSize,proto3" json:"page_size"`
	TaskId   *uint64 `protobuf:"varint,3,opt,name=task_id,json=taskId,proto3,oneof" json:"task_id"`
	Result   *uint32 `protobuf:"varint,4,opt,name=result,proto3,oneof" json:"result"`
	// contains filtered or unexported fields
}

func (*TaskLogListReq) Descriptor deprecated

func (*TaskLogListReq) Descriptor() ([]byte, []int)

Deprecated: Use TaskLogListReq.ProtoReflect.Descriptor instead.

func (*TaskLogListReq) GetPage

func (x *TaskLogListReq) GetPage() uint64

func (*TaskLogListReq) GetPageSize

func (x *TaskLogListReq) GetPageSize() uint64

func (*TaskLogListReq) GetResult

func (x *TaskLogListReq) GetResult() uint32

func (*TaskLogListReq) GetTaskId

func (x *TaskLogListReq) GetTaskId() uint64

func (*TaskLogListReq) ProtoMessage

func (*TaskLogListReq) ProtoMessage()

func (*TaskLogListReq) ProtoReflect

func (x *TaskLogListReq) ProtoReflect() protoreflect.Message

func (*TaskLogListReq) Reset

func (x *TaskLogListReq) Reset()

func (*TaskLogListReq) String

func (x *TaskLogListReq) String() string

type TaskLogListResp

type TaskLogListResp struct {
	Total uint64         `protobuf:"varint,1,opt,name=total,proto3" json:"total"`
	Data  []*TaskLogInfo `protobuf:"bytes,2,rep,name=data,proto3" json:"data"`
	// contains filtered or unexported fields
}

func (*TaskLogListResp) Descriptor deprecated

func (*TaskLogListResp) Descriptor() ([]byte, []int)

Deprecated: Use TaskLogListResp.ProtoReflect.Descriptor instead.

func (*TaskLogListResp) GetData

func (x *TaskLogListResp) GetData() []*TaskLogInfo

func (*TaskLogListResp) GetTotal

func (x *TaskLogListResp) GetTotal() uint64

func (*TaskLogListResp) ProtoMessage

func (*TaskLogListResp) ProtoMessage()

func (*TaskLogListResp) ProtoReflect

func (x *TaskLogListResp) ProtoReflect() protoreflect.Message

func (*TaskLogListResp) Reset

func (x *TaskLogListResp) Reset()

func (*TaskLogListResp) String

func (x *TaskLogListResp) String() string

type UUIDReq

type UUIDReq struct {
	Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id"`
	// contains filtered or unexported fields
}

func (*UUIDReq) Descriptor deprecated

func (*UUIDReq) Descriptor() ([]byte, []int)

Deprecated: Use UUIDReq.ProtoReflect.Descriptor instead.

func (*UUIDReq) GetId

func (x *UUIDReq) GetId() string

func (*UUIDReq) ProtoMessage

func (*UUIDReq) ProtoMessage()

func (*UUIDReq) ProtoReflect

func (x *UUIDReq) ProtoReflect() protoreflect.Message

func (*UUIDReq) Reset

func (x *UUIDReq) Reset()

func (*UUIDReq) String

func (x *UUIDReq) String() string

type UUIDsReq

type UUIDsReq struct {
	Ids []string `protobuf:"bytes,1,rep,name=ids,proto3" json:"ids"`
	// contains filtered or unexported fields
}

func (*UUIDsReq) Descriptor deprecated

func (*UUIDsReq) Descriptor() ([]byte, []int)

Deprecated: Use UUIDsReq.ProtoReflect.Descriptor instead.

func (*UUIDsReq) GetIds

func (x *UUIDsReq) GetIds() []string

func (*UUIDsReq) ProtoMessage

func (*UUIDsReq) ProtoMessage()

func (*UUIDsReq) ProtoReflect

func (x *UUIDsReq) ProtoReflect() protoreflect.Message

func (*UUIDsReq) Reset

func (x *UUIDsReq) Reset()

func (*UUIDsReq) String

func (x *UUIDsReq) String() string

type UnimplementedJobServer

type UnimplementedJobServer struct {
}

UnimplementedJobServer must be embedded to have forward compatible implementations.

func (UnimplementedJobServer) CreateTask

func (UnimplementedJobServer) CreateTaskLog

func (UnimplementedJobServer) DeleteTask

func (UnimplementedJobServer) DeleteTaskLog

func (UnimplementedJobServer) GetTaskById

func (UnimplementedJobServer) GetTaskList

func (UnimplementedJobServer) GetTaskLogById

func (UnimplementedJobServer) GetTaskLogList

func (UnimplementedJobServer) InitDatabase

func (UnimplementedJobServer) UpdateTask

func (UnimplementedJobServer) UpdateTaskLog

type UnsafeJobServer

type UnsafeJobServer interface {
	// contains filtered or unexported methods
}

UnsafeJobServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to JobServer will result in compilation errors.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL