Documentation ¶
Index ¶
- Variables
- func RegisterClusterServer(s *grpc.Server, srv ClusterServer)
- func RegisterJobStateMachineServer(s *grpc.Server, srv JobStateMachineServer)
- type ApplyOpRequest
- func (*ApplyOpRequest) Descriptor() ([]byte, []int)deprecated
- func (x *ApplyOpRequest) GetBody() []byte
- func (x *ApplyOpRequest) GetNowSecs() int64
- func (x *ApplyOpRequest) GetOp() OpType
- func (*ApplyOpRequest) ProtoMessage()
- func (x *ApplyOpRequest) ProtoReflect() protoreflect.Message
- func (x *ApplyOpRequest) Reset()
- func (x *ApplyOpRequest) String() string
- type ApplyOpResponse
- func (*ApplyOpResponse) Descriptor() ([]byte, []int)deprecated
- func (x *ApplyOpResponse) GetBody() []byte
- func (x *ApplyOpResponse) GetErrorCode() ResultCode
- func (x *ApplyOpResponse) GetErrorMessage() string
- func (*ApplyOpResponse) ProtoMessage()
- func (x *ApplyOpResponse) ProtoReflect() protoreflect.Message
- func (x *ApplyOpResponse) Reset()
- func (x *ApplyOpResponse) String() string
- type BuryRequest
- func (*BuryRequest) Descriptor() ([]byte, []int)deprecated
- func (x *BuryRequest) GetClientId() string
- func (x *BuryRequest) GetJobId() int64
- func (x *BuryRequest) GetPriority() uint32
- func (x *BuryRequest) GetProxyId() string
- func (*BuryRequest) ProtoMessage()
- func (x *BuryRequest) ProtoReflect() protoreflect.Message
- func (x *BuryRequest) Reset()
- func (x *BuryRequest) String() string
- type CheckClientStateRequest
- func (*CheckClientStateRequest) Descriptor() ([]byte, []int)deprecated
- func (x *CheckClientStateRequest) GetClientIds() []string
- func (x *CheckClientStateRequest) GetProxyId() string
- func (*CheckClientStateRequest) ProtoMessage()
- func (x *CheckClientStateRequest) ProtoReflect() protoreflect.Message
- func (x *CheckClientStateRequest) Reset()
- func (x *CheckClientStateRequest) String() string
- type CheckClientStateResponse
- func (*CheckClientStateResponse) Descriptor() ([]byte, []int)deprecated
- func (x *CheckClientStateResponse) GetMissingClientIds() []string
- func (x *CheckClientStateResponse) GetNotWaitingClientIds() []string
- func (x *CheckClientStateResponse) GetProxyId() string
- func (x *CheckClientStateResponse) GetWaitingClientIds() []string
- func (*CheckClientStateResponse) ProtoMessage()
- func (x *CheckClientStateResponse) ProtoReflect() protoreflect.Message
- func (x *CheckClientStateResponse) Reset()
- func (x *CheckClientStateResponse) String() string
- type ClientResvEntryProto
- func (*ClientResvEntryProto) Descriptor() ([]byte, []int)deprecated
- func (x *ClientResvEntryProto) GetClientId() string
- func (x *ClientResvEntryProto) GetHeapIndex() int32
- func (x *ClientResvEntryProto) GetIsWaitingForResv() bool
- func (x *ClientResvEntryProto) GetReqId() string
- func (x *ClientResvEntryProto) GetResvDeadlineAt() int64
- func (x *ClientResvEntryProto) GetTickAt() int64
- func (x *ClientResvEntryProto) GetWatchedTube() []string
- func (*ClientResvEntryProto) ProtoMessage()
- func (x *ClientResvEntryProto) ProtoReflect() protoreflect.Message
- func (x *ClientResvEntryProto) Reset()
- func (x *ClientResvEntryProto) String() string
- type ClusterClient
- type ClusterServer
- type DeleteRequest
- func (*DeleteRequest) Descriptor() ([]byte, []int)deprecated
- func (x *DeleteRequest) GetClientId() string
- func (x *DeleteRequest) GetJobId() int64
- func (x *DeleteRequest) GetProxyId() string
- func (*DeleteRequest) ProtoMessage()
- func (x *DeleteRequest) ProtoReflect() protoreflect.Message
- func (x *DeleteRequest) Reset()
- func (x *DeleteRequest) String() string
- type Empty
- type GetJobRequest
- type GetJobResponse
- type GetStatsJobYamlRequest
- func (*GetStatsJobYamlRequest) Descriptor() ([]byte, []int)deprecated
- func (x *GetStatsJobYamlRequest) GetJobId() int64
- func (*GetStatsJobYamlRequest) ProtoMessage()
- func (x *GetStatsJobYamlRequest) ProtoReflect() protoreflect.Message
- func (x *GetStatsJobYamlRequest) Reset()
- func (x *GetStatsJobYamlRequest) String() string
- type GetStatsJobYamlResponse
- func (*GetStatsJobYamlResponse) Descriptor() ([]byte, []int)deprecated
- func (x *GetStatsJobYamlResponse) GetStatsYaml() []byte
- func (*GetStatsJobYamlResponse) ProtoMessage()
- func (x *GetStatsJobYamlResponse) ProtoReflect() protoreflect.Message
- func (x *GetStatsJobYamlResponse) Reset()
- func (x *GetStatsJobYamlResponse) String() string
- type GetStatsTubeYamlRequest
- func (*GetStatsTubeYamlRequest) Descriptor() ([]byte, []int)deprecated
- func (x *GetStatsTubeYamlRequest) GetTubeName() string
- func (*GetStatsTubeYamlRequest) ProtoMessage()
- func (x *GetStatsTubeYamlRequest) ProtoReflect() protoreflect.Message
- func (x *GetStatsTubeYamlRequest) Reset()
- func (x *GetStatsTubeYamlRequest) String() string
- type GetStatsTubeYamlResponse
- func (*GetStatsTubeYamlResponse) Descriptor() ([]byte, []int)deprecated
- func (x *GetStatsTubeYamlResponse) GetStatsYaml() []byte
- func (*GetStatsTubeYamlResponse) ProtoMessage()
- func (x *GetStatsTubeYamlResponse) ProtoReflect() protoreflect.Message
- func (x *GetStatsTubeYamlResponse) Reset()
- func (x *GetStatsTubeYamlResponse) String() string
- type GetStatsYamlResponse
- func (*GetStatsYamlResponse) Descriptor() ([]byte, []int)deprecated
- func (x *GetStatsYamlResponse) GetStatsYaml() []byte
- func (*GetStatsYamlResponse) ProtoMessage()
- func (x *GetStatsYamlResponse) ProtoReflect() protoreflect.Message
- func (x *GetStatsYamlResponse) Reset()
- func (x *GetStatsYamlResponse) String() string
- type IsNodeLeaderResponse
- func (*IsNodeLeaderResponse) Descriptor() ([]byte, []int)deprecated
- func (x *IsNodeLeaderResponse) GetIsLeader() bool
- func (*IsNodeLeaderResponse) ProtoMessage()
- func (x *IsNodeLeaderResponse) ProtoReflect() protoreflect.Message
- func (x *IsNodeLeaderResponse) Reset()
- func (x *IsNodeLeaderResponse) String() string
- type JobProto
- func (*JobProto) Descriptor() ([]byte, []int)deprecated
- func (x *JobProto) GetBody() []byte
- func (x *JobProto) GetBodySize() int32
- func (x *JobProto) GetBuriedAt() int64
- func (x *JobProto) GetBuryCount() uint32
- func (x *JobProto) GetCreatedAt() int64
- func (x *JobProto) GetDelay() int64
- func (x *JobProto) GetExpiresAt() int64
- func (x *JobProto) GetId() int64
- func (x *JobProto) GetKickCount() uint32
- func (x *JobProto) GetPriority() uint32
- func (x *JobProto) GetReadyAt() int64
- func (x *JobProto) GetReleaseCount() uint32
- func (x *JobProto) GetReserveCount() uint32
- func (x *JobProto) GetReservedBy() string
- func (x *JobProto) GetState() JobStateProto
- func (x *JobProto) GetTimeoutCount() uint32
- func (x *JobProto) GetTtr() int32
- func (x *JobProto) GetTubeName() string
- func (*JobProto) ProtoMessage()
- func (x *JobProto) ProtoReflect() protoreflect.Message
- func (x *JobProto) Reset()
- func (x *JobProto) String() string
- type JobStateMachineClient
- type JobStateMachineServer
- type JobStateMachine_StreamReserveUpdatesClient
- type JobStateMachine_StreamReserveUpdatesServer
- type JobStateProto
- func (JobStateProto) Descriptor() protoreflect.EnumDescriptor
- func (x JobStateProto) Enum() *JobStateProto
- func (JobStateProto) EnumDescriptor() ([]byte, []int)deprecated
- func (x JobStateProto) Number() protoreflect.EnumNumber
- func (x JobStateProto) String() string
- func (JobStateProto) Type() protoreflect.EnumType
- type JoinRequest
- type KickNRequest
- func (*KickNRequest) Descriptor() ([]byte, []int)deprecated
- func (x *KickNRequest) GetBound() int32
- func (x *KickNRequest) GetTubeName() string
- func (*KickNRequest) ProtoMessage()
- func (x *KickNRequest) ProtoReflect() protoreflect.Message
- func (x *KickNRequest) Reset()
- func (x *KickNRequest) String() string
- type KickNResponse
- type KickRequest
- type LeaveRequest
- type ListTubesResponse
- type OpType
- type PeekRequest
- type PeekResponse
- type PutRequest
- func (*PutRequest) Descriptor() ([]byte, []int)deprecated
- func (x *PutRequest) GetBody() []byte
- func (x *PutRequest) GetBodySize() int32
- func (x *PutRequest) GetDelay() int64
- func (x *PutRequest) GetPriority() uint32
- func (x *PutRequest) GetTtr() int32
- func (x *PutRequest) GetTubeName() string
- func (*PutRequest) ProtoMessage()
- func (x *PutRequest) ProtoReflect() protoreflect.Message
- func (x *PutRequest) Reset()
- func (x *PutRequest) String() string
- type PutResponse
- type ReleaseRequest
- func (*ReleaseRequest) Descriptor() ([]byte, []int)deprecated
- func (x *ReleaseRequest) GetClientId() string
- func (x *ReleaseRequest) GetDelay() int64
- func (x *ReleaseRequest) GetJobId() int64
- func (x *ReleaseRequest) GetPriority() uint32
- func (x *ReleaseRequest) GetProxyId() string
- func (*ReleaseRequest) ProtoMessage()
- func (x *ReleaseRequest) ProtoReflect() protoreflect.Message
- func (x *ReleaseRequest) Reset()
- func (x *ReleaseRequest) String() string
- type Reservation
- func (*Reservation) Descriptor() ([]byte, []int)deprecated
- func (x *Reservation) GetBody() []byte
- func (x *Reservation) GetBodySize() int32
- func (x *Reservation) GetClientId() string
- func (x *Reservation) GetErrorMsg() string
- func (x *Reservation) GetJobId() int64
- func (x *Reservation) GetProxyId() string
- func (x *Reservation) GetRequestId() string
- func (x *Reservation) GetStatus() ReservationStatus
- func (*Reservation) ProtoMessage()
- func (x *Reservation) ProtoReflect() protoreflect.Message
- func (x *Reservation) Reset()
- func (x *Reservation) String() string
- type ReservationStatus
- func (ReservationStatus) Descriptor() protoreflect.EnumDescriptor
- func (x ReservationStatus) Enum() *ReservationStatus
- func (ReservationStatus) EnumDescriptor() ([]byte, []int)deprecated
- func (x ReservationStatus) Number() protoreflect.EnumNumber
- func (x ReservationStatus) String() string
- func (ReservationStatus) Type() protoreflect.EnumType
- type Reservations
- type ReserveRequest
- func (*ReserveRequest) Descriptor() ([]byte, []int)deprecated
- func (x *ReserveRequest) GetClientId() string
- func (x *ReserveRequest) GetProxyId() string
- func (x *ReserveRequest) GetRequestId() string
- func (x *ReserveRequest) GetTimeoutSecs() int32
- func (x *ReserveRequest) GetWatchedTubes() []string
- func (*ReserveRequest) ProtoMessage()
- func (x *ReserveRequest) ProtoReflect() protoreflect.Message
- func (x *ReserveRequest) Reset()
- func (x *ReserveRequest) String() string
- type ReserveResponse
- type ReserveUpdateRequest
- func (*ReserveUpdateRequest) Descriptor() ([]byte, []int)deprecated
- func (x *ReserveUpdateRequest) GetProxyId() string
- func (*ReserveUpdateRequest) ProtoMessage()
- func (x *ReserveUpdateRequest) ProtoReflect() protoreflect.Message
- func (x *ReserveUpdateRequest) Reset()
- func (x *ReserveUpdateRequest) String() string
- type ReserveUpdateResponse
- func (*ReserveUpdateResponse) Descriptor() ([]byte, []int)deprecated
- func (x *ReserveUpdateResponse) GetReservation() *Reservation
- func (*ReserveUpdateResponse) ProtoMessage()
- func (x *ReserveUpdateResponse) ProtoReflect() protoreflect.Message
- func (x *ReserveUpdateResponse) Reset()
- func (x *ReserveUpdateResponse) String() string
- type ResultCode
- type SnapshotProto
- func (*SnapshotProto) Descriptor() ([]byte, []int)deprecated
- func (x *SnapshotProto) GetJobs() []*JobProto
- func (x *SnapshotProto) GetReservations() []*ClientResvEntryProto
- func (*SnapshotProto) ProtoMessage()
- func (x *SnapshotProto) ProtoReflect() protoreflect.Message
- func (x *SnapshotProto) Reset()
- func (x *SnapshotProto) String() string
- type TickResponse
- type TouchRequest
- func (*TouchRequest) Descriptor() ([]byte, []int)deprecated
- func (x *TouchRequest) GetClientId() string
- func (x *TouchRequest) GetJobId() int64
- func (x *TouchRequest) GetProxyId() string
- func (*TouchRequest) ProtoMessage()
- func (x *TouchRequest) ProtoReflect() protoreflect.Message
- func (x *TouchRequest) Reset()
- func (x *TouchRequest) String() string
- type UnimplementedClusterServer
- func (*UnimplementedClusterServer) IsNodeLeader(context.Context, *Empty) (*IsNodeLeaderResponse, error)
- func (*UnimplementedClusterServer) Join(context.Context, *JoinRequest) (*Empty, error)
- func (*UnimplementedClusterServer) Leave(context.Context, *LeaveRequest) (*Empty, error)
- func (*UnimplementedClusterServer) Snapshot(context.Context, *Empty) (*Empty, error)
- type UnimplementedJobStateMachineServer
- func (*UnimplementedJobStateMachineServer) Bury(context.Context, *BuryRequest) (*Empty, error)
- func (*UnimplementedJobStateMachineServer) CheckClientState(context.Context, *CheckClientStateRequest) (*CheckClientStateResponse, error)
- func (*UnimplementedJobStateMachineServer) Delete(context.Context, *DeleteRequest) (*Empty, error)
- func (*UnimplementedJobStateMachineServer) GetJob(context.Context, *GetJobRequest) (*GetJobResponse, error)
- func (*UnimplementedJobStateMachineServer) GetStatsJobYaml(context.Context, *GetStatsJobYamlRequest) (*GetStatsJobYamlResponse, error)
- func (*UnimplementedJobStateMachineServer) GetStatsTubeYaml(context.Context, *GetStatsTubeYamlRequest) (*GetStatsTubeYamlResponse, error)
- func (*UnimplementedJobStateMachineServer) GetStatsYaml(context.Context, *Empty) (*GetStatsYamlResponse, error)
- func (*UnimplementedJobStateMachineServer) Kick(context.Context, *KickRequest) (*Empty, error)
- func (*UnimplementedJobStateMachineServer) KickN(context.Context, *KickNRequest) (*KickNResponse, error)
- func (*UnimplementedJobStateMachineServer) ListTubes(context.Context, *Empty) (*ListTubesResponse, error)
- func (*UnimplementedJobStateMachineServer) PeekBuried(context.Context, *PeekRequest) (*PeekResponse, error)
- func (*UnimplementedJobStateMachineServer) PeekDelayed(context.Context, *PeekRequest) (*PeekResponse, error)
- func (*UnimplementedJobStateMachineServer) PeekReady(context.Context, *PeekRequest) (*PeekResponse, error)
- func (*UnimplementedJobStateMachineServer) Put(context.Context, *PutRequest) (*PutResponse, error)
- func (*UnimplementedJobStateMachineServer) Release(context.Context, *ReleaseRequest) (*Empty, error)
- func (*UnimplementedJobStateMachineServer) Reserve(context.Context, *ReserveRequest) (*ReserveResponse, error)
- func (*UnimplementedJobStateMachineServer) StreamReserveUpdates(*ReserveUpdateRequest, JobStateMachine_StreamReserveUpdatesServer) error
- func (*UnimplementedJobStateMachineServer) Touch(context.Context, *TouchRequest) (*Empty, error)
Constants ¶
This section is empty.
Variables ¶
var ( JobStateProto_name = map[int32]string{ 0: "INITIAL", 1: "READY", 2: "RESERVED", 3: "BURIED", 4: "DELAYED", 5: "DELETED", } JobStateProto_value = map[string]int32{ "INITIAL": 0, "READY": 1, "RESERVED": 2, "BURIED": 3, "DELAYED": 4, "DELETED": 5, } )
Enum value maps for JobStateProto.
var ( ReservationStatus_name = map[int32]string{ 0: "UnknownRS", 1: "Queued", 2: "DeadlineSoon", 3: "Matched", 4: "Timeout", 5: "Error", } ReservationStatus_value = map[string]int32{ "UnknownRS": 0, "Queued": 1, "DeadlineSoon": 2, "Matched": 3, "Timeout": 4, "Error": 5, } )
Enum value maps for ReservationStatus.
var ( OpType_name = map[int32]string{ 0: "UNKNOWN", 1: "PUT", 2: "RESERVE", 3: "TICK", 4: "DELETE", 5: "RELEASE", 6: "CHECK_CLIENT_STATE", 7: "BURY", 8: "KICK", 9: "KICKN", 10: "TOUCH", 11: "GET_JOB", 12: "PEEK_READY", 13: "PEEK_BURIED", 14: "PEEK_DELAYED", 15: "STATS_JOB_YAML", 16: "STATS_TUBE_YAML", 17: "STATS_YAML", 18: "LIST_TUBES", } OpType_value = map[string]int32{ "UNKNOWN": 0, "PUT": 1, "RESERVE": 2, "TICK": 3, "DELETE": 4, "RELEASE": 5, "CHECK_CLIENT_STATE": 6, "BURY": 7, "KICK": 8, "KICKN": 9, "TOUCH": 10, "GET_JOB": 11, "PEEK_READY": 12, "PEEK_BURIED": 13, "PEEK_DELAYED": 14, "STATS_JOB_YAML": 15, "STATS_TUBE_YAML": 16, "STATS_YAML": 17, "LIST_TUBES": 18, } )
Enum value maps for OpType.
var ( ResultCode_name = map[int32]string{ 0: "OK", 1: "Canceled", 2: "Unknown", 3: "InvalidArgument", 4: "DeadlineExceeded", 5: "NotFound", 6: "AlreadyExists", 7: "PermissionDenied", 8: "ResourceExhausted", 9: "FailedPrecondition", 10: "Aborted", 11: "OutOfRange", 12: "Unimplemented", 13: "Internal", 14: "Unavailable", 15: "DataLoss", 16: "Unauthenticated", } ResultCode_value = map[string]int32{ "OK": 0, "Canceled": 1, "Unknown": 2, "InvalidArgument": 3, "DeadlineExceeded": 4, "NotFound": 5, "AlreadyExists": 6, "PermissionDenied": 7, "ResourceExhausted": 8, "FailedPrecondition": 9, "Aborted": 10, "OutOfRange": 11, "Unimplemented": 12, "Internal": 13, "Unavailable": 14, "DataLoss": 15, "Unauthenticated": 16, } )
Enum value maps for ResultCode.
var File_client_proto protoreflect.FileDescriptor
var File_cluster_proto protoreflect.FileDescriptor
var File_empty_proto protoreflect.FileDescriptor
var File_job_proto protoreflect.FileDescriptor
var File_jsm_proto protoreflect.FileDescriptor
Functions ¶
func RegisterClusterServer ¶
func RegisterClusterServer(s *grpc.Server, srv ClusterServer)
func RegisterJobStateMachineServer ¶
func RegisterJobStateMachineServer(s *grpc.Server, srv JobStateMachineServer)
Types ¶
type ApplyOpRequest ¶
type ApplyOpRequest struct { // Indicates the type of operation Op OpType `protobuf:"varint,1,opt,name=op,proto3,enum=coolbeans.api.v1.OpType" json:"op,omitempty"` // time in seconds from epoch this request is made NowSecs int64 `protobuf:"varint,2,opt,name=now_secs,json=nowSecs,proto3" json:"now_secs,omitempty"` // The operation request body Body []byte `protobuf:"bytes,3,opt,name=body,proto3" json:"body,omitempty"` // contains filtered or unexported fields }
func (*ApplyOpRequest) Descriptor
deprecated
func (*ApplyOpRequest) Descriptor() ([]byte, []int)
Deprecated: Use ApplyOpRequest.ProtoReflect.Descriptor instead.
func (*ApplyOpRequest) GetBody ¶
func (x *ApplyOpRequest) GetBody() []byte
func (*ApplyOpRequest) GetNowSecs ¶
func (x *ApplyOpRequest) GetNowSecs() int64
func (*ApplyOpRequest) GetOp ¶
func (x *ApplyOpRequest) GetOp() OpType
func (*ApplyOpRequest) ProtoMessage ¶
func (*ApplyOpRequest) ProtoMessage()
func (*ApplyOpRequest) ProtoReflect ¶
func (x *ApplyOpRequest) ProtoReflect() protoreflect.Message
func (*ApplyOpRequest) Reset ¶
func (x *ApplyOpRequest) Reset()
func (*ApplyOpRequest) String ¶
func (x *ApplyOpRequest) String() string
type ApplyOpResponse ¶
type ApplyOpResponse struct { // error code ErrorCode ResultCode `protobuf:"varint,1,opt,name=error_code,json=errorCode,proto3,enum=coolbeans.api.v1.ResultCode" json:"error_code,omitempty"` // error message (typically set if error_code > 0 ErrorMessage string `protobuf:"bytes,2,opt,name=error_message,json=errorMessage,proto3" json:"error_message,omitempty"` // The response body Body []byte `protobuf:"bytes,3,opt,name=body,proto3" json:"body,omitempty"` // contains filtered or unexported fields }
func (*ApplyOpResponse) Descriptor
deprecated
func (*ApplyOpResponse) Descriptor() ([]byte, []int)
Deprecated: Use ApplyOpResponse.ProtoReflect.Descriptor instead.
func (*ApplyOpResponse) GetBody ¶
func (x *ApplyOpResponse) GetBody() []byte
func (*ApplyOpResponse) GetErrorCode ¶
func (x *ApplyOpResponse) GetErrorCode() ResultCode
func (*ApplyOpResponse) GetErrorMessage ¶
func (x *ApplyOpResponse) GetErrorMessage() string
func (*ApplyOpResponse) ProtoMessage ¶
func (*ApplyOpResponse) ProtoMessage()
func (*ApplyOpResponse) ProtoReflect ¶
func (x *ApplyOpResponse) ProtoReflect() protoreflect.Message
func (*ApplyOpResponse) Reset ¶
func (x *ApplyOpResponse) Reset()
func (*ApplyOpResponse) String ¶
func (x *ApplyOpResponse) String() string
type BuryRequest ¶
type BuryRequest struct { // The job identifier of the job to be buried JobId int64 `protobuf:"varint,1,opt,name=job_id,json=jobId,proto3" json:"job_id,omitempty"` // Refer Job.priority, the new priority for the job Priority uint32 `protobuf:"varint,2,opt,name=priority,proto3" json:"priority,omitempty"` // Client id of the request ClientId string `protobuf:"bytes,3,opt,name=client_id,json=clientId,proto3" json:"client_id,omitempty"` // proxy_id is the id of the proxy server that forwarded this request ProxyId string `protobuf:"bytes,4,opt,name=proxy_id,json=proxyId,proto3" json:"proxy_id,omitempty"` // contains filtered or unexported fields }
func (*BuryRequest) Descriptor
deprecated
func (*BuryRequest) Descriptor() ([]byte, []int)
Deprecated: Use BuryRequest.ProtoReflect.Descriptor instead.
func (*BuryRequest) GetClientId ¶
func (x *BuryRequest) GetClientId() string
func (*BuryRequest) GetJobId ¶
func (x *BuryRequest) GetJobId() int64
func (*BuryRequest) GetPriority ¶
func (x *BuryRequest) GetPriority() uint32
func (*BuryRequest) GetProxyId ¶
func (x *BuryRequest) GetProxyId() string
func (*BuryRequest) ProtoMessage ¶
func (*BuryRequest) ProtoMessage()
func (*BuryRequest) ProtoReflect ¶
func (x *BuryRequest) ProtoReflect() protoreflect.Message
func (*BuryRequest) Reset ¶
func (x *BuryRequest) Reset()
func (*BuryRequest) String ¶
func (x *BuryRequest) String() string
type CheckClientStateRequest ¶
type CheckClientStateRequest struct { // proxy_id is the id of the proxy server that // forwarded this request ProxyId string `protobuf:"bytes,1,opt,name=proxy_id,json=proxyId,proto3" json:"proxy_id,omitempty"` // Array of all client_ids ClientIds []string `protobuf:"bytes,2,rep,name=client_ids,json=clientIds,proto3" json:"client_ids,omitempty"` // contains filtered or unexported fields }
func (*CheckClientStateRequest) Descriptor
deprecated
func (*CheckClientStateRequest) Descriptor() ([]byte, []int)
Deprecated: Use CheckClientStateRequest.ProtoReflect.Descriptor instead.
func (*CheckClientStateRequest) GetClientIds ¶
func (x *CheckClientStateRequest) GetClientIds() []string
func (*CheckClientStateRequest) GetProxyId ¶
func (x *CheckClientStateRequest) GetProxyId() string
func (*CheckClientStateRequest) ProtoMessage ¶
func (*CheckClientStateRequest) ProtoMessage()
func (*CheckClientStateRequest) ProtoReflect ¶
func (x *CheckClientStateRequest) ProtoReflect() protoreflect.Message
func (*CheckClientStateRequest) Reset ¶
func (x *CheckClientStateRequest) Reset()
func (*CheckClientStateRequest) String ¶
func (x *CheckClientStateRequest) String() string
type CheckClientStateResponse ¶
type CheckClientStateResponse struct { // proxy_id is the id of the proxy server that // forwarded this request ProxyId string `protobuf:"bytes,1,opt,name=proxy_id,json=proxyId,proto3" json:"proxy_id,omitempty"` // Array of all client_ids waiting for reservations WaitingClientIds []string `protobuf:"bytes,2,rep,name=waiting_client_ids,json=waitingClientIds,proto3" json:"waiting_client_ids,omitempty"` // Array of all client_ids not waiting for reservations NotWaitingClientIds []string `protobuf:"bytes,3,rep,name=not_waiting_client_ids,json=notWaitingClientIds,proto3" json:"not_waiting_client_ids,omitempty"` // Array of all client_ids unknown or missing on the server MissingClientIds []string `protobuf:"bytes,4,rep,name=missing_client_ids,json=missingClientIds,proto3" json:"missing_client_ids,omitempty"` // contains filtered or unexported fields }
func (*CheckClientStateResponse) Descriptor
deprecated
func (*CheckClientStateResponse) Descriptor() ([]byte, []int)
Deprecated: Use CheckClientStateResponse.ProtoReflect.Descriptor instead.
func (*CheckClientStateResponse) GetMissingClientIds ¶
func (x *CheckClientStateResponse) GetMissingClientIds() []string
func (*CheckClientStateResponse) GetNotWaitingClientIds ¶
func (x *CheckClientStateResponse) GetNotWaitingClientIds() []string
func (*CheckClientStateResponse) GetProxyId ¶
func (x *CheckClientStateResponse) GetProxyId() string
func (*CheckClientStateResponse) GetWaitingClientIds ¶
func (x *CheckClientStateResponse) GetWaitingClientIds() []string
func (*CheckClientStateResponse) ProtoMessage ¶
func (*CheckClientStateResponse) ProtoMessage()
func (*CheckClientStateResponse) ProtoReflect ¶
func (x *CheckClientStateResponse) ProtoReflect() protoreflect.Message
func (*CheckClientStateResponse) Reset ¶
func (x *CheckClientStateResponse) Reset()
func (*CheckClientStateResponse) String ¶
func (x *CheckClientStateResponse) String() string
type ClientResvEntryProto ¶
type ClientResvEntryProto struct { // identifier of the client that requested a reservation ClientId string `protobuf:"bytes,1,opt,name=client_id,json=clientId,proto3" json:"client_id,omitempty"` // reservation deadline at (clock time) ResvDeadlineAt int64 `protobuf:"varint,2,opt,name=resv_deadline_at,json=resvDeadlineAt,proto3" json:"resv_deadline_at,omitempty"` // boolean indicating if the client is waiting for a reservation IsWaitingForResv bool `protobuf:"varint,3,opt,name=is_waiting_for_resv,json=isWaitingForResv,proto3" json:"is_waiting_for_resv,omitempty"` // clock time at which the client needs some processing TickAt int64 `protobuf:"varint,4,opt,name=tick_at,json=tickAt,proto3" json:"tick_at,omitempty"` // request id of the current reservation request ReqId string `protobuf:"bytes,5,opt,name=req_id,json=reqId,proto3" json:"req_id,omitempty"` // heap index value for this client reservation HeapIndex int32 `protobuf:"varint,6,opt,name=heap_index,json=heapIndex,proto3" json:"heap_index,omitempty"` // names of the tubes current watched for resrervations WatchedTube []string `protobuf:"bytes,7,rep,name=watched_tube,json=watchedTube,proto3" json:"watched_tube,omitempty"` // contains filtered or unexported fields }
func (*ClientResvEntryProto) Descriptor
deprecated
func (*ClientResvEntryProto) Descriptor() ([]byte, []int)
Deprecated: Use ClientResvEntryProto.ProtoReflect.Descriptor instead.
func (*ClientResvEntryProto) GetClientId ¶
func (x *ClientResvEntryProto) GetClientId() string
func (*ClientResvEntryProto) GetHeapIndex ¶
func (x *ClientResvEntryProto) GetHeapIndex() int32
func (*ClientResvEntryProto) GetIsWaitingForResv ¶
func (x *ClientResvEntryProto) GetIsWaitingForResv() bool
func (*ClientResvEntryProto) GetReqId ¶
func (x *ClientResvEntryProto) GetReqId() string
func (*ClientResvEntryProto) GetResvDeadlineAt ¶
func (x *ClientResvEntryProto) GetResvDeadlineAt() int64
func (*ClientResvEntryProto) GetTickAt ¶
func (x *ClientResvEntryProto) GetTickAt() int64
func (*ClientResvEntryProto) GetWatchedTube ¶
func (x *ClientResvEntryProto) GetWatchedTube() []string
func (*ClientResvEntryProto) ProtoMessage ¶
func (*ClientResvEntryProto) ProtoMessage()
func (*ClientResvEntryProto) ProtoReflect ¶
func (x *ClientResvEntryProto) ProtoReflect() protoreflect.Message
func (*ClientResvEntryProto) Reset ¶
func (x *ClientResvEntryProto) Reset()
func (*ClientResvEntryProto) String ¶
func (x *ClientResvEntryProto) String() string
type ClusterClient ¶
type ClusterClient interface { // Join, allows a calling node to make a request to join // this cluster. // // It is required that the node that this is called into is a leader node. // Refer: the specific implementation for error codes Join(ctx context.Context, in *JoinRequest, opts ...grpc.CallOption) (*Empty, error) // Leave, allows a calling node to leave the cluster. // // It is required that the node that this is called into is a leader node. // Refer: the specific implementation for error codes Leave(ctx context.Context, in *LeaveRequest, opts ...grpc.CallOption) (*Empty, error) // IsNodeLeader, Check if this current node is a leader IsNodeLeader(ctx context.Context, in *Empty, opts ...grpc.CallOption) (*IsNodeLeaderResponse, error) // Snaoshot, requests the server to return a user defined snapshot of // the specific node. Snapshot(ctx context.Context, in *Empty, opts ...grpc.CallOption) (*Empty, error) }
ClusterClient is the client API for Cluster service.
For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.
func NewClusterClient ¶
func NewClusterClient(cc grpc.ClientConnInterface) ClusterClient
type ClusterServer ¶
type ClusterServer interface { // Join, allows a calling node to make a request to join // this cluster. // // It is required that the node that this is called into is a leader node. // Refer: the specific implementation for error codes Join(context.Context, *JoinRequest) (*Empty, error) // Leave, allows a calling node to leave the cluster. // // It is required that the node that this is called into is a leader node. // Refer: the specific implementation for error codes Leave(context.Context, *LeaveRequest) (*Empty, error) // IsNodeLeader, Check if this current node is a leader IsNodeLeader(context.Context, *Empty) (*IsNodeLeaderResponse, error) // Snaoshot, requests the server to return a user defined snapshot of // the specific node. Snapshot(context.Context, *Empty) (*Empty, error) }
ClusterServer is the server API for Cluster service.
type DeleteRequest ¶
type DeleteRequest struct { // The job identifier of the job to be deleted JobId int64 `protobuf:"varint,1,opt,name=job_id,json=jobId,proto3" json:"job_id,omitempty"` // the proxy identifier forwarding the client's request ProxyId string `protobuf:"bytes,2,opt,name=proxy_id,json=proxyId,proto3" json:"proxy_id,omitempty"` // the client identifier of the client (deleting this job) ClientId string `protobuf:"bytes,3,opt,name=client_id,json=clientId,proto3" json:"client_id,omitempty"` // contains filtered or unexported fields }
func (*DeleteRequest) Descriptor
deprecated
func (*DeleteRequest) Descriptor() ([]byte, []int)
Deprecated: Use DeleteRequest.ProtoReflect.Descriptor instead.
func (*DeleteRequest) GetClientId ¶
func (x *DeleteRequest) GetClientId() string
func (*DeleteRequest) GetJobId ¶
func (x *DeleteRequest) GetJobId() int64
func (*DeleteRequest) GetProxyId ¶
func (x *DeleteRequest) GetProxyId() string
func (*DeleteRequest) ProtoMessage ¶
func (*DeleteRequest) ProtoMessage()
func (*DeleteRequest) ProtoReflect ¶
func (x *DeleteRequest) ProtoReflect() protoreflect.Message
func (*DeleteRequest) Reset ¶
func (x *DeleteRequest) Reset()
func (*DeleteRequest) String ¶
func (x *DeleteRequest) String() string
type Empty ¶
type Empty struct {
// contains filtered or unexported fields
}
func (*Empty) Descriptor
deprecated
func (*Empty) ProtoMessage ¶
func (*Empty) ProtoMessage()
func (*Empty) ProtoReflect ¶
func (x *Empty) ProtoReflect() protoreflect.Message
type GetJobRequest ¶
type GetJobRequest struct { // Id of the job to get JobId int64 `protobuf:"varint,1,opt,name=job_id,json=jobId,proto3" json:"job_id,omitempty"` // contains filtered or unexported fields }
func (*GetJobRequest) Descriptor
deprecated
func (*GetJobRequest) Descriptor() ([]byte, []int)
Deprecated: Use GetJobRequest.ProtoReflect.Descriptor instead.
func (*GetJobRequest) GetJobId ¶
func (x *GetJobRequest) GetJobId() int64
func (*GetJobRequest) ProtoMessage ¶
func (*GetJobRequest) ProtoMessage()
func (*GetJobRequest) ProtoReflect ¶
func (x *GetJobRequest) ProtoReflect() protoreflect.Message
func (*GetJobRequest) Reset ¶
func (x *GetJobRequest) Reset()
func (*GetJobRequest) String ¶
func (x *GetJobRequest) String() string
type GetJobResponse ¶
type GetJobResponse struct { // An optional job if set. Job *JobProto `protobuf:"bytes,1,opt,name=job,proto3" json:"job,omitempty"` // contains filtered or unexported fields }
func (*GetJobResponse) Descriptor
deprecated
func (*GetJobResponse) Descriptor() ([]byte, []int)
Deprecated: Use GetJobResponse.ProtoReflect.Descriptor instead.
func (*GetJobResponse) GetJob ¶
func (x *GetJobResponse) GetJob() *JobProto
func (*GetJobResponse) ProtoMessage ¶
func (*GetJobResponse) ProtoMessage()
func (*GetJobResponse) ProtoReflect ¶
func (x *GetJobResponse) ProtoReflect() protoreflect.Message
func (*GetJobResponse) Reset ¶
func (x *GetJobResponse) Reset()
func (*GetJobResponse) String ¶
func (x *GetJobResponse) String() string
type GetStatsJobYamlRequest ¶
type GetStatsJobYamlRequest struct { // Id of the job to get JobId int64 `protobuf:"varint,1,opt,name=job_id,json=jobId,proto3" json:"job_id,omitempty"` // contains filtered or unexported fields }
func (*GetStatsJobYamlRequest) Descriptor
deprecated
func (*GetStatsJobYamlRequest) Descriptor() ([]byte, []int)
Deprecated: Use GetStatsJobYamlRequest.ProtoReflect.Descriptor instead.
func (*GetStatsJobYamlRequest) GetJobId ¶
func (x *GetStatsJobYamlRequest) GetJobId() int64
func (*GetStatsJobYamlRequest) ProtoMessage ¶
func (*GetStatsJobYamlRequest) ProtoMessage()
func (*GetStatsJobYamlRequest) ProtoReflect ¶
func (x *GetStatsJobYamlRequest) ProtoReflect() protoreflect.Message
func (*GetStatsJobYamlRequest) Reset ¶
func (x *GetStatsJobYamlRequest) Reset()
func (*GetStatsJobYamlRequest) String ¶
func (x *GetStatsJobYamlRequest) String() string
type GetStatsJobYamlResponse ¶
type GetStatsJobYamlResponse struct { // Yaml representation stats (key-value pairs) StatsYaml []byte `protobuf:"bytes,1,opt,name=stats_yaml,json=statsYaml,proto3" json:"stats_yaml,omitempty"` // contains filtered or unexported fields }
func (*GetStatsJobYamlResponse) Descriptor
deprecated
func (*GetStatsJobYamlResponse) Descriptor() ([]byte, []int)
Deprecated: Use GetStatsJobYamlResponse.ProtoReflect.Descriptor instead.
func (*GetStatsJobYamlResponse) GetStatsYaml ¶
func (x *GetStatsJobYamlResponse) GetStatsYaml() []byte
func (*GetStatsJobYamlResponse) ProtoMessage ¶
func (*GetStatsJobYamlResponse) ProtoMessage()
func (*GetStatsJobYamlResponse) ProtoReflect ¶
func (x *GetStatsJobYamlResponse) ProtoReflect() protoreflect.Message
func (*GetStatsJobYamlResponse) Reset ¶
func (x *GetStatsJobYamlResponse) Reset()
func (*GetStatsJobYamlResponse) String ¶
func (x *GetStatsJobYamlResponse) String() string
type GetStatsTubeYamlRequest ¶
type GetStatsTubeYamlRequest struct { // name of the tube TubeName string `protobuf:"bytes,1,opt,name=tube_name,json=tubeName,proto3" json:"tube_name,omitempty"` // contains filtered or unexported fields }
func (*GetStatsTubeYamlRequest) Descriptor
deprecated
func (*GetStatsTubeYamlRequest) Descriptor() ([]byte, []int)
Deprecated: Use GetStatsTubeYamlRequest.ProtoReflect.Descriptor instead.
func (*GetStatsTubeYamlRequest) GetTubeName ¶
func (x *GetStatsTubeYamlRequest) GetTubeName() string
func (*GetStatsTubeYamlRequest) ProtoMessage ¶
func (*GetStatsTubeYamlRequest) ProtoMessage()
func (*GetStatsTubeYamlRequest) ProtoReflect ¶
func (x *GetStatsTubeYamlRequest) ProtoReflect() protoreflect.Message
func (*GetStatsTubeYamlRequest) Reset ¶
func (x *GetStatsTubeYamlRequest) Reset()
func (*GetStatsTubeYamlRequest) String ¶
func (x *GetStatsTubeYamlRequest) String() string
type GetStatsTubeYamlResponse ¶
type GetStatsTubeYamlResponse struct { // Yaml representation stats (key-value pairs) StatsYaml []byte `protobuf:"bytes,1,opt,name=stats_yaml,json=statsYaml,proto3" json:"stats_yaml,omitempty"` // contains filtered or unexported fields }
func (*GetStatsTubeYamlResponse) Descriptor
deprecated
func (*GetStatsTubeYamlResponse) Descriptor() ([]byte, []int)
Deprecated: Use GetStatsTubeYamlResponse.ProtoReflect.Descriptor instead.
func (*GetStatsTubeYamlResponse) GetStatsYaml ¶
func (x *GetStatsTubeYamlResponse) GetStatsYaml() []byte
func (*GetStatsTubeYamlResponse) ProtoMessage ¶
func (*GetStatsTubeYamlResponse) ProtoMessage()
func (*GetStatsTubeYamlResponse) ProtoReflect ¶
func (x *GetStatsTubeYamlResponse) ProtoReflect() protoreflect.Message
func (*GetStatsTubeYamlResponse) Reset ¶
func (x *GetStatsTubeYamlResponse) Reset()
func (*GetStatsTubeYamlResponse) String ¶
func (x *GetStatsTubeYamlResponse) String() string
type GetStatsYamlResponse ¶
type GetStatsYamlResponse struct { // Yaml representation stats (key-value pairs) StatsYaml []byte `protobuf:"bytes,1,opt,name=stats_yaml,json=statsYaml,proto3" json:"stats_yaml,omitempty"` // contains filtered or unexported fields }
func (*GetStatsYamlResponse) Descriptor
deprecated
func (*GetStatsYamlResponse) Descriptor() ([]byte, []int)
Deprecated: Use GetStatsYamlResponse.ProtoReflect.Descriptor instead.
func (*GetStatsYamlResponse) GetStatsYaml ¶
func (x *GetStatsYamlResponse) GetStatsYaml() []byte
func (*GetStatsYamlResponse) ProtoMessage ¶
func (*GetStatsYamlResponse) ProtoMessage()
func (*GetStatsYamlResponse) ProtoReflect ¶
func (x *GetStatsYamlResponse) ProtoReflect() protoreflect.Message
func (*GetStatsYamlResponse) Reset ¶
func (x *GetStatsYamlResponse) Reset()
func (*GetStatsYamlResponse) String ¶
func (x *GetStatsYamlResponse) String() string
type IsNodeLeaderResponse ¶
type IsNodeLeaderResponse struct { // is_leader is a boolean value indicating if this current node is a leader or not IsLeader bool `protobuf:"varint,1,opt,name=is_leader,json=isLeader,proto3" json:"is_leader,omitempty"` // contains filtered or unexported fields }
func (*IsNodeLeaderResponse) Descriptor
deprecated
func (*IsNodeLeaderResponse) Descriptor() ([]byte, []int)
Deprecated: Use IsNodeLeaderResponse.ProtoReflect.Descriptor instead.
func (*IsNodeLeaderResponse) GetIsLeader ¶
func (x *IsNodeLeaderResponse) GetIsLeader() bool
func (*IsNodeLeaderResponse) ProtoMessage ¶
func (*IsNodeLeaderResponse) ProtoMessage()
func (*IsNodeLeaderResponse) ProtoReflect ¶
func (x *IsNodeLeaderResponse) ProtoReflect() protoreflect.Message
func (*IsNodeLeaderResponse) Reset ¶
func (x *IsNodeLeaderResponse) Reset()
func (*IsNodeLeaderResponse) String ¶
func (x *IsNodeLeaderResponse) String() string
type JobProto ¶
type JobProto struct { // Unique identifier for job Id int64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"` // Priority is an integer < 2**32. Jobs with smaller priority values will be // scheduled before jobs with larger priorities. The most urgent priority is 0; // the least urgent priority is 4,294,967,295. Priority uint32 `protobuf:"varint,2,opt,name=priority,proto3" json:"priority,omitempty"` // delay is an integer number of seconds to wait before putting the job in // the ready queue. The job will be in the "delayed" state during this time. // Maximum delay is 2**32-1. Delay int64 `protobuf:"varint,3,opt,name=delay,proto3" json:"delay,omitempty"` // TTR/time to run -- is an integer number of seconds to allow a worker // to run this job. This time is counted from the moment a worker reserves // this job. If the worker does not delete, release, or bury the job within // <ttr> seconds, the job will time out and the server will release the job. // The minimum ttr is 1. If the client sends 0, the server will silently // increase the ttr to 1. Maximum ttr is 2**32-1. Ttr int32 `protobuf:"varint,4,opt,name=ttr,proto3" json:"ttr,omitempty"` // tube_name is the name of the tube associated with this job TubeName string `protobuf:"bytes,5,opt,name=tube_name,json=tubeName,proto3" json:"tube_name,omitempty"` // created is the time in UTC the job is created CreatedAt int64 `protobuf:"varint,6,opt,name=created_at,json=createdAt,proto3" json:"created_at,omitempty"` // ready_at is the time in UTC the job is ready ReadyAt int64 `protobuf:"varint,7,opt,name=ready_at,json=readyAt,proto3" json:"ready_at,omitempty"` // expires_at is the time in UTC, when current reservation expires ExpiresAt int64 `protobuf:"varint,8,opt,name=expires_at,json=expiresAt,proto3" json:"expires_at,omitempty"` // state is the current state of this job State JobStateProto `protobuf:"varint,9,opt,name=state,proto3,enum=coolbeans.api.v1.JobStateProto" json:"state,omitempty"` // reserved_by is the identifier of the client which has // reserved this job, the value is empty if un-reserved ReservedBy string `protobuf:"bytes,10,opt,name=reserved_by,json=reservedBy,proto3" json:"reserved_by,omitempty"` // body_size is an integer indicating the size of the job body, not including the // trailing "\r\n". This value must be less than max-job-size (default: 2**16) BodySize int32 `protobuf:"varint,11,opt,name=body_size,json=bodySize,proto3" json:"body_size,omitempty"` // body is the job body -- a sequence of bytes of length BodySize Body []byte `protobuf:"bytes,12,opt,name=body,proto3" json:"body,omitempty"` // buried_at the clock time when the job is buried BuriedAt int64 `protobuf:"varint,13,opt,name=buried_at,json=buriedAt,proto3" json:"buried_at,omitempty"` // reserve_count is the number of times this job has been reserved. ReserveCount uint32 `protobuf:"varint,14,opt,name=reserve_count,json=reserveCount,proto3" json:"reserve_count,omitempty"` // timeoutCount is the number of times this job has timed out during a reservation. TimeoutCount uint32 `protobuf:"varint,15,opt,name=timeout_count,json=timeoutCount,proto3" json:"timeout_count,omitempty"` // release_count is the number of times a client has released this job from a reservation. ReleaseCount uint32 `protobuf:"varint,16,opt,name=release_count,json=releaseCount,proto3" json:"release_count,omitempty"` // bury_count is the number of times this job has been buried. BuryCount uint32 `protobuf:"varint,17,opt,name=bury_count,json=buryCount,proto3" json:"bury_count,omitempty"` // kick_count is the number of times this job has been kicked KickCount uint32 `protobuf:"varint,18,opt,name=kick_count,json=kickCount,proto3" json:"kick_count,omitempty"` // contains filtered or unexported fields }
func (*JobProto) Descriptor
deprecated
func (*JobProto) GetBodySize ¶
func (*JobProto) GetBuriedAt ¶
func (*JobProto) GetBuryCount ¶
func (*JobProto) GetCreatedAt ¶
func (*JobProto) GetExpiresAt ¶
func (*JobProto) GetKickCount ¶
func (*JobProto) GetPriority ¶
func (*JobProto) GetReadyAt ¶
func (*JobProto) GetReleaseCount ¶
func (*JobProto) GetReserveCount ¶
func (*JobProto) GetReservedBy ¶
func (*JobProto) GetState ¶
func (x *JobProto) GetState() JobStateProto
func (*JobProto) GetTimeoutCount ¶
func (*JobProto) GetTubeName ¶
func (*JobProto) ProtoMessage ¶
func (*JobProto) ProtoMessage()
func (*JobProto) ProtoReflect ¶
func (x *JobProto) ProtoReflect() protoreflect.Message
type JobStateMachineClient ¶
type JobStateMachineClient interface { // Put creates a new job with the provided job parameters // // The response contains the identifier of the job created Put(ctx context.Context, in *PutRequest, opts ...grpc.CallOption) (*PutResponse, error) // Delete a job with the provided job id Delete(ctx context.Context, in *DeleteRequest, opts ...grpc.CallOption) (*Empty, error) // Reserve is a request to reserve a channel for a client by this proxy Reserve(ctx context.Context, in *ReserveRequest, opts ...grpc.CallOption) (*ReserveResponse, error) // StreamReserveUpdates is a streaming RPC from the server back to client // // Reservations are streamed as they are available for this proxy StreamReserveUpdates(ctx context.Context, in *ReserveUpdateRequest, opts ...grpc.CallOption) (JobStateMachine_StreamReserveUpdatesClient, error) // CheckClientState queries the job state machine whether the provided list of clientIds are waiting for reservations. CheckClientState(ctx context.Context, in *CheckClientStateRequest, opts ...grpc.CallOption) (*CheckClientStateResponse, error) // Release a reserved job back to either a Ready or a Delayed state Release(ctx context.Context, in *ReleaseRequest, opts ...grpc.CallOption) (*Empty, error) // Extend a reserved job's reservation TTL by its TTR (time-to-run) Touch(ctx context.Context, in *TouchRequest, opts ...grpc.CallOption) (*Empty, error) // Bury this job, if this job is in the reserved state Bury(ctx context.Context, in *BuryRequest, opts ...grpc.CallOption) (*Empty, error) // Kick this job, if this job is in a buried stated to ready state Kick(ctx context.Context, in *KickRequest, opts ...grpc.CallOption) (*Empty, error) // Kick at-most n jobs in this tube, KickN(ctx context.Context, in *KickNRequest, opts ...grpc.CallOption) (*KickNResponse, error) // Peek a specific job (by the JobID) GetJob(ctx context.Context, in *GetJobRequest, opts ...grpc.CallOption) (*GetJobResponse, error) // Peek a tube's buried jobs PeekBuried(ctx context.Context, in *PeekRequest, opts ...grpc.CallOption) (*PeekResponse, error) // Peek a tube's delayed jobs PeekDelayed(ctx context.Context, in *PeekRequest, opts ...grpc.CallOption) (*PeekResponse, error) // Peek a tube's ready jobs PeekReady(ctx context.Context, in *PeekRequest, opts ...grpc.CallOption) (*PeekResponse, error) // Retrieve a job statistics GetStatsJobYaml(ctx context.Context, in *GetStatsJobYamlRequest, opts ...grpc.CallOption) (*GetStatsJobYamlResponse, error) // Retrieve a tube's statistics GetStatsTubeYaml(ctx context.Context, in *GetStatsTubeYamlRequest, opts ...grpc.CallOption) (*GetStatsTubeYamlResponse, error) // Retrieve overall statistics GetStatsYaml(ctx context.Context, in *Empty, opts ...grpc.CallOption) (*GetStatsYamlResponse, error) // Retreive a list of all Tubes ListTubes(ctx context.Context, in *Empty, opts ...grpc.CallOption) (*ListTubesResponse, error) }
JobStateMachineClient is the client API for JobStateMachine service.
For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.
func NewJobStateMachineClient ¶
func NewJobStateMachineClient(cc grpc.ClientConnInterface) JobStateMachineClient
type JobStateMachineServer ¶
type JobStateMachineServer interface { // Put creates a new job with the provided job parameters // // The response contains the identifier of the job created Put(context.Context, *PutRequest) (*PutResponse, error) // Delete a job with the provided job id Delete(context.Context, *DeleteRequest) (*Empty, error) // Reserve is a request to reserve a channel for a client by this proxy Reserve(context.Context, *ReserveRequest) (*ReserveResponse, error) // StreamReserveUpdates is a streaming RPC from the server back to client // // Reservations are streamed as they are available for this proxy StreamReserveUpdates(*ReserveUpdateRequest, JobStateMachine_StreamReserveUpdatesServer) error // CheckClientState queries the job state machine whether the provided list of clientIds are waiting for reservations. CheckClientState(context.Context, *CheckClientStateRequest) (*CheckClientStateResponse, error) // Release a reserved job back to either a Ready or a Delayed state Release(context.Context, *ReleaseRequest) (*Empty, error) // Extend a reserved job's reservation TTL by its TTR (time-to-run) Touch(context.Context, *TouchRequest) (*Empty, error) // Bury this job, if this job is in the reserved state Bury(context.Context, *BuryRequest) (*Empty, error) // Kick this job, if this job is in a buried stated to ready state Kick(context.Context, *KickRequest) (*Empty, error) // Kick at-most n jobs in this tube, KickN(context.Context, *KickNRequest) (*KickNResponse, error) // Peek a specific job (by the JobID) GetJob(context.Context, *GetJobRequest) (*GetJobResponse, error) // Peek a tube's buried jobs PeekBuried(context.Context, *PeekRequest) (*PeekResponse, error) // Peek a tube's delayed jobs PeekDelayed(context.Context, *PeekRequest) (*PeekResponse, error) // Peek a tube's ready jobs PeekReady(context.Context, *PeekRequest) (*PeekResponse, error) // Retrieve a job statistics GetStatsJobYaml(context.Context, *GetStatsJobYamlRequest) (*GetStatsJobYamlResponse, error) // Retrieve a tube's statistics GetStatsTubeYaml(context.Context, *GetStatsTubeYamlRequest) (*GetStatsTubeYamlResponse, error) // Retrieve overall statistics GetStatsYaml(context.Context, *Empty) (*GetStatsYamlResponse, error) // Retreive a list of all Tubes ListTubes(context.Context, *Empty) (*ListTubesResponse, error) }
JobStateMachineServer is the server API for JobStateMachine service.
type JobStateMachine_StreamReserveUpdatesClient ¶
type JobStateMachine_StreamReserveUpdatesClient interface { Recv() (*ReserveResponse, error) grpc.ClientStream }
type JobStateMachine_StreamReserveUpdatesServer ¶
type JobStateMachine_StreamReserveUpdatesServer interface { Send(*ReserveResponse) error grpc.ServerStream }
type JobStateProto ¶
type JobStateProto int32
const ( JobStateProto_INITIAL JobStateProto = 0 JobStateProto_READY JobStateProto = 1 JobStateProto_RESERVED JobStateProto = 2 JobStateProto_BURIED JobStateProto = 3 JobStateProto_DELAYED JobStateProto = 4 JobStateProto_DELETED JobStateProto = 5 )
func (JobStateProto) Descriptor ¶
func (JobStateProto) Descriptor() protoreflect.EnumDescriptor
func (JobStateProto) Enum ¶
func (x JobStateProto) Enum() *JobStateProto
func (JobStateProto) EnumDescriptor
deprecated
func (JobStateProto) EnumDescriptor() ([]byte, []int)
Deprecated: Use JobStateProto.Descriptor instead.
func (JobStateProto) Number ¶
func (x JobStateProto) Number() protoreflect.EnumNumber
func (JobStateProto) String ¶
func (x JobStateProto) String() string
func (JobStateProto) Type ¶
func (JobStateProto) Type() protoreflect.EnumType
type JoinRequest ¶
type JoinRequest struct { // Node ID of the node interested in joining NodeId string `protobuf:"bytes,1,opt,name=node_id,json=nodeId,proto3" json:"node_id,omitempty"` // Address of the replica interested in joining Addr string `protobuf:"bytes,2,opt,name=addr,proto3" json:"addr,omitempty"` // contains filtered or unexported fields }
func (*JoinRequest) Descriptor
deprecated
func (*JoinRequest) Descriptor() ([]byte, []int)
Deprecated: Use JoinRequest.ProtoReflect.Descriptor instead.
func (*JoinRequest) GetAddr ¶
func (x *JoinRequest) GetAddr() string
func (*JoinRequest) GetNodeId ¶
func (x *JoinRequest) GetNodeId() string
func (*JoinRequest) ProtoMessage ¶
func (*JoinRequest) ProtoMessage()
func (*JoinRequest) ProtoReflect ¶
func (x *JoinRequest) ProtoReflect() protoreflect.Message
func (*JoinRequest) Reset ¶
func (x *JoinRequest) Reset()
func (*JoinRequest) String ¶
func (x *JoinRequest) String() string
type KickNRequest ¶
type KickNRequest struct { // Refer Job.tube_name TubeName string `protobuf:"bytes,1,opt,name=tube_name,json=tubeName,proto3" json:"tube_name,omitempty"` // bound is the maximum number of jobs to kick Bound int32 `protobuf:"varint,2,opt,name=bound,proto3" json:"bound,omitempty"` // contains filtered or unexported fields }
func (*KickNRequest) Descriptor
deprecated
func (*KickNRequest) Descriptor() ([]byte, []int)
Deprecated: Use KickNRequest.ProtoReflect.Descriptor instead.
func (*KickNRequest) GetBound ¶
func (x *KickNRequest) GetBound() int32
func (*KickNRequest) GetTubeName ¶
func (x *KickNRequest) GetTubeName() string
func (*KickNRequest) ProtoMessage ¶
func (*KickNRequest) ProtoMessage()
func (*KickNRequest) ProtoReflect ¶
func (x *KickNRequest) ProtoReflect() protoreflect.Message
func (*KickNRequest) Reset ¶
func (x *KickNRequest) Reset()
func (*KickNRequest) String ¶
func (x *KickNRequest) String() string
type KickNResponse ¶
type KickNResponse struct { // The actual number of jobs kicked JobsKicked int32 `protobuf:"varint,1,opt,name=jobs_kicked,json=jobsKicked,proto3" json:"jobs_kicked,omitempty"` // contains filtered or unexported fields }
func (*KickNResponse) Descriptor
deprecated
func (*KickNResponse) Descriptor() ([]byte, []int)
Deprecated: Use KickNResponse.ProtoReflect.Descriptor instead.
func (*KickNResponse) GetJobsKicked ¶
func (x *KickNResponse) GetJobsKicked() int32
func (*KickNResponse) ProtoMessage ¶
func (*KickNResponse) ProtoMessage()
func (*KickNResponse) ProtoReflect ¶
func (x *KickNResponse) ProtoReflect() protoreflect.Message
func (*KickNResponse) Reset ¶
func (x *KickNResponse) Reset()
func (*KickNResponse) String ¶
func (x *KickNResponse) String() string
type KickRequest ¶
type KickRequest struct { // The job identifier of the job to be Kicked JobId int64 `protobuf:"varint,1,opt,name=job_id,json=jobId,proto3" json:"job_id,omitempty"` // contains filtered or unexported fields }
func (*KickRequest) Descriptor
deprecated
func (*KickRequest) Descriptor() ([]byte, []int)
Deprecated: Use KickRequest.ProtoReflect.Descriptor instead.
func (*KickRequest) GetJobId ¶
func (x *KickRequest) GetJobId() int64
func (*KickRequest) ProtoMessage ¶
func (*KickRequest) ProtoMessage()
func (*KickRequest) ProtoReflect ¶
func (x *KickRequest) ProtoReflect() protoreflect.Message
func (*KickRequest) Reset ¶
func (x *KickRequest) Reset()
func (*KickRequest) String ¶
func (x *KickRequest) String() string
type LeaveRequest ¶
type LeaveRequest struct { // Node ID of the node requested to leave NodeId string `protobuf:"bytes,1,opt,name=node_id,json=nodeId,proto3" json:"node_id,omitempty"` // contains filtered or unexported fields }
func (*LeaveRequest) Descriptor
deprecated
func (*LeaveRequest) Descriptor() ([]byte, []int)
Deprecated: Use LeaveRequest.ProtoReflect.Descriptor instead.
func (*LeaveRequest) GetNodeId ¶
func (x *LeaveRequest) GetNodeId() string
func (*LeaveRequest) ProtoMessage ¶
func (*LeaveRequest) ProtoMessage()
func (*LeaveRequest) ProtoReflect ¶
func (x *LeaveRequest) ProtoReflect() protoreflect.Message
func (*LeaveRequest) Reset ¶
func (x *LeaveRequest) Reset()
func (*LeaveRequest) String ¶
func (x *LeaveRequest) String() string
type ListTubesResponse ¶
type ListTubesResponse struct { Tubes []string `protobuf:"bytes,1,rep,name=tubes,proto3" json:"tubes,omitempty"` // contains filtered or unexported fields }
func (*ListTubesResponse) Descriptor
deprecated
func (*ListTubesResponse) Descriptor() ([]byte, []int)
Deprecated: Use ListTubesResponse.ProtoReflect.Descriptor instead.
func (*ListTubesResponse) GetTubes ¶
func (x *ListTubesResponse) GetTubes() []string
func (*ListTubesResponse) ProtoMessage ¶
func (*ListTubesResponse) ProtoMessage()
func (*ListTubesResponse) ProtoReflect ¶
func (x *ListTubesResponse) ProtoReflect() protoreflect.Message
func (*ListTubesResponse) Reset ¶
func (x *ListTubesResponse) Reset()
func (*ListTubesResponse) String ¶
func (x *ListTubesResponse) String() string
type OpType ¶
type OpType int32
const ( OpType_UNKNOWN OpType = 0 OpType_PUT OpType = 1 OpType_RESERVE OpType = 2 OpType_TICK OpType = 3 OpType_DELETE OpType = 4 OpType_RELEASE OpType = 5 OpType_CHECK_CLIENT_STATE OpType = 6 OpType_BURY OpType = 7 OpType_KICK OpType = 8 OpType_KICKN OpType = 9 OpType_TOUCH OpType = 10 OpType_GET_JOB OpType = 11 OpType_PEEK_READY OpType = 12 OpType_PEEK_BURIED OpType = 13 OpType_PEEK_DELAYED OpType = 14 OpType_STATS_JOB_YAML OpType = 15 OpType_STATS_TUBE_YAML OpType = 16 OpType_STATS_YAML OpType = 17 OpType_LIST_TUBES OpType = 18 )
func (OpType) Descriptor ¶
func (OpType) Descriptor() protoreflect.EnumDescriptor
func (OpType) EnumDescriptor
deprecated
func (OpType) Number ¶
func (x OpType) Number() protoreflect.EnumNumber
func (OpType) Type ¶
func (OpType) Type() protoreflect.EnumType
type PeekRequest ¶
type PeekRequest struct { // the name of the tube TubeName string `protobuf:"bytes,1,opt,name=tube_name,json=tubeName,proto3" json:"tube_name,omitempty"` // contains filtered or unexported fields }
func (*PeekRequest) Descriptor
deprecated
func (*PeekRequest) Descriptor() ([]byte, []int)
Deprecated: Use PeekRequest.ProtoReflect.Descriptor instead.
func (*PeekRequest) GetTubeName ¶
func (x *PeekRequest) GetTubeName() string
func (*PeekRequest) ProtoMessage ¶
func (*PeekRequest) ProtoMessage()
func (*PeekRequest) ProtoReflect ¶
func (x *PeekRequest) ProtoReflect() protoreflect.Message
func (*PeekRequest) Reset ¶
func (x *PeekRequest) Reset()
func (*PeekRequest) String ¶
func (x *PeekRequest) String() string
type PeekResponse ¶
type PeekResponse struct { // An optional job if set. Job *JobProto `protobuf:"bytes,1,opt,name=job,proto3" json:"job,omitempty"` // contains filtered or unexported fields }
func (*PeekResponse) Descriptor
deprecated
func (*PeekResponse) Descriptor() ([]byte, []int)
Deprecated: Use PeekResponse.ProtoReflect.Descriptor instead.
func (*PeekResponse) GetJob ¶
func (x *PeekResponse) GetJob() *JobProto
func (*PeekResponse) ProtoMessage ¶
func (*PeekResponse) ProtoMessage()
func (*PeekResponse) ProtoReflect ¶
func (x *PeekResponse) ProtoReflect() protoreflect.Message
func (*PeekResponse) Reset ¶
func (x *PeekResponse) Reset()
func (*PeekResponse) String ¶
func (x *PeekResponse) String() string
type PutRequest ¶
type PutRequest struct { // Refer Job.priority Priority uint32 `protobuf:"varint,1,opt,name=priority,proto3" json:"priority,omitempty"` // Refer Job.delay Delay int64 `protobuf:"varint,2,opt,name=delay,proto3" json:"delay,omitempty"` // Refer Job.ttr Ttr int32 `protobuf:"varint,3,opt,name=ttr,proto3" json:"ttr,omitempty"` // Refer Job.tube_na,e TubeName string `protobuf:"bytes,4,opt,name=tube_name,json=tubeName,proto3" json:"tube_name,omitempty"` // Refer Job.body_size BodySize int32 `protobuf:"varint,5,opt,name=body_size,json=bodySize,proto3" json:"body_size,omitempty"` // Refer Job.body Body []byte `protobuf:"bytes,6,opt,name=body,proto3" json:"body,omitempty"` // contains filtered or unexported fields }
func (*PutRequest) Descriptor
deprecated
func (*PutRequest) Descriptor() ([]byte, []int)
Deprecated: Use PutRequest.ProtoReflect.Descriptor instead.
func (*PutRequest) GetBody ¶
func (x *PutRequest) GetBody() []byte
func (*PutRequest) GetBodySize ¶
func (x *PutRequest) GetBodySize() int32
func (*PutRequest) GetDelay ¶
func (x *PutRequest) GetDelay() int64
func (*PutRequest) GetPriority ¶
func (x *PutRequest) GetPriority() uint32
func (*PutRequest) GetTtr ¶
func (x *PutRequest) GetTtr() int32
func (*PutRequest) GetTubeName ¶
func (x *PutRequest) GetTubeName() string
func (*PutRequest) ProtoMessage ¶
func (*PutRequest) ProtoMessage()
func (*PutRequest) ProtoReflect ¶
func (x *PutRequest) ProtoReflect() protoreflect.Message
func (*PutRequest) Reset ¶
func (x *PutRequest) Reset()
func (*PutRequest) String ¶
func (x *PutRequest) String() string
type PutResponse ¶
type PutResponse struct { // The job identifier of the new job created JobId int64 `protobuf:"varint,1,opt,name=job_id,json=jobId,proto3" json:"job_id,omitempty"` // contains filtered or unexported fields }
func (*PutResponse) Descriptor
deprecated
func (*PutResponse) Descriptor() ([]byte, []int)
Deprecated: Use PutResponse.ProtoReflect.Descriptor instead.
func (*PutResponse) GetJobId ¶
func (x *PutResponse) GetJobId() int64
func (*PutResponse) ProtoMessage ¶
func (*PutResponse) ProtoMessage()
func (*PutResponse) ProtoReflect ¶
func (x *PutResponse) ProtoReflect() protoreflect.Message
func (*PutResponse) Reset ¶
func (x *PutResponse) Reset()
func (*PutResponse) String ¶
func (x *PutResponse) String() string
type ReleaseRequest ¶
type ReleaseRequest struct { // The job identifier of the job to be released JobId int64 `protobuf:"varint,1,opt,name=job_id,json=jobId,proto3" json:"job_id,omitempty"` // The identifier of the client asking for the release ClientId string `protobuf:"bytes,2,opt,name=client_id,json=clientId,proto3" json:"client_id,omitempty"` // proxy_id is the id of the proxy server that // forwarded this request ProxyId string `protobuf:"bytes,3,opt,name=proxy_id,json=proxyId,proto3" json:"proxy_id,omitempty"` // A delay if set to a value > 0 marks the job as delayed Delay int64 `protobuf:"varint,4,opt,name=delay,proto3" json:"delay,omitempty"` // the new priority with which this job is released Priority uint32 `protobuf:"varint,5,opt,name=priority,proto3" json:"priority,omitempty"` // contains filtered or unexported fields }
func (*ReleaseRequest) Descriptor
deprecated
func (*ReleaseRequest) Descriptor() ([]byte, []int)
Deprecated: Use ReleaseRequest.ProtoReflect.Descriptor instead.
func (*ReleaseRequest) GetClientId ¶
func (x *ReleaseRequest) GetClientId() string
func (*ReleaseRequest) GetDelay ¶
func (x *ReleaseRequest) GetDelay() int64
func (*ReleaseRequest) GetJobId ¶
func (x *ReleaseRequest) GetJobId() int64
func (*ReleaseRequest) GetPriority ¶
func (x *ReleaseRequest) GetPriority() uint32
func (*ReleaseRequest) GetProxyId ¶
func (x *ReleaseRequest) GetProxyId() string
func (*ReleaseRequest) ProtoMessage ¶
func (*ReleaseRequest) ProtoMessage()
func (*ReleaseRequest) ProtoReflect ¶
func (x *ReleaseRequest) ProtoReflect() protoreflect.Message
func (*ReleaseRequest) Reset ¶
func (x *ReleaseRequest) Reset()
func (*ReleaseRequest) String ¶
func (x *ReleaseRequest) String() string
type Reservation ¶
type Reservation struct { // request_id associated with this reservation RequestId string `protobuf:"bytes,1,opt,name=request_id,json=requestId,proto3" json:"request_id,omitempty"` // client id assinged to this reservation ClientId string `protobuf:"bytes,2,opt,name=client_id,json=clientId,proto3" json:"client_id,omitempty"` // Result of this reservation Status ReservationStatus `protobuf:"varint,3,opt,name=Status,proto3,enum=coolbeans.api.v1.ReservationStatus" json:"Status,omitempty"` // job id (assigned) if Status is matched JobId int64 `protobuf:"varint,4,opt,name=job_id,json=jobId,proto3" json:"job_id,omitempty"` // job body size (assigned) if Status is matched BodySize int32 `protobuf:"varint,5,opt,name=body_size,json=bodySize,proto3" json:"body_size,omitempty"` // job body (assigned) if Status is matched Body []byte `protobuf:"bytes,6,opt,name=body,proto3" json:"body,omitempty"` // error message (assigned) if Status is error ErrorMsg string `protobuf:"bytes,7,opt,name=error_msg,json=errorMsg,proto3" json:"error_msg,omitempty"` // proxy_id is the id of the proxy server that // forwarded this reservation request ProxyId string `protobuf:"bytes,8,opt,name=proxy_id,json=proxyId,proto3" json:"proxy_id,omitempty"` // contains filtered or unexported fields }
func (*Reservation) Descriptor
deprecated
func (*Reservation) Descriptor() ([]byte, []int)
Deprecated: Use Reservation.ProtoReflect.Descriptor instead.
func (*Reservation) GetBody ¶
func (x *Reservation) GetBody() []byte
func (*Reservation) GetBodySize ¶
func (x *Reservation) GetBodySize() int32
func (*Reservation) GetClientId ¶
func (x *Reservation) GetClientId() string
func (*Reservation) GetErrorMsg ¶
func (x *Reservation) GetErrorMsg() string
func (*Reservation) GetJobId ¶
func (x *Reservation) GetJobId() int64
func (*Reservation) GetProxyId ¶
func (x *Reservation) GetProxyId() string
func (*Reservation) GetRequestId ¶
func (x *Reservation) GetRequestId() string
func (*Reservation) GetStatus ¶
func (x *Reservation) GetStatus() ReservationStatus
func (*Reservation) ProtoMessage ¶
func (*Reservation) ProtoMessage()
func (*Reservation) ProtoReflect ¶
func (x *Reservation) ProtoReflect() protoreflect.Message
func (*Reservation) Reset ¶
func (x *Reservation) Reset()
func (*Reservation) String ¶
func (x *Reservation) String() string
type ReservationStatus ¶
type ReservationStatus int32
const ( // Unknown ~~> UnknownRS (yuck!!) // Note that enum values use C++ scoping rules, meaning // that enum values are siblings of their type, not children of it. // Therefore, "Unknown" must be unique within "coolbeans.api.v1", // not just within "ResultCode" ReservationStatus_UnknownRS ReservationStatus = 0 ReservationStatus_Queued ReservationStatus = 1 ReservationStatus_DeadlineSoon ReservationStatus = 2 ReservationStatus_Matched ReservationStatus = 3 ReservationStatus_Timeout ReservationStatus = 4 ReservationStatus_Error ReservationStatus = 5 )
func (ReservationStatus) Descriptor ¶
func (ReservationStatus) Descriptor() protoreflect.EnumDescriptor
func (ReservationStatus) Enum ¶
func (x ReservationStatus) Enum() *ReservationStatus
func (ReservationStatus) EnumDescriptor
deprecated
func (ReservationStatus) EnumDescriptor() ([]byte, []int)
Deprecated: Use ReservationStatus.Descriptor instead.
func (ReservationStatus) Number ¶
func (x ReservationStatus) Number() protoreflect.EnumNumber
func (ReservationStatus) String ¶
func (x ReservationStatus) String() string
func (ReservationStatus) Type ¶
func (ReservationStatus) Type() protoreflect.EnumType
type Reservations ¶
type Reservations struct { // Reservation object encapsulated in this response Entries []*Reservation `protobuf:"bytes,1,rep,name=entries,proto3" json:"entries,omitempty"` // contains filtered or unexported fields }
func (*Reservations) Descriptor
deprecated
func (*Reservations) Descriptor() ([]byte, []int)
Deprecated: Use Reservations.ProtoReflect.Descriptor instead.
func (*Reservations) GetEntries ¶
func (x *Reservations) GetEntries() []*Reservation
func (*Reservations) ProtoMessage ¶
func (*Reservations) ProtoMessage()
func (*Reservations) ProtoReflect ¶
func (x *Reservations) ProtoReflect() protoreflect.Message
func (*Reservations) Reset ¶
func (x *Reservations) Reset()
func (*Reservations) String ¶
func (x *Reservations) String() string
type ReserveRequest ¶
type ReserveRequest struct { // client id of the reservation ClientId string `protobuf:"bytes,1,opt,name=client_id,json=clientId,proto3" json:"client_id,omitempty"` // request id identify this reservation RequestId string `protobuf:"bytes,2,opt,name=request_id,json=requestId,proto3" json:"request_id,omitempty"` // reservation timeout in seconds TimeoutSecs int32 `protobuf:"varint,3,opt,name=timeout_secs,json=timeoutSecs,proto3" json:"timeout_secs,omitempty"` // array of tubes to watch WatchedTubes []string `protobuf:"bytes,4,rep,name=watched_tubes,json=watchedTubes,proto3" json:"watched_tubes,omitempty"` // the proxy identifier forwarding the client's request ProxyId string `protobuf:"bytes,5,opt,name=proxy_id,json=proxyId,proto3" json:"proxy_id,omitempty"` // contains filtered or unexported fields }
func (*ReserveRequest) Descriptor
deprecated
func (*ReserveRequest) Descriptor() ([]byte, []int)
Deprecated: Use ReserveRequest.ProtoReflect.Descriptor instead.
func (*ReserveRequest) GetClientId ¶
func (x *ReserveRequest) GetClientId() string
func (*ReserveRequest) GetProxyId ¶
func (x *ReserveRequest) GetProxyId() string
func (*ReserveRequest) GetRequestId ¶
func (x *ReserveRequest) GetRequestId() string
func (*ReserveRequest) GetTimeoutSecs ¶
func (x *ReserveRequest) GetTimeoutSecs() int32
func (*ReserveRequest) GetWatchedTubes ¶
func (x *ReserveRequest) GetWatchedTubes() []string
func (*ReserveRequest) ProtoMessage ¶
func (*ReserveRequest) ProtoMessage()
func (*ReserveRequest) ProtoReflect ¶
func (x *ReserveRequest) ProtoReflect() protoreflect.Message
func (*ReserveRequest) Reset ¶
func (x *ReserveRequest) Reset()
func (*ReserveRequest) String ¶
func (x *ReserveRequest) String() string
type ReserveResponse ¶
type ReserveResponse struct { // Reservation object encapsulated in this response Reservation *Reservation `protobuf:"bytes,1,opt,name=reservation,proto3" json:"reservation,omitempty"` // contains filtered or unexported fields }
func (*ReserveResponse) Descriptor
deprecated
func (*ReserveResponse) Descriptor() ([]byte, []int)
Deprecated: Use ReserveResponse.ProtoReflect.Descriptor instead.
func (*ReserveResponse) GetReservation ¶
func (x *ReserveResponse) GetReservation() *Reservation
func (*ReserveResponse) ProtoMessage ¶
func (*ReserveResponse) ProtoMessage()
func (*ReserveResponse) ProtoReflect ¶
func (x *ReserveResponse) ProtoReflect() protoreflect.Message
func (*ReserveResponse) Reset ¶
func (x *ReserveResponse) Reset()
func (*ReserveResponse) String ¶
func (x *ReserveResponse) String() string
type ReserveUpdateRequest ¶
type ReserveUpdateRequest struct { // the proxy identifier requesting reservation update ProxyId string `protobuf:"bytes,1,opt,name=proxy_id,json=proxyId,proto3" json:"proxy_id,omitempty"` // contains filtered or unexported fields }
func (*ReserveUpdateRequest) Descriptor
deprecated
func (*ReserveUpdateRequest) Descriptor() ([]byte, []int)
Deprecated: Use ReserveUpdateRequest.ProtoReflect.Descriptor instead.
func (*ReserveUpdateRequest) GetProxyId ¶
func (x *ReserveUpdateRequest) GetProxyId() string
func (*ReserveUpdateRequest) ProtoMessage ¶
func (*ReserveUpdateRequest) ProtoMessage()
func (*ReserveUpdateRequest) ProtoReflect ¶
func (x *ReserveUpdateRequest) ProtoReflect() protoreflect.Message
func (*ReserveUpdateRequest) Reset ¶
func (x *ReserveUpdateRequest) Reset()
func (*ReserveUpdateRequest) String ¶
func (x *ReserveUpdateRequest) String() string
type ReserveUpdateResponse ¶
type ReserveUpdateResponse struct { // Reservations encapsulated in this response Reservation *Reservation `protobuf:"bytes,1,opt,name=reservation,proto3" json:"reservation,omitempty"` // contains filtered or unexported fields }
func (*ReserveUpdateResponse) Descriptor
deprecated
func (*ReserveUpdateResponse) Descriptor() ([]byte, []int)
Deprecated: Use ReserveUpdateResponse.ProtoReflect.Descriptor instead.
func (*ReserveUpdateResponse) GetReservation ¶
func (x *ReserveUpdateResponse) GetReservation() *Reservation
func (*ReserveUpdateResponse) ProtoMessage ¶
func (*ReserveUpdateResponse) ProtoMessage()
func (*ReserveUpdateResponse) ProtoReflect ¶
func (x *ReserveUpdateResponse) ProtoReflect() protoreflect.Message
func (*ReserveUpdateResponse) Reset ¶
func (x *ReserveUpdateResponse) Reset()
func (*ReserveUpdateResponse) String ¶
func (x *ReserveUpdateResponse) String() string
type ResultCode ¶
type ResultCode int32
C & P from GRPC error codes https://github.com/grpc/grpc-go/blob/master/codes/codes.go
const ( // OK is returned on success. ResultCode_OK ResultCode = 0 // Canceled indicates the operation was canceled (typically by the caller). ResultCode_Canceled ResultCode = 1 // Unknown error. An example of where this error may be returned is // if a Status value received from another address space belongs to // an error-space that is not known in this address space. Also // errors raised by APIs that do not return enough error information // may be converted to this error. ResultCode_Unknown ResultCode = 2 // InvalidArgument indicates client specified an invalid argument. // Note that this differs from FailedPrecondition. It indicates arguments // that are problematic regardless of the state of the system // (e.g., a malformed file name). ResultCode_InvalidArgument ResultCode = 3 // DeadlineExceeded means operation expired before completion. // For operations that change the state of the system, this error may be // returned even if the operation has completed successfully. For // example, a successful response from a server could have been delayed // long enough for the deadline to expire. ResultCode_DeadlineExceeded ResultCode = 4 // NotFound means some requested entity (e.g., file or directory) was // not found. ResultCode_NotFound ResultCode = 5 // AlreadyExists means an attempt to create an entity failed because one // already exists. ResultCode_AlreadyExists ResultCode = 6 // PermissionDenied indicates the caller does not have permission to // execute the specified operation. It must not be used for rejections // caused by exhausting some resource (use ResourceExhausted // instead for those errors). It must not be // used if the caller cannot be identified (use Unauthenticated // instead for those errors). ResultCode_PermissionDenied ResultCode = 7 // ResourceExhausted indicates some resource has been exhausted, perhaps // a per-user quota, or perhaps the entire file system is out of space. ResultCode_ResourceExhausted ResultCode = 8 // FailedPrecondition indicates operation was rejected because the // system is not in a state required for the operation's execution. // For example, directory to be deleted may be non-empty, an rmdir // operation is applied to a non-directory, etc. // // A litmus test that may help a service implementor in deciding // between FailedPrecondition, Aborted, and Unavailable: // (a) Use Unavailable if the client can retry just the failing call. // (b) Use Aborted if the client should retry at a higher-level // (e.g., restarting a read-modify-write sequence). // (c) Use FailedPrecondition if the client should not retry until // the system state has been explicitly fixed. E.g., if an "rmdir" // fails because the directory is non-empty, FailedPrecondition // should be returned since the client should not retry unless // they have first fixed up the directory by deleting files from it. // (d) Use FailedPrecondition if the client performs conditional // REST Get/Update/Delete on a resource and the resource on the // server does not match the condition. E.g., conflicting // read-modify-write on the same resource. ResultCode_FailedPrecondition ResultCode = 9 // Aborted indicates the operation was aborted, typically due to a // concurrency issue like sequencer check failures, transaction aborts, // etc. // // See litmus test above for deciding between FailedPrecondition, // Aborted, and Unavailable. ResultCode_Aborted ResultCode = 10 // OutOfRange means operation was attempted past the valid range. // E.g., seeking or reading past end of file. // // Unlike InvalidArgument, this error indicates a problem that may // be fixed if the system state changes. For example, a 32-bit file // system will generate InvalidArgument if asked to read at an // offset that is not in the range [0,2^32-1], but it will generate // OutOfRange if asked to read from an offset past the current // file size. // // There is a fair bit of overlap between FailedPrecondition and // OutOfRange. We recommend using OutOfRange (the more specific // error) when it applies so that callers who are iterating through // a space can easily look for an OutOfRange error to detect when // they are done. ResultCode_OutOfRange ResultCode = 11 // Unimplemented indicates operation is not implemented or not // supported/enabled in this service. ResultCode_Unimplemented ResultCode = 12 // Internal errors. Means some invariants expected by underlying // system has been broken. If you see one of these errors, // something is very broken. ResultCode_Internal ResultCode = 13 // This is a most likely a transient condition and may be corrected // by retrying with a backoff. Note that it is not always safe to retry // non-idempotent operations. // // See litmus test above for deciding between FailedPrecondition, // Aborted, and Unavailable. ResultCode_Unavailable ResultCode = 14 // DataLoss indicates unrecoverable data loss or corruption. ResultCode_DataLoss ResultCode = 15 // Unauthenticated indicates the request does not have valid // authentication credentials for the operation. ResultCode_Unauthenticated ResultCode = 16 )
func (ResultCode) Descriptor ¶
func (ResultCode) Descriptor() protoreflect.EnumDescriptor
func (ResultCode) Enum ¶
func (x ResultCode) Enum() *ResultCode
func (ResultCode) EnumDescriptor
deprecated
func (ResultCode) EnumDescriptor() ([]byte, []int)
Deprecated: Use ResultCode.Descriptor instead.
func (ResultCode) Number ¶
func (x ResultCode) Number() protoreflect.EnumNumber
func (ResultCode) String ¶
func (x ResultCode) String() string
func (ResultCode) Type ¶
func (ResultCode) Type() protoreflect.EnumType
type SnapshotProto ¶
type SnapshotProto struct { // Array of all jobs currently in the system Jobs []*JobProto `protobuf:"bytes,1,rep,name=jobs,proto3" json:"jobs,omitempty"` // Arrayy of all client reservation entries in the system Reservations []*ClientResvEntryProto `protobuf:"bytes,2,rep,name=reservations,proto3" json:"reservations,omitempty"` // contains filtered or unexported fields }
Encapsulates a snap of the entire system
func (*SnapshotProto) Descriptor
deprecated
func (*SnapshotProto) Descriptor() ([]byte, []int)
Deprecated: Use SnapshotProto.ProtoReflect.Descriptor instead.
func (*SnapshotProto) GetJobs ¶
func (x *SnapshotProto) GetJobs() []*JobProto
func (*SnapshotProto) GetReservations ¶
func (x *SnapshotProto) GetReservations() []*ClientResvEntryProto
func (*SnapshotProto) ProtoMessage ¶
func (*SnapshotProto) ProtoMessage()
func (*SnapshotProto) ProtoReflect ¶
func (x *SnapshotProto) ProtoReflect() protoreflect.Message
func (*SnapshotProto) Reset ¶
func (x *SnapshotProto) Reset()
func (*SnapshotProto) String ¶
func (x *SnapshotProto) String() string
type TickResponse ¶
type TickResponse struct { // Reservations grouped by proxy id ProxyReservations map[string]*Reservations `` /* 200-byte string literal not displayed */ // contains filtered or unexported fields }
func (*TickResponse) Descriptor
deprecated
func (*TickResponse) Descriptor() ([]byte, []int)
Deprecated: Use TickResponse.ProtoReflect.Descriptor instead.
func (*TickResponse) GetProxyReservations ¶
func (x *TickResponse) GetProxyReservations() map[string]*Reservations
func (*TickResponse) ProtoMessage ¶
func (*TickResponse) ProtoMessage()
func (*TickResponse) ProtoReflect ¶
func (x *TickResponse) ProtoReflect() protoreflect.Message
func (*TickResponse) Reset ¶
func (x *TickResponse) Reset()
func (*TickResponse) String ¶
func (x *TickResponse) String() string
type TouchRequest ¶
type TouchRequest struct { // The job identifier of the job to be touched JobId int64 `protobuf:"varint,1,opt,name=job_id,json=jobId,proto3" json:"job_id,omitempty"` // The identifier of the client asking for the release ClientId string `protobuf:"bytes,2,opt,name=client_id,json=clientId,proto3" json:"client_id,omitempty"` // proxy_id is the id of the proxy server that // forwarded this request ProxyId string `protobuf:"bytes,3,opt,name=proxy_id,json=proxyId,proto3" json:"proxy_id,omitempty"` // contains filtered or unexported fields }
func (*TouchRequest) Descriptor
deprecated
func (*TouchRequest) Descriptor() ([]byte, []int)
Deprecated: Use TouchRequest.ProtoReflect.Descriptor instead.
func (*TouchRequest) GetClientId ¶
func (x *TouchRequest) GetClientId() string
func (*TouchRequest) GetJobId ¶
func (x *TouchRequest) GetJobId() int64
func (*TouchRequest) GetProxyId ¶
func (x *TouchRequest) GetProxyId() string
func (*TouchRequest) ProtoMessage ¶
func (*TouchRequest) ProtoMessage()
func (*TouchRequest) ProtoReflect ¶
func (x *TouchRequest) ProtoReflect() protoreflect.Message
func (*TouchRequest) Reset ¶
func (x *TouchRequest) Reset()
func (*TouchRequest) String ¶
func (x *TouchRequest) String() string
type UnimplementedClusterServer ¶
type UnimplementedClusterServer struct { }
UnimplementedClusterServer can be embedded to have forward compatible implementations.
func (*UnimplementedClusterServer) IsNodeLeader ¶
func (*UnimplementedClusterServer) IsNodeLeader(context.Context, *Empty) (*IsNodeLeaderResponse, error)
func (*UnimplementedClusterServer) Join ¶
func (*UnimplementedClusterServer) Join(context.Context, *JoinRequest) (*Empty, error)
func (*UnimplementedClusterServer) Leave ¶
func (*UnimplementedClusterServer) Leave(context.Context, *LeaveRequest) (*Empty, error)
type UnimplementedJobStateMachineServer ¶
type UnimplementedJobStateMachineServer struct { }
UnimplementedJobStateMachineServer can be embedded to have forward compatible implementations.
func (*UnimplementedJobStateMachineServer) Bury ¶
func (*UnimplementedJobStateMachineServer) Bury(context.Context, *BuryRequest) (*Empty, error)
func (*UnimplementedJobStateMachineServer) CheckClientState ¶
func (*UnimplementedJobStateMachineServer) CheckClientState(context.Context, *CheckClientStateRequest) (*CheckClientStateResponse, error)
func (*UnimplementedJobStateMachineServer) Delete ¶
func (*UnimplementedJobStateMachineServer) Delete(context.Context, *DeleteRequest) (*Empty, error)
func (*UnimplementedJobStateMachineServer) GetJob ¶
func (*UnimplementedJobStateMachineServer) GetJob(context.Context, *GetJobRequest) (*GetJobResponse, error)
func (*UnimplementedJobStateMachineServer) GetStatsJobYaml ¶
func (*UnimplementedJobStateMachineServer) GetStatsJobYaml(context.Context, *GetStatsJobYamlRequest) (*GetStatsJobYamlResponse, error)
func (*UnimplementedJobStateMachineServer) GetStatsTubeYaml ¶
func (*UnimplementedJobStateMachineServer) GetStatsTubeYaml(context.Context, *GetStatsTubeYamlRequest) (*GetStatsTubeYamlResponse, error)
func (*UnimplementedJobStateMachineServer) GetStatsYaml ¶
func (*UnimplementedJobStateMachineServer) GetStatsYaml(context.Context, *Empty) (*GetStatsYamlResponse, error)
func (*UnimplementedJobStateMachineServer) Kick ¶
func (*UnimplementedJobStateMachineServer) Kick(context.Context, *KickRequest) (*Empty, error)
func (*UnimplementedJobStateMachineServer) KickN ¶
func (*UnimplementedJobStateMachineServer) KickN(context.Context, *KickNRequest) (*KickNResponse, error)
func (*UnimplementedJobStateMachineServer) ListTubes ¶
func (*UnimplementedJobStateMachineServer) ListTubes(context.Context, *Empty) (*ListTubesResponse, error)
func (*UnimplementedJobStateMachineServer) PeekBuried ¶
func (*UnimplementedJobStateMachineServer) PeekBuried(context.Context, *PeekRequest) (*PeekResponse, error)
func (*UnimplementedJobStateMachineServer) PeekDelayed ¶
func (*UnimplementedJobStateMachineServer) PeekDelayed(context.Context, *PeekRequest) (*PeekResponse, error)
func (*UnimplementedJobStateMachineServer) PeekReady ¶
func (*UnimplementedJobStateMachineServer) PeekReady(context.Context, *PeekRequest) (*PeekResponse, error)
func (*UnimplementedJobStateMachineServer) Put ¶
func (*UnimplementedJobStateMachineServer) Put(context.Context, *PutRequest) (*PutResponse, error)
func (*UnimplementedJobStateMachineServer) Release ¶
func (*UnimplementedJobStateMachineServer) Release(context.Context, *ReleaseRequest) (*Empty, error)
func (*UnimplementedJobStateMachineServer) Reserve ¶
func (*UnimplementedJobStateMachineServer) Reserve(context.Context, *ReserveRequest) (*ReserveResponse, error)
func (*UnimplementedJobStateMachineServer) StreamReserveUpdates ¶
func (*UnimplementedJobStateMachineServer) StreamReserveUpdates(*ReserveUpdateRequest, JobStateMachine_StreamReserveUpdatesServer) error
func (*UnimplementedJobStateMachineServer) Touch ¶
func (*UnimplementedJobStateMachineServer) Touch(context.Context, *TouchRequest) (*Empty, error)