Documentation ¶
Index ¶
- Variables
- type JobHistory
- func (*JobHistory) Descriptor() ([]byte, []int)deprecated
- func (x *JobHistory) GetCompletedAt() *timestamppb.Timestamp
- func (x *JobHistory) GetId() string
- func (x *JobHistory) GetJobId() string
- func (x *JobHistory) GetLog() string
- func (x *JobHistory) GetScheduledRunDateTime() *timestamppb.Timestamp
- func (x *JobHistory) GetStatusCode() uint32
- func (x *JobHistory) GetSuccess() bool
- func (*JobHistory) ProtoMessage()
- func (x *JobHistory) ProtoReflect() protoreflect.Message
- func (x *JobHistory) Reset()
- func (x *JobHistory) String() string
- type JobStatus
- type Schedule
- func (*Schedule) Descriptor() ([]byte, []int)deprecated
- func (m *Schedule) GetExpiry() isSchedule_Expiry
- func (x *Schedule) GetExpiryDate() *timestamppb.Timestamp
- func (x *Schedule) GetRepeatCount() int32
- func (x *Schedule) GetSchedule() string
- func (x *Schedule) GetStartsAt() *timestamppb.Timestamp
- func (x *Schedule) GetTimezone() string
- func (*Schedule) ProtoMessage()
- func (x *Schedule) ProtoReflect() protoreflect.Message
- func (x *Schedule) Reset()
- func (x *Schedule) String() string
- type Schedule_ExpiryDate
- type Schedule_RepeatCount
- type SchedulingJob
- func (*SchedulingJob) Descriptor() ([]byte, []int)deprecated
- func (x *SchedulingJob) GetCreated() *timestamppb.Timestamp
- func (x *SchedulingJob) GetDescription() string
- func (x *SchedulingJob) GetExpiry() *timestamppb.Timestamp
- func (x *SchedulingJob) GetId() string
- func (x *SchedulingJob) GetJobFunction() string
- func (x *SchedulingJob) GetJobPayload() string
- func (x *SchedulingJob) GetLastRunDatetime() *timestamppb.Timestamp
- func (x *SchedulingJob) GetLogs() []*JobHistory
- func (x *SchedulingJob) GetName() string
- func (x *SchedulingJob) GetNextRunDatetime() *timestamppb.Timestamp
- func (x *SchedulingJob) GetSchedule() *Schedule
- func (x *SchedulingJob) GetStatus() JobStatus
- func (x *SchedulingJob) GetUpdated() *timestamppb.Timestamp
- func (*SchedulingJob) ProtoMessage()
- func (x *SchedulingJob) ProtoReflect() protoreflect.Message
- func (x *SchedulingJob) Reset()
- func (x *SchedulingJob) String() string
- type SchedulingJobResponse
- func (*SchedulingJobResponse) Descriptor() ([]byte, []int)deprecated
- func (x *SchedulingJobResponse) GetExpiry() *timestamppb.Timestamp
- func (x *SchedulingJobResponse) GetId() string
- func (x *SchedulingJobResponse) GetNextRunDatetime() *timestamppb.Timestamp
- func (x *SchedulingJobResponse) GetStatus() JobStatus
- func (*SchedulingJobResponse) ProtoMessage()
- func (x *SchedulingJobResponse) ProtoReflect() protoreflect.Message
- func (x *SchedulingJobResponse) Reset()
- func (x *SchedulingJobResponse) String() string
Constants ¶
This section is empty.
Variables ¶
View Source
var ( JobStatus_name = map[int32]string{ 0: "JOB_STATUS_NONE", 1: "JOB_STATUS_CREATED", 2: "JOB_STATUS_READY", 3: "JOB_STATUS_INFLIGHT", 4: "JOB_STATUS_SUCCEEDED", 5: "JOB_STATUS_FAILED", 6: "JOB_STATUS_PAUSED", 7: "JOB_STATUS_EXPIRED", 8: "JOB_STATUS_DELETED", } JobStatus_value = map[string]int32{ "JOB_STATUS_NONE": 0, "JOB_STATUS_CREATED": 1, "JOB_STATUS_READY": 2, "JOB_STATUS_INFLIGHT": 3, "JOB_STATUS_SUCCEEDED": 4, "JOB_STATUS_FAILED": 5, "JOB_STATUS_PAUSED": 6, "JOB_STATUS_EXPIRED": 7, "JOB_STATUS_DELETED": 8, } )
Enum value maps for JobStatus.
View Source
var File_ct_scheduler_scheduler_proto protoreflect.FileDescriptor
Functions ¶
This section is empty.
Types ¶
type JobHistory ¶
type JobHistory struct { // Job history id. // @tag: validateCreate:"-" Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty" validateCreate:"-"` // Job ID. // @tag: validateCreate:"required" JobId string `protobuf:"bytes,2,opt,name=jobId,proto3" json:"jobId,omitempty" validateCreate:"required"` // True if the job has succeeded. False if the job has failed. // @tag: validateCreate:"omitempty" Success bool `protobuf:"varint,3,opt,name=success,proto3" json:"success,omitempty" validateCreate:"omitempty"` // The job output log. // @tag: validateCreate:"required" Log string `protobuf:"bytes,4,opt,name=log,proto3" json:"log,omitempty" validateCreate:"required"` // The status code. // @tag: validateCreate:"omitempty" StatusCode uint32 `protobuf:"varint,5,opt,name=statusCode,proto3" json:"statusCode,omitempty" validateCreate:"omitempty"` // Scheduled run datetime for the job. // @tag: validateCreate:"omitempty" ScheduledRunDateTime *timestamppb.Timestamp `protobuf:"bytes,6,opt,name=scheduledRunDateTime,proto3" json:"scheduledRunDateTime,omitempty" validateCreate:"omitempty"` // Job completion datetime. // @tag: validateCreate:"required" CompletedAt *timestamppb.Timestamp `protobuf:"bytes,7,opt,name=completedAt,proto3" json:"completedAt,omitempty" validateCreate:"required"` // contains filtered or unexported fields }
func (*JobHistory) Descriptor
deprecated
func (*JobHistory) Descriptor() ([]byte, []int)
Deprecated: Use JobHistory.ProtoReflect.Descriptor instead.
func (*JobHistory) GetCompletedAt ¶
func (x *JobHistory) GetCompletedAt() *timestamppb.Timestamp
func (*JobHistory) GetId ¶
func (x *JobHistory) GetId() string
func (*JobHistory) GetJobId ¶
func (x *JobHistory) GetJobId() string
func (*JobHistory) GetLog ¶
func (x *JobHistory) GetLog() string
func (*JobHistory) GetScheduledRunDateTime ¶
func (x *JobHistory) GetScheduledRunDateTime() *timestamppb.Timestamp
func (*JobHistory) GetStatusCode ¶
func (x *JobHistory) GetStatusCode() uint32
func (*JobHistory) GetSuccess ¶
func (x *JobHistory) GetSuccess() bool
func (*JobHistory) ProtoMessage ¶
func (*JobHistory) ProtoMessage()
func (*JobHistory) ProtoReflect ¶
func (x *JobHistory) ProtoReflect() protoreflect.Message
func (*JobHistory) Reset ¶
func (x *JobHistory) Reset()
func (*JobHistory) String ¶
func (x *JobHistory) String() string
type JobStatus ¶
type JobStatus int32
const ( JobStatus_JOB_STATUS_NONE JobStatus = 0 // A job has been successfully created. JobStatus_JOB_STATUS_CREATED JobStatus = 1 // A job has a next run datetime and in standby mode. JobStatus_JOB_STATUS_READY JobStatus = 2 // When a job is flagged with inflight, the job has been dispatched and in process. JobStatus_JOB_STATUS_INFLIGHT JobStatus = 3 // A job has been completed and waiting to be assigned the next run datetime. JobStatus_JOB_STATUS_SUCCEEDED JobStatus = 4 // A job has been failed. The history logging is available for the details. JobStatus_JOB_STATUS_FAILED JobStatus = 5 // A job has been paused until resumed datetime or when resumed. JobStatus_JOB_STATUS_PAUSED JobStatus = 6 // A job has been expired and ready to be deleted. Expired jobs will be deleted. JobStatus_JOB_STATUS_EXPIRED JobStatus = 7 // A job has been deleted and the SchedulingJob record does not exist. JobStatus_JOB_STATUS_DELETED JobStatus = 8 )
func (JobStatus) Descriptor ¶
func (JobStatus) Descriptor() protoreflect.EnumDescriptor
func (JobStatus) EnumDescriptor
deprecated
func (JobStatus) Number ¶
func (x JobStatus) Number() protoreflect.EnumNumber
func (JobStatus) Type ¶
func (JobStatus) Type() protoreflect.EnumType
type Schedule ¶
type Schedule struct { // Crontab schedule expression. e.g. '0 * * * *', '@hourly' // For month end job, '@monthend' is available. // To run a one-off job now, '@now' is available. // Crontab generator tool https://crontab.guru // Reference https://en.wikipedia.org/wiki/Cron // @tag: validateCreate:"required" validateUpdate:"required" validateGeneric:"omitempty" Schedule string `` /* 149-byte string literal not displayed */ // Iana timezone. Default is UTC. Timezone string `protobuf:"bytes,2,opt,name=timezone,proto3" json:"timezone,omitempty"` // Datetime to start the first job or resume the paused job. StartsAt *timestamppb.Timestamp `protobuf:"bytes,3,opt,name=startsAt,proto3" json:"startsAt,omitempty"` // Types that are assignable to Expiry: // // *Schedule_RepeatCount // *Schedule_ExpiryDate Expiry isSchedule_Expiry `protobuf_oneof:"expiry"` // contains filtered or unexported fields }
func (*Schedule) Descriptor
deprecated
func (*Schedule) GetExpiryDate ¶
func (x *Schedule) GetExpiryDate() *timestamppb.Timestamp
func (*Schedule) GetRepeatCount ¶
func (*Schedule) GetSchedule ¶
func (*Schedule) GetStartsAt ¶
func (x *Schedule) GetStartsAt() *timestamppb.Timestamp
func (*Schedule) GetTimezone ¶
func (*Schedule) ProtoMessage ¶
func (*Schedule) ProtoMessage()
func (*Schedule) ProtoReflect ¶
func (x *Schedule) ProtoReflect() protoreflect.Message
type Schedule_ExpiryDate ¶
type Schedule_ExpiryDate struct { // The date which job will be expired. ExpiryDate *timestamppb.Timestamp `protobuf:"bytes,16,opt,name=expiryDate,proto3,oneof"` }
type Schedule_RepeatCount ¶
type Schedule_RepeatCount struct { // Set repeat count to repeat the job for certain times (eg. 3 will repeat the job for 3 times). // If job is one off, set -1. RepeatCount int32 `protobuf:"zigzag32,15,opt,name=repeatCount,proto3,oneof"` }
type SchedulingJob ¶
type SchedulingJob struct { // Auto generated 22 char identifier. Read only. // @tag: validateCreate:"-" validateUpdate:"required" validateGeneric:"required" Id string `` /* 129-byte string literal not displayed */ // HttpMethod and Endpoint with comma separation. // Eg. POST,https://api.pub1.passkit.io/members/count/05QFES9HNRMZb1gwcsepww // @tag: validateCreate:"required" validateUpdate:"required" validateGeneric:"omitempty" JobFunction string `` /* 155-byte string literal not displayed */ // Json string of the job function payload. // @tag: validateCreate:"omitempty" validateUpdate:"omitempty" validateGeneric:"omitempty" JobPayload string `` /* 155-byte string literal not displayed */ // Job name. // @tag: validateCreate:"required" validateUpdate:"required" validateGeneric:"omitempty" Name string `` /* 141-byte string literal not displayed */ // Job description. // @tag: validateCreate:"omitempty" validateUpdate:"omitempty" validateGeneric:"omitempty" Description string `` /* 157-byte string literal not displayed */ // Job schedule. You can set recursive or one-off job. // @tag: validateCreate:"required" validateUpdate:"required" validateGeneric:"omitempty" Schedule *Schedule `` /* 149-byte string literal not displayed */ // Job status. Writable values are JOB_STATUS_READY and JOB_STATUS_PAUSED only. Default is JOB_STATUS_READY. // Setting status=JOB_STATUS_PAUSED sets nextRunDatetime=null only when Schedule.StartsAt is not set. // Status will be always JOB_STATUS_READY, if you set Schedule.StartsAt. // @tag: validateCreate:"omitempty" validateUpdate:"omitempty" validateGeneric:"omitempty" Status JobStatus `` /* 166-byte string literal not displayed */ // Next scheduled run datetime. Read only. // @tag: validateCreate:"isdefault" validateUpdate:"isdefault" validateGeneric:"isdefault" NextRunDatetime *timestamppb.Timestamp `` /* 165-byte string literal not displayed */ // The datetime when the job was executed last time. Read only. // @tag: validateCreate:"isdefault" validateUpdate:"isdefault" validateGeneric:"isdefault" LastRunDatetime *timestamppb.Timestamp `` /* 165-byte string literal not displayed */ // 5 latest logs of executed jobs. Read only. // @tag: validateCreate:"isdefault" validateUpdate:"isdefault" validateGeneric:"isdefault" Logs []*JobHistory `` /* 144-byte string literal not displayed */ // Datetime the job was created. Read only. // @tag: validateCreate:"isdefault" validateUpdate:"isdefault" validateGeneric:"isdefault" Created *timestamppb.Timestamp `` /* 150-byte string literal not displayed */ // Datetime the job was last updated. Read only. // @tag: validateCreate:"isdefault" validateUpdate:"isdefault" validateGeneric:"isdefault" Updated *timestamppb.Timestamp `` /* 150-byte string literal not displayed */ // Datetime when the job will for the last time and expires. Read only. Expiry setting is available in the Schedule field. // @tag: validateCreate:"isdefault" validateUpdate:"isdefault" validateGeneric:"isdefault" Expiry *timestamppb.Timestamp `` /* 148-byte string literal not displayed */ // contains filtered or unexported fields }
func (*SchedulingJob) Descriptor
deprecated
func (*SchedulingJob) Descriptor() ([]byte, []int)
Deprecated: Use SchedulingJob.ProtoReflect.Descriptor instead.
func (*SchedulingJob) GetCreated ¶
func (x *SchedulingJob) GetCreated() *timestamppb.Timestamp
func (*SchedulingJob) GetDescription ¶
func (x *SchedulingJob) GetDescription() string
func (*SchedulingJob) GetExpiry ¶
func (x *SchedulingJob) GetExpiry() *timestamppb.Timestamp
func (*SchedulingJob) GetId ¶
func (x *SchedulingJob) GetId() string
func (*SchedulingJob) GetJobFunction ¶
func (x *SchedulingJob) GetJobFunction() string
func (*SchedulingJob) GetJobPayload ¶
func (x *SchedulingJob) GetJobPayload() string
func (*SchedulingJob) GetLastRunDatetime ¶
func (x *SchedulingJob) GetLastRunDatetime() *timestamppb.Timestamp
func (*SchedulingJob) GetLogs ¶
func (x *SchedulingJob) GetLogs() []*JobHistory
func (*SchedulingJob) GetName ¶
func (x *SchedulingJob) GetName() string
func (*SchedulingJob) GetNextRunDatetime ¶
func (x *SchedulingJob) GetNextRunDatetime() *timestamppb.Timestamp
func (*SchedulingJob) GetSchedule ¶
func (x *SchedulingJob) GetSchedule() *Schedule
func (*SchedulingJob) GetStatus ¶
func (x *SchedulingJob) GetStatus() JobStatus
func (*SchedulingJob) GetUpdated ¶
func (x *SchedulingJob) GetUpdated() *timestamppb.Timestamp
func (*SchedulingJob) ProtoMessage ¶
func (*SchedulingJob) ProtoMessage()
func (*SchedulingJob) ProtoReflect ¶
func (x *SchedulingJob) ProtoReflect() protoreflect.Message
func (*SchedulingJob) Reset ¶
func (x *SchedulingJob) Reset()
func (*SchedulingJob) String ¶
func (x *SchedulingJob) String() string
type SchedulingJobResponse ¶
type SchedulingJobResponse struct { // Auto generated 22 char identifier. Read only. Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"` // Job status. Writable values are JOB_STATUS_READY and JOB_STATUS_PAUSED only. Status JobStatus `protobuf:"varint,2,opt,name=status,proto3,enum=ct.JobStatus" json:"status,omitempty"` // Next scheduled run datetime. Read only. NextRunDatetime *timestamppb.Timestamp `protobuf:"bytes,3,opt,name=nextRunDatetime,proto3" json:"nextRunDatetime,omitempty"` // Datetime when the job will for the last time and expires. Read only. Expiry setting is available in the Schedule field. Expiry *timestamppb.Timestamp `protobuf:"bytes,4,opt,name=expiry,proto3" json:"expiry,omitempty"` // contains filtered or unexported fields }
func (*SchedulingJobResponse) Descriptor
deprecated
func (*SchedulingJobResponse) Descriptor() ([]byte, []int)
Deprecated: Use SchedulingJobResponse.ProtoReflect.Descriptor instead.
func (*SchedulingJobResponse) GetExpiry ¶
func (x *SchedulingJobResponse) GetExpiry() *timestamppb.Timestamp
func (*SchedulingJobResponse) GetId ¶
func (x *SchedulingJobResponse) GetId() string
func (*SchedulingJobResponse) GetNextRunDatetime ¶
func (x *SchedulingJobResponse) GetNextRunDatetime() *timestamppb.Timestamp
func (*SchedulingJobResponse) GetStatus ¶
func (x *SchedulingJobResponse) GetStatus() JobStatus
func (*SchedulingJobResponse) ProtoMessage ¶
func (*SchedulingJobResponse) ProtoMessage()
func (*SchedulingJobResponse) ProtoReflect ¶
func (x *SchedulingJobResponse) ProtoReflect() protoreflect.Message
func (*SchedulingJobResponse) Reset ¶
func (x *SchedulingJobResponse) Reset()
func (*SchedulingJobResponse) String ¶
func (x *SchedulingJobResponse) String() string
Click to show internal directories.
Click to hide internal directories.