blob: e54a10ef14911b93f5991e39bb505a913b9981e5 [file] [log] [blame]
// Copyright 2018 The LUCI Authors. All rights reserved.
// Use of this source code is governed under the Apache License, Version 2.0
// that can be found in the LICENSE file.
// This proto file describes the external scheduler plugin API.
// Code generated by protoc-gen-go. DO NOT EDIT.
// versions:
// protoc-gen-go v1.28.1
// protoc v3.21.7
// source: go.chromium.org/luci/swarming/proto/api/plugin.proto
package apipb
import prpc "go.chromium.org/luci/grpc/prpc"
import (
context "context"
grpc "google.golang.org/grpc"
codes "google.golang.org/grpc/codes"
status "google.golang.org/grpc/status"
protoreflect "google.golang.org/protobuf/reflect/protoreflect"
protoimpl "google.golang.org/protobuf/runtime/protoimpl"
timestamppb "google.golang.org/protobuf/types/known/timestamppb"
reflect "reflect"
sync "sync"
)
const (
// Verify that this generated code is sufficiently up-to-date.
_ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion)
// Verify that runtime/protoimpl is sufficiently up-to-date.
_ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20)
)
type GetCancellationsResponse_Cancellation_Reason int32
const (
// Invalid reason, do not use.
GetCancellationsResponse_Cancellation_INVALID GetCancellationsResponse_Cancellation_Reason = 0
// Task was running on a worker, but was interrupted by another task.
// Task may be retried by swarming.
GetCancellationsResponse_Cancellation_PREEMPTED GetCancellationsResponse_Cancellation_Reason = 1
// Task had invalid or erroneous properties that make it not handleable
// by scheduler. Task should not be retried.
GetCancellationsResponse_Cancellation_ERROR GetCancellationsResponse_Cancellation_Reason = 2
)
// Enum value maps for GetCancellationsResponse_Cancellation_Reason.
var (
GetCancellationsResponse_Cancellation_Reason_name = map[int32]string{
0: "INVALID",
1: "PREEMPTED",
2: "ERROR",
}
GetCancellationsResponse_Cancellation_Reason_value = map[string]int32{
"INVALID": 0,
"PREEMPTED": 1,
"ERROR": 2,
}
)
func (x GetCancellationsResponse_Cancellation_Reason) Enum() *GetCancellationsResponse_Cancellation_Reason {
p := new(GetCancellationsResponse_Cancellation_Reason)
*p = x
return p
}
func (x GetCancellationsResponse_Cancellation_Reason) String() string {
return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x))
}
func (GetCancellationsResponse_Cancellation_Reason) Descriptor() protoreflect.EnumDescriptor {
return file_go_chromium_org_luci_swarming_proto_api_plugin_proto_enumTypes[0].Descriptor()
}
func (GetCancellationsResponse_Cancellation_Reason) Type() protoreflect.EnumType {
return &file_go_chromium_org_luci_swarming_proto_api_plugin_proto_enumTypes[0]
}
func (x GetCancellationsResponse_Cancellation_Reason) Number() protoreflect.EnumNumber {
return protoreflect.EnumNumber(x)
}
// Deprecated: Use GetCancellationsResponse_Cancellation_Reason.Descriptor instead.
func (GetCancellationsResponse_Cancellation_Reason) EnumDescriptor() ([]byte, []int) {
return file_go_chromium_org_luci_swarming_proto_api_plugin_proto_rawDescGZIP(), []int{7, 0, 0}
}
// TaskSpec describes a task request and its state, for the purposes of the
// external scheduler API.
//
// It intentionally elides aspects of a task request that are irrelevant
// to scheduling decisions, to keep this proto small for performance reasons.
//
// This message format is in its early stages, and may be subject to frequent
// or even breaking changes as the external scheduler API is rolled out.
type TaskSpec struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
// Id is the swarming task request ID.
//
// Other than being a unique string to track the lifecycle of this request,
// it is opaque to external scheduler. By convention, swarming uses a task's
// summary ID (trailing '0') here, not the run ID.
Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"`
// Tags is the list of tags applied to this task request.
Tags []string `protobuf:"bytes,2,rep,name=tags,proto3" json:"tags,omitempty"`
// Slices is the set of task slices for this spec. A TaskSpec must contain
// at least 1 slice.
Slices []*SliceSpec `protobuf:"bytes,3,rep,name=slices,proto3" json:"slices,omitempty"`
// State is the current state of this task.
State TaskState `protobuf:"varint,4,opt,name=state,proto3,enum=swarming.v1.TaskState" json:"state,omitempty"`
// BotID is the id of the bot that this task is running on. It is only
// valid if state=RUNNING.
BotId string `protobuf:"bytes,5,opt,name=bot_id,json=botId,proto3" json:"bot_id,omitempty"`
// EnqueuedTime is the time at which a task was enqueued. It is only valid
// if state=PENDING.
EnqueuedTime *timestamppb.Timestamp `protobuf:"bytes,6,opt,name=enqueued_time,json=enqueuedTime,proto3" json:"enqueued_time,omitempty"`
}
func (x *TaskSpec) Reset() {
*x = TaskSpec{}
if protoimpl.UnsafeEnabled {
mi := &file_go_chromium_org_luci_swarming_proto_api_plugin_proto_msgTypes[0]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
}
func (x *TaskSpec) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*TaskSpec) ProtoMessage() {}
func (x *TaskSpec) ProtoReflect() protoreflect.Message {
mi := &file_go_chromium_org_luci_swarming_proto_api_plugin_proto_msgTypes[0]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use TaskSpec.ProtoReflect.Descriptor instead.
func (*TaskSpec) Descriptor() ([]byte, []int) {
return file_go_chromium_org_luci_swarming_proto_api_plugin_proto_rawDescGZIP(), []int{0}
}
func (x *TaskSpec) GetId() string {
if x != nil {
return x.Id
}
return ""
}
func (x *TaskSpec) GetTags() []string {
if x != nil {
return x.Tags
}
return nil
}
func (x *TaskSpec) GetSlices() []*SliceSpec {
if x != nil {
return x.Slices
}
return nil
}
func (x *TaskSpec) GetState() TaskState {
if x != nil {
return x.State
}
return TaskState_TASK_STATE_INVALID
}
func (x *TaskSpec) GetBotId() string {
if x != nil {
return x.BotId
}
return ""
}
func (x *TaskSpec) GetEnqueuedTime() *timestamppb.Timestamp {
if x != nil {
return x.EnqueuedTime
}
return nil
}
// SliceSpec describes a task request slice, for the purposes of TaskSpec.
type SliceSpec struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
// Dimensions is set dimension strings for this slice.
Dimensions []string `protobuf:"bytes,1,rep,name=dimensions,proto3" json:"dimensions,omitempty"`
}
func (x *SliceSpec) Reset() {
*x = SliceSpec{}
if protoimpl.UnsafeEnabled {
mi := &file_go_chromium_org_luci_swarming_proto_api_plugin_proto_msgTypes[1]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
}
func (x *SliceSpec) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*SliceSpec) ProtoMessage() {}
func (x *SliceSpec) ProtoReflect() protoreflect.Message {
mi := &file_go_chromium_org_luci_swarming_proto_api_plugin_proto_msgTypes[1]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use SliceSpec.ProtoReflect.Descriptor instead.
func (*SliceSpec) Descriptor() ([]byte, []int) {
return file_go_chromium_org_luci_swarming_proto_api_plugin_proto_rawDescGZIP(), []int{1}
}
func (x *SliceSpec) GetDimensions() []string {
if x != nil {
return x.Dimensions
}
return nil
}
type IdleBot struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
// BotId is the id of the bot that is idle.
BotId string `protobuf:"bytes,1,opt,name=bot_id,json=botId,proto3" json:"bot_id,omitempty"`
// Dimensions is the dimension set of the idle bot.
Dimensions []string `protobuf:"bytes,2,rep,name=dimensions,proto3" json:"dimensions,omitempty"`
}
func (x *IdleBot) Reset() {
*x = IdleBot{}
if protoimpl.UnsafeEnabled {
mi := &file_go_chromium_org_luci_swarming_proto_api_plugin_proto_msgTypes[2]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
}
func (x *IdleBot) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*IdleBot) ProtoMessage() {}
func (x *IdleBot) ProtoReflect() protoreflect.Message {
mi := &file_go_chromium_org_luci_swarming_proto_api_plugin_proto_msgTypes[2]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use IdleBot.ProtoReflect.Descriptor instead.
func (*IdleBot) Descriptor() ([]byte, []int) {
return file_go_chromium_org_luci_swarming_proto_api_plugin_proto_rawDescGZIP(), []int{2}
}
func (x *IdleBot) GetBotId() string {
if x != nil {
return x.BotId
}
return ""
}
func (x *IdleBot) GetDimensions() []string {
if x != nil {
return x.Dimensions
}
return nil
}
type AssignTasksRequest struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
// SchedulerID is the id of the scheduler that this request should be run on.
SchedulerId string `protobuf:"bytes,1,opt,name=scheduler_id,json=schedulerId,proto3" json:"scheduler_id,omitempty"`
// IdleBots is the set of idle bots that are trying to get tasks assigned.
IdleBots []*IdleBot `protobuf:"bytes,2,rep,name=idle_bots,json=idleBots,proto3" json:"idle_bots,omitempty"`
// Time is the current time (according to swarming) at which these bots
// are attempting to have tasks assigned to them.
Time *timestamppb.Timestamp `protobuf:"bytes,3,opt,name=time,proto3" json:"time,omitempty"`
}
func (x *AssignTasksRequest) Reset() {
*x = AssignTasksRequest{}
if protoimpl.UnsafeEnabled {
mi := &file_go_chromium_org_luci_swarming_proto_api_plugin_proto_msgTypes[3]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
}
func (x *AssignTasksRequest) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*AssignTasksRequest) ProtoMessage() {}
func (x *AssignTasksRequest) ProtoReflect() protoreflect.Message {
mi := &file_go_chromium_org_luci_swarming_proto_api_plugin_proto_msgTypes[3]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use AssignTasksRequest.ProtoReflect.Descriptor instead.
func (*AssignTasksRequest) Descriptor() ([]byte, []int) {
return file_go_chromium_org_luci_swarming_proto_api_plugin_proto_rawDescGZIP(), []int{3}
}
func (x *AssignTasksRequest) GetSchedulerId() string {
if x != nil {
return x.SchedulerId
}
return ""
}
func (x *AssignTasksRequest) GetIdleBots() []*IdleBot {
if x != nil {
return x.IdleBots
}
return nil
}
func (x *AssignTasksRequest) GetTime() *timestamppb.Timestamp {
if x != nil {
return x.Time
}
return nil
}
type AssignTasksResponse struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
// Assignments is the set of (bot, task) assignments that the scheduler
// determined should be made.
Assignments []*TaskAssignment `protobuf:"bytes,1,rep,name=assignments,proto3" json:"assignments,omitempty"`
}
func (x *AssignTasksResponse) Reset() {
*x = AssignTasksResponse{}
if protoimpl.UnsafeEnabled {
mi := &file_go_chromium_org_luci_swarming_proto_api_plugin_proto_msgTypes[4]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
}
func (x *AssignTasksResponse) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*AssignTasksResponse) ProtoMessage() {}
func (x *AssignTasksResponse) ProtoReflect() protoreflect.Message {
mi := &file_go_chromium_org_luci_swarming_proto_api_plugin_proto_msgTypes[4]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use AssignTasksResponse.ProtoReflect.Descriptor instead.
func (*AssignTasksResponse) Descriptor() ([]byte, []int) {
return file_go_chromium_org_luci_swarming_proto_api_plugin_proto_rawDescGZIP(), []int{4}
}
func (x *AssignTasksResponse) GetAssignments() []*TaskAssignment {
if x != nil {
return x.Assignments
}
return nil
}
type TaskAssignment struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
// BotID is the bot that should be assigned a task.
BotId string `protobuf:"bytes,1,opt,name=bot_id,json=botId,proto3" json:"bot_id,omitempty"`
// TaskID is the task that should be assigned to the bot.
TaskId string `protobuf:"bytes,2,opt,name=task_id,json=taskId,proto3" json:"task_id,omitempty"`
// SliceNumber is the slice within the task that should be assigned to the bot.
// If absent, slice 0 will be assumed.
SliceNumber int32 `protobuf:"varint,3,opt,name=slice_number,json=sliceNumber,proto3" json:"slice_number,omitempty"`
}
func (x *TaskAssignment) Reset() {
*x = TaskAssignment{}
if protoimpl.UnsafeEnabled {
mi := &file_go_chromium_org_luci_swarming_proto_api_plugin_proto_msgTypes[5]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
}
func (x *TaskAssignment) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*TaskAssignment) ProtoMessage() {}
func (x *TaskAssignment) ProtoReflect() protoreflect.Message {
mi := &file_go_chromium_org_luci_swarming_proto_api_plugin_proto_msgTypes[5]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use TaskAssignment.ProtoReflect.Descriptor instead.
func (*TaskAssignment) Descriptor() ([]byte, []int) {
return file_go_chromium_org_luci_swarming_proto_api_plugin_proto_rawDescGZIP(), []int{5}
}
func (x *TaskAssignment) GetBotId() string {
if x != nil {
return x.BotId
}
return ""
}
func (x *TaskAssignment) GetTaskId() string {
if x != nil {
return x.TaskId
}
return ""
}
func (x *TaskAssignment) GetSliceNumber() int32 {
if x != nil {
return x.SliceNumber
}
return 0
}
type GetCancellationsRequest struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
// SchedulerID is the id of the scheduler that this request should be run on.
SchedulerId string `protobuf:"bytes,1,opt,name=scheduler_id,json=schedulerId,proto3" json:"scheduler_id,omitempty"`
}
func (x *GetCancellationsRequest) Reset() {
*x = GetCancellationsRequest{}
if protoimpl.UnsafeEnabled {
mi := &file_go_chromium_org_luci_swarming_proto_api_plugin_proto_msgTypes[6]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
}
func (x *GetCancellationsRequest) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*GetCancellationsRequest) ProtoMessage() {}
func (x *GetCancellationsRequest) ProtoReflect() protoreflect.Message {
mi := &file_go_chromium_org_luci_swarming_proto_api_plugin_proto_msgTypes[6]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use GetCancellationsRequest.ProtoReflect.Descriptor instead.
func (*GetCancellationsRequest) Descriptor() ([]byte, []int) {
return file_go_chromium_org_luci_swarming_proto_api_plugin_proto_rawDescGZIP(), []int{6}
}
func (x *GetCancellationsRequest) GetSchedulerId() string {
if x != nil {
return x.SchedulerId
}
return ""
}
type GetCancellationsResponse struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
// Cancellations is the set of (bot, task) pairs for tasks that should be
// cancelled on bots.
Cancellations []*GetCancellationsResponse_Cancellation `protobuf:"bytes,1,rep,name=cancellations,proto3" json:"cancellations,omitempty"`
}
func (x *GetCancellationsResponse) Reset() {
*x = GetCancellationsResponse{}
if protoimpl.UnsafeEnabled {
mi := &file_go_chromium_org_luci_swarming_proto_api_plugin_proto_msgTypes[7]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
}
func (x *GetCancellationsResponse) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*GetCancellationsResponse) ProtoMessage() {}
func (x *GetCancellationsResponse) ProtoReflect() protoreflect.Message {
mi := &file_go_chromium_org_luci_swarming_proto_api_plugin_proto_msgTypes[7]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use GetCancellationsResponse.ProtoReflect.Descriptor instead.
func (*GetCancellationsResponse) Descriptor() ([]byte, []int) {
return file_go_chromium_org_luci_swarming_proto_api_plugin_proto_rawDescGZIP(), []int{7}
}
func (x *GetCancellationsResponse) GetCancellations() []*GetCancellationsResponse_Cancellation {
if x != nil {
return x.Cancellations
}
return nil
}
type NotifyTasksItem struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
// Time is the time at which the given task was in the given state.
Time *timestamppb.Timestamp `protobuf:"bytes,1,opt,name=time,proto3" json:"time,omitempty"`
// Task describes a task request and its current state.
Task *TaskSpec `protobuf:"bytes,2,opt,name=task,proto3" json:"task,omitempty"`
}
func (x *NotifyTasksItem) Reset() {
*x = NotifyTasksItem{}
if protoimpl.UnsafeEnabled {
mi := &file_go_chromium_org_luci_swarming_proto_api_plugin_proto_msgTypes[8]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
}
func (x *NotifyTasksItem) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*NotifyTasksItem) ProtoMessage() {}
func (x *NotifyTasksItem) ProtoReflect() protoreflect.Message {
mi := &file_go_chromium_org_luci_swarming_proto_api_plugin_proto_msgTypes[8]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use NotifyTasksItem.ProtoReflect.Descriptor instead.
func (*NotifyTasksItem) Descriptor() ([]byte, []int) {
return file_go_chromium_org_luci_swarming_proto_api_plugin_proto_rawDescGZIP(), []int{8}
}
func (x *NotifyTasksItem) GetTime() *timestamppb.Timestamp {
if x != nil {
return x.Time
}
return nil
}
func (x *NotifyTasksItem) GetTask() *TaskSpec {
if x != nil {
return x.Task
}
return nil
}
type NotifyTasksRequest struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
// SchedulerID is the id of the scheduler that this request should be run on.
SchedulerId string `protobuf:"bytes,1,opt,name=scheduler_id,json=schedulerId,proto3" json:"scheduler_id,omitempty"`
// Notifications is the set of task notifications to send to the scheduler.
Notifications []*NotifyTasksItem `protobuf:"bytes,2,rep,name=notifications,proto3" json:"notifications,omitempty"`
// IsCallback specifies whether these notifications are in response to
// updates that were requested by a previous GetCallbacks call.
//
// This is for diagnostic purposes only.
IsCallback bool `protobuf:"varint,3,opt,name=is_callback,json=isCallback,proto3" json:"is_callback,omitempty"`
}
func (x *NotifyTasksRequest) Reset() {
*x = NotifyTasksRequest{}
if protoimpl.UnsafeEnabled {
mi := &file_go_chromium_org_luci_swarming_proto_api_plugin_proto_msgTypes[9]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
}
func (x *NotifyTasksRequest) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*NotifyTasksRequest) ProtoMessage() {}
func (x *NotifyTasksRequest) ProtoReflect() protoreflect.Message {
mi := &file_go_chromium_org_luci_swarming_proto_api_plugin_proto_msgTypes[9]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use NotifyTasksRequest.ProtoReflect.Descriptor instead.
func (*NotifyTasksRequest) Descriptor() ([]byte, []int) {
return file_go_chromium_org_luci_swarming_proto_api_plugin_proto_rawDescGZIP(), []int{9}
}
func (x *NotifyTasksRequest) GetSchedulerId() string {
if x != nil {
return x.SchedulerId
}
return ""
}
func (x *NotifyTasksRequest) GetNotifications() []*NotifyTasksItem {
if x != nil {
return x.Notifications
}
return nil
}
func (x *NotifyTasksRequest) GetIsCallback() bool {
if x != nil {
return x.IsCallback
}
return false
}
type NotifyTasksResponse struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
}
func (x *NotifyTasksResponse) Reset() {
*x = NotifyTasksResponse{}
if protoimpl.UnsafeEnabled {
mi := &file_go_chromium_org_luci_swarming_proto_api_plugin_proto_msgTypes[10]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
}
func (x *NotifyTasksResponse) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*NotifyTasksResponse) ProtoMessage() {}
func (x *NotifyTasksResponse) ProtoReflect() protoreflect.Message {
mi := &file_go_chromium_org_luci_swarming_proto_api_plugin_proto_msgTypes[10]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use NotifyTasksResponse.ProtoReflect.Descriptor instead.
func (*NotifyTasksResponse) Descriptor() ([]byte, []int) {
return file_go_chromium_org_luci_swarming_proto_api_plugin_proto_rawDescGZIP(), []int{10}
}
type GetCallbacksRequest struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
// SchedulerID is the id of the scheduler that this request should be run on.
SchedulerId string `protobuf:"bytes,1,opt,name=scheduler_id,json=schedulerId,proto3" json:"scheduler_id,omitempty"`
}
func (x *GetCallbacksRequest) Reset() {
*x = GetCallbacksRequest{}
if protoimpl.UnsafeEnabled {
mi := &file_go_chromium_org_luci_swarming_proto_api_plugin_proto_msgTypes[11]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
}
func (x *GetCallbacksRequest) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*GetCallbacksRequest) ProtoMessage() {}
func (x *GetCallbacksRequest) ProtoReflect() protoreflect.Message {
mi := &file_go_chromium_org_luci_swarming_proto_api_plugin_proto_msgTypes[11]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use GetCallbacksRequest.ProtoReflect.Descriptor instead.
func (*GetCallbacksRequest) Descriptor() ([]byte, []int) {
return file_go_chromium_org_luci_swarming_proto_api_plugin_proto_rawDescGZIP(), []int{11}
}
func (x *GetCallbacksRequest) GetSchedulerId() string {
if x != nil {
return x.SchedulerId
}
return ""
}
type GetCallbacksResponse struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
// TaskIds is the list of tasks that the external scheduler would like
// callback notifications about.
TaskIds []string `protobuf:"bytes,1,rep,name=task_ids,json=taskIds,proto3" json:"task_ids,omitempty"`
}
func (x *GetCallbacksResponse) Reset() {
*x = GetCallbacksResponse{}
if protoimpl.UnsafeEnabled {
mi := &file_go_chromium_org_luci_swarming_proto_api_plugin_proto_msgTypes[12]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
}
func (x *GetCallbacksResponse) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*GetCallbacksResponse) ProtoMessage() {}
func (x *GetCallbacksResponse) ProtoReflect() protoreflect.Message {
mi := &file_go_chromium_org_luci_swarming_proto_api_plugin_proto_msgTypes[12]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use GetCallbacksResponse.ProtoReflect.Descriptor instead.
func (*GetCallbacksResponse) Descriptor() ([]byte, []int) {
return file_go_chromium_org_luci_swarming_proto_api_plugin_proto_rawDescGZIP(), []int{12}
}
func (x *GetCallbacksResponse) GetTaskIds() []string {
if x != nil {
return x.TaskIds
}
return nil
}
type GetCancellationsResponse_Cancellation struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
// BotID is the bot that a task should be cancelled on.
BotId string `protobuf:"bytes,1,opt,name=bot_id,json=botId,proto3" json:"bot_id,omitempty"`
// TaskID is the task that should be cancelled on the bot.
TaskId string `protobuf:"bytes,2,opt,name=task_id,json=taskId,proto3" json:"task_id,omitempty"`
// Reason is the reason the task was cancelled.
Reason GetCancellationsResponse_Cancellation_Reason `protobuf:"varint,3,opt,name=reason,proto3,enum=swarming.v1.GetCancellationsResponse_Cancellation_Reason" json:"reason,omitempty"`
// ExtraInfo is optional, human readable extra information about why the
// task was cancelled.
ExtraInfo string `protobuf:"bytes,4,opt,name=extra_info,json=extraInfo,proto3" json:"extra_info,omitempty"`
}
func (x *GetCancellationsResponse_Cancellation) Reset() {
*x = GetCancellationsResponse_Cancellation{}
if protoimpl.UnsafeEnabled {
mi := &file_go_chromium_org_luci_swarming_proto_api_plugin_proto_msgTypes[13]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
}
func (x *GetCancellationsResponse_Cancellation) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*GetCancellationsResponse_Cancellation) ProtoMessage() {}
func (x *GetCancellationsResponse_Cancellation) ProtoReflect() protoreflect.Message {
mi := &file_go_chromium_org_luci_swarming_proto_api_plugin_proto_msgTypes[13]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use GetCancellationsResponse_Cancellation.ProtoReflect.Descriptor instead.
func (*GetCancellationsResponse_Cancellation) Descriptor() ([]byte, []int) {
return file_go_chromium_org_luci_swarming_proto_api_plugin_proto_rawDescGZIP(), []int{7, 0}
}
func (x *GetCancellationsResponse_Cancellation) GetBotId() string {
if x != nil {
return x.BotId
}
return ""
}
func (x *GetCancellationsResponse_Cancellation) GetTaskId() string {
if x != nil {
return x.TaskId
}
return ""
}
func (x *GetCancellationsResponse_Cancellation) GetReason() GetCancellationsResponse_Cancellation_Reason {
if x != nil {
return x.Reason
}
return GetCancellationsResponse_Cancellation_INVALID
}
func (x *GetCancellationsResponse_Cancellation) GetExtraInfo() string {
if x != nil {
return x.ExtraInfo
}
return ""
}
var File_go_chromium_org_luci_swarming_proto_api_plugin_proto protoreflect.FileDescriptor
var file_go_chromium_org_luci_swarming_proto_api_plugin_proto_rawDesc = []byte{
0x0a, 0x34, 0x67, 0x6f, 0x2e, 0x63, 0x68, 0x72, 0x6f, 0x6d, 0x69, 0x75, 0x6d, 0x2e, 0x6f, 0x72,
0x67, 0x2f, 0x6c, 0x75, 0x63, 0x69, 0x2f, 0x73, 0x77, 0x61, 0x72, 0x6d, 0x69, 0x6e, 0x67, 0x2f,
0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x70, 0x6c, 0x75, 0x67, 0x69, 0x6e,
0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x0b, 0x73, 0x77, 0x61, 0x72, 0x6d, 0x69, 0x6e, 0x67,
0x2e, 0x76, 0x31, 0x1a, 0x1f, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x70, 0x72, 0x6f, 0x74,
0x6f, 0x62, 0x75, 0x66, 0x2f, 0x74, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x2e, 0x70,
0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x36, 0x67, 0x6f, 0x2e, 0x63, 0x68, 0x72, 0x6f, 0x6d, 0x69, 0x75,
0x6d, 0x2e, 0x6f, 0x72, 0x67, 0x2f, 0x6c, 0x75, 0x63, 0x69, 0x2f, 0x73, 0x77, 0x61, 0x72, 0x6d,
0x69, 0x6e, 0x67, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x73, 0x77,
0x61, 0x72, 0x6d, 0x69, 0x6e, 0x67, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0xe4, 0x01, 0x0a,
0x08, 0x54, 0x61, 0x73, 0x6b, 0x53, 0x70, 0x65, 0x63, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18,
0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x12, 0x12, 0x0a, 0x04, 0x74, 0x61, 0x67,
0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x09, 0x52, 0x04, 0x74, 0x61, 0x67, 0x73, 0x12, 0x2e, 0x0a,
0x06, 0x73, 0x6c, 0x69, 0x63, 0x65, 0x73, 0x18, 0x03, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x16, 0x2e,
0x73, 0x77, 0x61, 0x72, 0x6d, 0x69, 0x6e, 0x67, 0x2e, 0x76, 0x31, 0x2e, 0x53, 0x6c, 0x69, 0x63,
0x65, 0x53, 0x70, 0x65, 0x63, 0x52, 0x06, 0x73, 0x6c, 0x69, 0x63, 0x65, 0x73, 0x12, 0x2c, 0x0a,
0x05, 0x73, 0x74, 0x61, 0x74, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x16, 0x2e, 0x73,
0x77, 0x61, 0x72, 0x6d, 0x69, 0x6e, 0x67, 0x2e, 0x76, 0x31, 0x2e, 0x54, 0x61, 0x73, 0x6b, 0x53,
0x74, 0x61, 0x74, 0x65, 0x52, 0x05, 0x73, 0x74, 0x61, 0x74, 0x65, 0x12, 0x15, 0x0a, 0x06, 0x62,
0x6f, 0x74, 0x5f, 0x69, 0x64, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x62, 0x6f, 0x74,
0x49, 0x64, 0x12, 0x3f, 0x0a, 0x0d, 0x65, 0x6e, 0x71, 0x75, 0x65, 0x75, 0x65, 0x64, 0x5f, 0x74,
0x69, 0x6d, 0x65, 0x18, 0x06, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x67, 0x6f, 0x6f, 0x67,
0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x54, 0x69, 0x6d, 0x65,
0x73, 0x74, 0x61, 0x6d, 0x70, 0x52, 0x0c, 0x65, 0x6e, 0x71, 0x75, 0x65, 0x75, 0x65, 0x64, 0x54,
0x69, 0x6d, 0x65, 0x22, 0x2b, 0x0a, 0x09, 0x53, 0x6c, 0x69, 0x63, 0x65, 0x53, 0x70, 0x65, 0x63,
0x12, 0x1e, 0x0a, 0x0a, 0x64, 0x69, 0x6d, 0x65, 0x6e, 0x73, 0x69, 0x6f, 0x6e, 0x73, 0x18, 0x01,
0x20, 0x03, 0x28, 0x09, 0x52, 0x0a, 0x64, 0x69, 0x6d, 0x65, 0x6e, 0x73, 0x69, 0x6f, 0x6e, 0x73,
0x22, 0x40, 0x0a, 0x07, 0x49, 0x64, 0x6c, 0x65, 0x42, 0x6f, 0x74, 0x12, 0x15, 0x0a, 0x06, 0x62,
0x6f, 0x74, 0x5f, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x62, 0x6f, 0x74,
0x49, 0x64, 0x12, 0x1e, 0x0a, 0x0a, 0x64, 0x69, 0x6d, 0x65, 0x6e, 0x73, 0x69, 0x6f, 0x6e, 0x73,
0x18, 0x02, 0x20, 0x03, 0x28, 0x09, 0x52, 0x0a, 0x64, 0x69, 0x6d, 0x65, 0x6e, 0x73, 0x69, 0x6f,
0x6e, 0x73, 0x22, 0x9a, 0x01, 0x0a, 0x12, 0x41, 0x73, 0x73, 0x69, 0x67, 0x6e, 0x54, 0x61, 0x73,
0x6b, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x21, 0x0a, 0x0c, 0x73, 0x63, 0x68,
0x65, 0x64, 0x75, 0x6c, 0x65, 0x72, 0x5f, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52,
0x0b, 0x73, 0x63, 0x68, 0x65, 0x64, 0x75, 0x6c, 0x65, 0x72, 0x49, 0x64, 0x12, 0x31, 0x0a, 0x09,
0x69, 0x64, 0x6c, 0x65, 0x5f, 0x62, 0x6f, 0x74, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32,
0x14, 0x2e, 0x73, 0x77, 0x61, 0x72, 0x6d, 0x69, 0x6e, 0x67, 0x2e, 0x76, 0x31, 0x2e, 0x49, 0x64,
0x6c, 0x65, 0x42, 0x6f, 0x74, 0x52, 0x08, 0x69, 0x64, 0x6c, 0x65, 0x42, 0x6f, 0x74, 0x73, 0x12,
0x2e, 0x0a, 0x04, 0x74, 0x69, 0x6d, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1a, 0x2e,
0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e,
0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x52, 0x04, 0x74, 0x69, 0x6d, 0x65, 0x22,
0x54, 0x0a, 0x13, 0x41, 0x73, 0x73, 0x69, 0x67, 0x6e, 0x54, 0x61, 0x73, 0x6b, 0x73, 0x52, 0x65,
0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x3d, 0x0a, 0x0b, 0x61, 0x73, 0x73, 0x69, 0x67, 0x6e,
0x6d, 0x65, 0x6e, 0x74, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x73, 0x77,
0x61, 0x72, 0x6d, 0x69, 0x6e, 0x67, 0x2e, 0x76, 0x31, 0x2e, 0x54, 0x61, 0x73, 0x6b, 0x41, 0x73,
0x73, 0x69, 0x67, 0x6e, 0x6d, 0x65, 0x6e, 0x74, 0x52, 0x0b, 0x61, 0x73, 0x73, 0x69, 0x67, 0x6e,
0x6d, 0x65, 0x6e, 0x74, 0x73, 0x22, 0x63, 0x0a, 0x0e, 0x54, 0x61, 0x73, 0x6b, 0x41, 0x73, 0x73,
0x69, 0x67, 0x6e, 0x6d, 0x65, 0x6e, 0x74, 0x12, 0x15, 0x0a, 0x06, 0x62, 0x6f, 0x74, 0x5f, 0x69,
0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x62, 0x6f, 0x74, 0x49, 0x64, 0x12, 0x17,
0x0a, 0x07, 0x74, 0x61, 0x73, 0x6b, 0x5f, 0x69, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52,
0x06, 0x74, 0x61, 0x73, 0x6b, 0x49, 0x64, 0x12, 0x21, 0x0a, 0x0c, 0x73, 0x6c, 0x69, 0x63, 0x65,
0x5f, 0x6e, 0x75, 0x6d, 0x62, 0x65, 0x72, 0x18, 0x03, 0x20, 0x01, 0x28, 0x05, 0x52, 0x0b, 0x73,
0x6c, 0x69, 0x63, 0x65, 0x4e, 0x75, 0x6d, 0x62, 0x65, 0x72, 0x22, 0x3c, 0x0a, 0x17, 0x47, 0x65,
0x74, 0x43, 0x61, 0x6e, 0x63, 0x65, 0x6c, 0x6c, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x52, 0x65,
0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x21, 0x0a, 0x0c, 0x73, 0x63, 0x68, 0x65, 0x64, 0x75, 0x6c,
0x65, 0x72, 0x5f, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x73, 0x63, 0x68,
0x65, 0x64, 0x75, 0x6c, 0x65, 0x72, 0x49, 0x64, 0x22, 0xd8, 0x02, 0x0a, 0x18, 0x47, 0x65, 0x74,
0x43, 0x61, 0x6e, 0x63, 0x65, 0x6c, 0x6c, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x52, 0x65, 0x73,
0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x58, 0x0a, 0x0d, 0x63, 0x61, 0x6e, 0x63, 0x65, 0x6c, 0x6c,
0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x32, 0x2e, 0x73,
0x77, 0x61, 0x72, 0x6d, 0x69, 0x6e, 0x67, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x43, 0x61,
0x6e, 0x63, 0x65, 0x6c, 0x6c, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f,
0x6e, 0x73, 0x65, 0x2e, 0x43, 0x61, 0x6e, 0x63, 0x65, 0x6c, 0x6c, 0x61, 0x74, 0x69, 0x6f, 0x6e,
0x52, 0x0d, 0x63, 0x61, 0x6e, 0x63, 0x65, 0x6c, 0x6c, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x1a,
0xe1, 0x01, 0x0a, 0x0c, 0x43, 0x61, 0x6e, 0x63, 0x65, 0x6c, 0x6c, 0x61, 0x74, 0x69, 0x6f, 0x6e,
0x12, 0x15, 0x0a, 0x06, 0x62, 0x6f, 0x74, 0x5f, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09,
0x52, 0x05, 0x62, 0x6f, 0x74, 0x49, 0x64, 0x12, 0x17, 0x0a, 0x07, 0x74, 0x61, 0x73, 0x6b, 0x5f,
0x69, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x74, 0x61, 0x73, 0x6b, 0x49, 0x64,
0x12, 0x51, 0x0a, 0x06, 0x72, 0x65, 0x61, 0x73, 0x6f, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0e,
0x32, 0x39, 0x2e, 0x73, 0x77, 0x61, 0x72, 0x6d, 0x69, 0x6e, 0x67, 0x2e, 0x76, 0x31, 0x2e, 0x47,
0x65, 0x74, 0x43, 0x61, 0x6e, 0x63, 0x65, 0x6c, 0x6c, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x52,
0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x2e, 0x43, 0x61, 0x6e, 0x63, 0x65, 0x6c, 0x6c, 0x61,
0x74, 0x69, 0x6f, 0x6e, 0x2e, 0x52, 0x65, 0x61, 0x73, 0x6f, 0x6e, 0x52, 0x06, 0x72, 0x65, 0x61,
0x73, 0x6f, 0x6e, 0x12, 0x1d, 0x0a, 0x0a, 0x65, 0x78, 0x74, 0x72, 0x61, 0x5f, 0x69, 0x6e, 0x66,
0x6f, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x65, 0x78, 0x74, 0x72, 0x61, 0x49, 0x6e,
0x66, 0x6f, 0x22, 0x2f, 0x0a, 0x06, 0x52, 0x65, 0x61, 0x73, 0x6f, 0x6e, 0x12, 0x0b, 0x0a, 0x07,
0x49, 0x4e, 0x56, 0x41, 0x4c, 0x49, 0x44, 0x10, 0x00, 0x12, 0x0d, 0x0a, 0x09, 0x50, 0x52, 0x45,
0x45, 0x4d, 0x50, 0x54, 0x45, 0x44, 0x10, 0x01, 0x12, 0x09, 0x0a, 0x05, 0x45, 0x52, 0x52, 0x4f,
0x52, 0x10, 0x02, 0x22, 0x6c, 0x0a, 0x0f, 0x4e, 0x6f, 0x74, 0x69, 0x66, 0x79, 0x54, 0x61, 0x73,
0x6b, 0x73, 0x49, 0x74, 0x65, 0x6d, 0x12, 0x2e, 0x0a, 0x04, 0x74, 0x69, 0x6d, 0x65, 0x18, 0x01,
0x20, 0x01, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72,
0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70,
0x52, 0x04, 0x74, 0x69, 0x6d, 0x65, 0x12, 0x29, 0x0a, 0x04, 0x74, 0x61, 0x73, 0x6b, 0x18, 0x02,
0x20, 0x01, 0x28, 0x0b, 0x32, 0x15, 0x2e, 0x73, 0x77, 0x61, 0x72, 0x6d, 0x69, 0x6e, 0x67, 0x2e,
0x76, 0x31, 0x2e, 0x54, 0x61, 0x73, 0x6b, 0x53, 0x70, 0x65, 0x63, 0x52, 0x04, 0x74, 0x61, 0x73,
0x6b, 0x22, 0x9c, 0x01, 0x0a, 0x12, 0x4e, 0x6f, 0x74, 0x69, 0x66, 0x79, 0x54, 0x61, 0x73, 0x6b,
0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x21, 0x0a, 0x0c, 0x73, 0x63, 0x68, 0x65,
0x64, 0x75, 0x6c, 0x65, 0x72, 0x5f, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b,
0x73, 0x63, 0x68, 0x65, 0x64, 0x75, 0x6c, 0x65, 0x72, 0x49, 0x64, 0x12, 0x42, 0x0a, 0x0d, 0x6e,
0x6f, 0x74, 0x69, 0x66, 0x69, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x18, 0x02, 0x20, 0x03,
0x28, 0x0b, 0x32, 0x1c, 0x2e, 0x73, 0x77, 0x61, 0x72, 0x6d, 0x69, 0x6e, 0x67, 0x2e, 0x76, 0x31,
0x2e, 0x4e, 0x6f, 0x74, 0x69, 0x66, 0x79, 0x54, 0x61, 0x73, 0x6b, 0x73, 0x49, 0x74, 0x65, 0x6d,
0x52, 0x0d, 0x6e, 0x6f, 0x74, 0x69, 0x66, 0x69, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x12,
0x1f, 0x0a, 0x0b, 0x69, 0x73, 0x5f, 0x63, 0x61, 0x6c, 0x6c, 0x62, 0x61, 0x63, 0x6b, 0x18, 0x03,
0x20, 0x01, 0x28, 0x08, 0x52, 0x0a, 0x69, 0x73, 0x43, 0x61, 0x6c, 0x6c, 0x62, 0x61, 0x63, 0x6b,
0x22, 0x15, 0x0a, 0x13, 0x4e, 0x6f, 0x74, 0x69, 0x66, 0x79, 0x54, 0x61, 0x73, 0x6b, 0x73, 0x52,
0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x38, 0x0a, 0x13, 0x47, 0x65, 0x74, 0x43, 0x61,
0x6c, 0x6c, 0x62, 0x61, 0x63, 0x6b, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x21,
0x0a, 0x0c, 0x73, 0x63, 0x68, 0x65, 0x64, 0x75, 0x6c, 0x65, 0x72, 0x5f, 0x69, 0x64, 0x18, 0x01,
0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x73, 0x63, 0x68, 0x65, 0x64, 0x75, 0x6c, 0x65, 0x72, 0x49,
0x64, 0x22, 0x31, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x43, 0x61, 0x6c, 0x6c, 0x62, 0x61, 0x63, 0x6b,
0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x19, 0x0a, 0x08, 0x74, 0x61, 0x73,
0x6b, 0x5f, 0x69, 0x64, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x09, 0x52, 0x07, 0x74, 0x61, 0x73,
0x6b, 0x49, 0x64, 0x73, 0x32, 0xed, 0x02, 0x0a, 0x11, 0x45, 0x78, 0x74, 0x65, 0x72, 0x6e, 0x61,
0x6c, 0x53, 0x63, 0x68, 0x65, 0x64, 0x75, 0x6c, 0x65, 0x72, 0x12, 0x50, 0x0a, 0x0b, 0x41, 0x73,
0x73, 0x69, 0x67, 0x6e, 0x54, 0x61, 0x73, 0x6b, 0x73, 0x12, 0x1f, 0x2e, 0x73, 0x77, 0x61, 0x72,
0x6d, 0x69, 0x6e, 0x67, 0x2e, 0x76, 0x31, 0x2e, 0x41, 0x73, 0x73, 0x69, 0x67, 0x6e, 0x54, 0x61,
0x73, 0x6b, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x20, 0x2e, 0x73, 0x77, 0x61,
0x72, 0x6d, 0x69, 0x6e, 0x67, 0x2e, 0x76, 0x31, 0x2e, 0x41, 0x73, 0x73, 0x69, 0x67, 0x6e, 0x54,
0x61, 0x73, 0x6b, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x5f, 0x0a, 0x10,
0x47, 0x65, 0x74, 0x43, 0x61, 0x6e, 0x63, 0x65, 0x6c, 0x6c, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73,
0x12, 0x24, 0x2e, 0x73, 0x77, 0x61, 0x72, 0x6d, 0x69, 0x6e, 0x67, 0x2e, 0x76, 0x31, 0x2e, 0x47,
0x65, 0x74, 0x43, 0x61, 0x6e, 0x63, 0x65, 0x6c, 0x6c, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x52,
0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x25, 0x2e, 0x73, 0x77, 0x61, 0x72, 0x6d, 0x69, 0x6e,
0x67, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x43, 0x61, 0x6e, 0x63, 0x65, 0x6c, 0x6c, 0x61,
0x74, 0x69, 0x6f, 0x6e, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x50, 0x0a,
0x0b, 0x4e, 0x6f, 0x74, 0x69, 0x66, 0x79, 0x54, 0x61, 0x73, 0x6b, 0x73, 0x12, 0x1f, 0x2e, 0x73,
0x77, 0x61, 0x72, 0x6d, 0x69, 0x6e, 0x67, 0x2e, 0x76, 0x31, 0x2e, 0x4e, 0x6f, 0x74, 0x69, 0x66,
0x79, 0x54, 0x61, 0x73, 0x6b, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x20, 0x2e,
0x73, 0x77, 0x61, 0x72, 0x6d, 0x69, 0x6e, 0x67, 0x2e, 0x76, 0x31, 0x2e, 0x4e, 0x6f, 0x74, 0x69,
0x66, 0x79, 0x54, 0x61, 0x73, 0x6b, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12,
0x53, 0x0a, 0x0c, 0x47, 0x65, 0x74, 0x43, 0x61, 0x6c, 0x6c, 0x62, 0x61, 0x63, 0x6b, 0x73, 0x12,
0x20, 0x2e, 0x73, 0x77, 0x61, 0x72, 0x6d, 0x69, 0x6e, 0x67, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65,
0x74, 0x43, 0x61, 0x6c, 0x6c, 0x62, 0x61, 0x63, 0x6b, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73,
0x74, 0x1a, 0x21, 0x2e, 0x73, 0x77, 0x61, 0x72, 0x6d, 0x69, 0x6e, 0x67, 0x2e, 0x76, 0x31, 0x2e,
0x47, 0x65, 0x74, 0x43, 0x61, 0x6c, 0x6c, 0x62, 0x61, 0x63, 0x6b, 0x73, 0x52, 0x65, 0x73, 0x70,
0x6f, 0x6e, 0x73, 0x65, 0x42, 0x2f, 0x5a, 0x2d, 0x67, 0x6f, 0x2e, 0x63, 0x68, 0x72, 0x6f, 0x6d,
0x69, 0x75, 0x6d, 0x2e, 0x6f, 0x72, 0x67, 0x2f, 0x6c, 0x75, 0x63, 0x69, 0x2f, 0x73, 0x77, 0x61,
0x72, 0x6d, 0x69, 0x6e, 0x67, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x61, 0x70, 0x69, 0x3b,
0x61, 0x70, 0x69, 0x70, 0x62, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
}
var (
file_go_chromium_org_luci_swarming_proto_api_plugin_proto_rawDescOnce sync.Once
file_go_chromium_org_luci_swarming_proto_api_plugin_proto_rawDescData = file_go_chromium_org_luci_swarming_proto_api_plugin_proto_rawDesc
)
func file_go_chromium_org_luci_swarming_proto_api_plugin_proto_rawDescGZIP() []byte {
file_go_chromium_org_luci_swarming_proto_api_plugin_proto_rawDescOnce.Do(func() {
file_go_chromium_org_luci_swarming_proto_api_plugin_proto_rawDescData = protoimpl.X.CompressGZIP(file_go_chromium_org_luci_swarming_proto_api_plugin_proto_rawDescData)
})
return file_go_chromium_org_luci_swarming_proto_api_plugin_proto_rawDescData
}
var file_go_chromium_org_luci_swarming_proto_api_plugin_proto_enumTypes = make([]protoimpl.EnumInfo, 1)
var file_go_chromium_org_luci_swarming_proto_api_plugin_proto_msgTypes = make([]protoimpl.MessageInfo, 14)
var file_go_chromium_org_luci_swarming_proto_api_plugin_proto_goTypes = []interface{}{
(GetCancellationsResponse_Cancellation_Reason)(0), // 0: swarming.v1.GetCancellationsResponse.Cancellation.Reason
(*TaskSpec)(nil), // 1: swarming.v1.TaskSpec
(*SliceSpec)(nil), // 2: swarming.v1.SliceSpec
(*IdleBot)(nil), // 3: swarming.v1.IdleBot
(*AssignTasksRequest)(nil), // 4: swarming.v1.AssignTasksRequest
(*AssignTasksResponse)(nil), // 5: swarming.v1.AssignTasksResponse
(*TaskAssignment)(nil), // 6: swarming.v1.TaskAssignment
(*GetCancellationsRequest)(nil), // 7: swarming.v1.GetCancellationsRequest
(*GetCancellationsResponse)(nil), // 8: swarming.v1.GetCancellationsResponse
(*NotifyTasksItem)(nil), // 9: swarming.v1.NotifyTasksItem
(*NotifyTasksRequest)(nil), // 10: swarming.v1.NotifyTasksRequest
(*NotifyTasksResponse)(nil), // 11: swarming.v1.NotifyTasksResponse
(*GetCallbacksRequest)(nil), // 12: swarming.v1.GetCallbacksRequest
(*GetCallbacksResponse)(nil), // 13: swarming.v1.GetCallbacksResponse
(*GetCancellationsResponse_Cancellation)(nil), // 14: swarming.v1.GetCancellationsResponse.Cancellation
(TaskState)(0), // 15: swarming.v1.TaskState
(*timestamppb.Timestamp)(nil), // 16: google.protobuf.Timestamp
}
var file_go_chromium_org_luci_swarming_proto_api_plugin_proto_depIdxs = []int32{
2, // 0: swarming.v1.TaskSpec.slices:type_name -> swarming.v1.SliceSpec
15, // 1: swarming.v1.TaskSpec.state:type_name -> swarming.v1.TaskState
16, // 2: swarming.v1.TaskSpec.enqueued_time:type_name -> google.protobuf.Timestamp
3, // 3: swarming.v1.AssignTasksRequest.idle_bots:type_name -> swarming.v1.IdleBot
16, // 4: swarming.v1.AssignTasksRequest.time:type_name -> google.protobuf.Timestamp
6, // 5: swarming.v1.AssignTasksResponse.assignments:type_name -> swarming.v1.TaskAssignment
14, // 6: swarming.v1.GetCancellationsResponse.cancellations:type_name -> swarming.v1.GetCancellationsResponse.Cancellation
16, // 7: swarming.v1.NotifyTasksItem.time:type_name -> google.protobuf.Timestamp
1, // 8: swarming.v1.NotifyTasksItem.task:type_name -> swarming.v1.TaskSpec
9, // 9: swarming.v1.NotifyTasksRequest.notifications:type_name -> swarming.v1.NotifyTasksItem
0, // 10: swarming.v1.GetCancellationsResponse.Cancellation.reason:type_name -> swarming.v1.GetCancellationsResponse.Cancellation.Reason
4, // 11: swarming.v1.ExternalScheduler.AssignTasks:input_type -> swarming.v1.AssignTasksRequest
7, // 12: swarming.v1.ExternalScheduler.GetCancellations:input_type -> swarming.v1.GetCancellationsRequest
10, // 13: swarming.v1.ExternalScheduler.NotifyTasks:input_type -> swarming.v1.NotifyTasksRequest
12, // 14: swarming.v1.ExternalScheduler.GetCallbacks:input_type -> swarming.v1.GetCallbacksRequest
5, // 15: swarming.v1.ExternalScheduler.AssignTasks:output_type -> swarming.v1.AssignTasksResponse
8, // 16: swarming.v1.ExternalScheduler.GetCancellations:output_type -> swarming.v1.GetCancellationsResponse
11, // 17: swarming.v1.ExternalScheduler.NotifyTasks:output_type -> swarming.v1.NotifyTasksResponse
13, // 18: swarming.v1.ExternalScheduler.GetCallbacks:output_type -> swarming.v1.GetCallbacksResponse
15, // [15:19] is the sub-list for method output_type
11, // [11:15] is the sub-list for method input_type
11, // [11:11] is the sub-list for extension type_name
11, // [11:11] is the sub-list for extension extendee
0, // [0:11] is the sub-list for field type_name
}
func init() { file_go_chromium_org_luci_swarming_proto_api_plugin_proto_init() }
func file_go_chromium_org_luci_swarming_proto_api_plugin_proto_init() {
if File_go_chromium_org_luci_swarming_proto_api_plugin_proto != nil {
return
}
file_go_chromium_org_luci_swarming_proto_api_swarming_proto_init()
if !protoimpl.UnsafeEnabled {
file_go_chromium_org_luci_swarming_proto_api_plugin_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} {
switch v := v.(*TaskSpec); i {
case 0:
return &v.state
case 1:
return &v.sizeCache
case 2:
return &v.unknownFields
default:
return nil
}
}
file_go_chromium_org_luci_swarming_proto_api_plugin_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} {
switch v := v.(*SliceSpec); i {
case 0:
return &v.state
case 1:
return &v.sizeCache
case 2:
return &v.unknownFields
default:
return nil
}
}
file_go_chromium_org_luci_swarming_proto_api_plugin_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} {
switch v := v.(*IdleBot); i {
case 0:
return &v.state
case 1:
return &v.sizeCache
case 2:
return &v.unknownFields
default:
return nil
}
}
file_go_chromium_org_luci_swarming_proto_api_plugin_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} {
switch v := v.(*AssignTasksRequest); i {
case 0:
return &v.state
case 1:
return &v.sizeCache
case 2:
return &v.unknownFields
default:
return nil
}
}
file_go_chromium_org_luci_swarming_proto_api_plugin_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} {
switch v := v.(*AssignTasksResponse); i {
case 0:
return &v.state
case 1:
return &v.sizeCache
case 2:
return &v.unknownFields
default:
return nil
}
}
file_go_chromium_org_luci_swarming_proto_api_plugin_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} {
switch v := v.(*TaskAssignment); i {
case 0:
return &v.state
case 1:
return &v.sizeCache
case 2:
return &v.unknownFields
default:
return nil
}
}
file_go_chromium_org_luci_swarming_proto_api_plugin_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} {
switch v := v.(*GetCancellationsRequest); i {
case 0:
return &v.state
case 1:
return &v.sizeCache
case 2:
return &v.unknownFields
default:
return nil
}
}
file_go_chromium_org_luci_swarming_proto_api_plugin_proto_msgTypes[7].Exporter = func(v interface{}, i int) interface{} {
switch v := v.(*GetCancellationsResponse); i {
case 0:
return &v.state
case 1:
return &v.sizeCache
case 2:
return &v.unknownFields
default:
return nil
}
}
file_go_chromium_org_luci_swarming_proto_api_plugin_proto_msgTypes[8].Exporter = func(v interface{}, i int) interface{} {
switch v := v.(*NotifyTasksItem); i {
case 0:
return &v.state
case 1:
return &v.sizeCache
case 2:
return &v.unknownFields
default:
return nil
}
}
file_go_chromium_org_luci_swarming_proto_api_plugin_proto_msgTypes[9].Exporter = func(v interface{}, i int) interface{} {
switch v := v.(*NotifyTasksRequest); i {
case 0:
return &v.state
case 1:
return &v.sizeCache
case 2:
return &v.unknownFields
default:
return nil
}
}
file_go_chromium_org_luci_swarming_proto_api_plugin_proto_msgTypes[10].Exporter = func(v interface{}, i int) interface{} {
switch v := v.(*NotifyTasksResponse); i {
case 0:
return &v.state
case 1:
return &v.sizeCache
case 2:
return &v.unknownFields
default:
return nil
}
}
file_go_chromium_org_luci_swarming_proto_api_plugin_proto_msgTypes[11].Exporter = func(v interface{}, i int) interface{} {
switch v := v.(*GetCallbacksRequest); i {
case 0:
return &v.state
case 1:
return &v.sizeCache
case 2:
return &v.unknownFields
default:
return nil
}
}
file_go_chromium_org_luci_swarming_proto_api_plugin_proto_msgTypes[12].Exporter = func(v interface{}, i int) interface{} {
switch v := v.(*GetCallbacksResponse); i {
case 0:
return &v.state
case 1:
return &v.sizeCache
case 2:
return &v.unknownFields
default:
return nil
}
}
file_go_chromium_org_luci_swarming_proto_api_plugin_proto_msgTypes[13].Exporter = func(v interface{}, i int) interface{} {
switch v := v.(*GetCancellationsResponse_Cancellation); i {
case 0:
return &v.state
case 1:
return &v.sizeCache
case 2:
return &v.unknownFields
default:
return nil
}
}
}
type x struct{}
out := protoimpl.TypeBuilder{
File: protoimpl.DescBuilder{
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
RawDescriptor: file_go_chromium_org_luci_swarming_proto_api_plugin_proto_rawDesc,
NumEnums: 1,
NumMessages: 14,
NumExtensions: 0,
NumServices: 1,
},
GoTypes: file_go_chromium_org_luci_swarming_proto_api_plugin_proto_goTypes,
DependencyIndexes: file_go_chromium_org_luci_swarming_proto_api_plugin_proto_depIdxs,
EnumInfos: file_go_chromium_org_luci_swarming_proto_api_plugin_proto_enumTypes,
MessageInfos: file_go_chromium_org_luci_swarming_proto_api_plugin_proto_msgTypes,
}.Build()
File_go_chromium_org_luci_swarming_proto_api_plugin_proto = out.File
file_go_chromium_org_luci_swarming_proto_api_plugin_proto_rawDesc = nil
file_go_chromium_org_luci_swarming_proto_api_plugin_proto_goTypes = nil
file_go_chromium_org_luci_swarming_proto_api_plugin_proto_depIdxs = nil
}
// Reference imports to suppress errors if they are not otherwise used.
var _ context.Context
var _ grpc.ClientConnInterface
// This is a compile-time assertion to ensure that this generated file
// is compatible with the grpc package it is being compiled against.
const _ = grpc.SupportPackageIsVersion6
// ExternalSchedulerClient is the client API for ExternalScheduler service.
//
// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.
type ExternalSchedulerClient interface {
// AssignTasks determines which tasks should be run on which of the supplied
// idle bots.
AssignTasks(ctx context.Context, in *AssignTasksRequest, opts ...grpc.CallOption) (*AssignTasksResponse, error)
// GetCancellations determines which tasks should be cancelled on which bots.
GetCancellations(ctx context.Context, in *GetCancellationsRequest, opts ...grpc.CallOption) (*GetCancellationsResponse, error)
// NotifyTasks informs the scheduler about the state of tasks (either new
// tasks, or states of existing tasks).
NotifyTasks(ctx context.Context, in *NotifyTasksRequest, opts ...grpc.CallOption) (*NotifyTasksResponse, error)
// GetCallbacks asks the scheduler for a set of request ids that the
// external scheduler wants to receive callback NotifyTasks calls about.
GetCallbacks(ctx context.Context, in *GetCallbacksRequest, opts ...grpc.CallOption) (*GetCallbacksResponse, error)
}
type externalSchedulerPRPCClient struct {
client *prpc.Client
}
func NewExternalSchedulerPRPCClient(client *prpc.Client) ExternalSchedulerClient {
return &externalSchedulerPRPCClient{client}
}
func (c *externalSchedulerPRPCClient) AssignTasks(ctx context.Context, in *AssignTasksRequest, opts ...grpc.CallOption) (*AssignTasksResponse, error) {
out := new(AssignTasksResponse)
err := c.client.Call(ctx, "swarming.v1.ExternalScheduler", "AssignTasks", in, out, opts...)
if err != nil {
return nil, err
}
return out, nil
}
func (c *externalSchedulerPRPCClient) GetCancellations(ctx context.Context, in *GetCancellationsRequest, opts ...grpc.CallOption) (*GetCancellationsResponse, error) {
out := new(GetCancellationsResponse)
err := c.client.Call(ctx, "swarming.v1.ExternalScheduler", "GetCancellations", in, out, opts...)
if err != nil {
return nil, err
}
return out, nil
}
func (c *externalSchedulerPRPCClient) NotifyTasks(ctx context.Context, in *NotifyTasksRequest, opts ...grpc.CallOption) (*NotifyTasksResponse, error) {
out := new(NotifyTasksResponse)
err := c.client.Call(ctx, "swarming.v1.ExternalScheduler", "NotifyTasks", in, out, opts...)
if err != nil {
return nil, err
}
return out, nil
}
func (c *externalSchedulerPRPCClient) GetCallbacks(ctx context.Context, in *GetCallbacksRequest, opts ...grpc.CallOption) (*GetCallbacksResponse, error) {
out := new(GetCallbacksResponse)
err := c.client.Call(ctx, "swarming.v1.ExternalScheduler", "GetCallbacks", in, out, opts...)
if err != nil {
return nil, err
}
return out, nil
}
type externalSchedulerClient struct {
cc grpc.ClientConnInterface
}
func NewExternalSchedulerClient(cc grpc.ClientConnInterface) ExternalSchedulerClient {
return &externalSchedulerClient{cc}
}
func (c *externalSchedulerClient) AssignTasks(ctx context.Context, in *AssignTasksRequest, opts ...grpc.CallOption) (*AssignTasksResponse, error) {
out := new(AssignTasksResponse)
err := c.cc.Invoke(ctx, "/swarming.v1.ExternalScheduler/AssignTasks", in, out, opts...)
if err != nil {
return nil, err
}
return out, nil
}
func (c *externalSchedulerClient) GetCancellations(ctx context.Context, in *GetCancellationsRequest, opts ...grpc.CallOption) (*GetCancellationsResponse, error) {
out := new(GetCancellationsResponse)
err := c.cc.Invoke(ctx, "/swarming.v1.ExternalScheduler/GetCancellations", in, out, opts...)
if err != nil {
return nil, err
}
return out, nil
}
func (c *externalSchedulerClient) NotifyTasks(ctx context.Context, in *NotifyTasksRequest, opts ...grpc.CallOption) (*NotifyTasksResponse, error) {
out := new(NotifyTasksResponse)
err := c.cc.Invoke(ctx, "/swarming.v1.ExternalScheduler/NotifyTasks", in, out, opts...)
if err != nil {
return nil, err
}
return out, nil
}
func (c *externalSchedulerClient) GetCallbacks(ctx context.Context, in *GetCallbacksRequest, opts ...grpc.CallOption) (*GetCallbacksResponse, error) {
out := new(GetCallbacksResponse)
err := c.cc.Invoke(ctx, "/swarming.v1.ExternalScheduler/GetCallbacks", in, out, opts...)
if err != nil {
return nil, err
}
return out, nil
}
// ExternalSchedulerServer is the server API for ExternalScheduler service.
type ExternalSchedulerServer interface {
// AssignTasks determines which tasks should be run on which of the supplied
// idle bots.
AssignTasks(context.Context, *AssignTasksRequest) (*AssignTasksResponse, error)
// GetCancellations determines which tasks should be cancelled on which bots.
GetCancellations(context.Context, *GetCancellationsRequest) (*GetCancellationsResponse, error)
// NotifyTasks informs the scheduler about the state of tasks (either new
// tasks, or states of existing tasks).
NotifyTasks(context.Context, *NotifyTasksRequest) (*NotifyTasksResponse, error)
// GetCallbacks asks the scheduler for a set of request ids that the
// external scheduler wants to receive callback NotifyTasks calls about.
GetCallbacks(context.Context, *GetCallbacksRequest) (*GetCallbacksResponse, error)
}
// UnimplementedExternalSchedulerServer can be embedded to have forward compatible implementations.
type UnimplementedExternalSchedulerServer struct {
}
func (*UnimplementedExternalSchedulerServer) AssignTasks(context.Context, *AssignTasksRequest) (*AssignTasksResponse, error) {
return nil, status.Errorf(codes.Unimplemented, "method AssignTasks not implemented")
}
func (*UnimplementedExternalSchedulerServer) GetCancellations(context.Context, *GetCancellationsRequest) (*GetCancellationsResponse, error) {
return nil, status.Errorf(codes.Unimplemented, "method GetCancellations not implemented")
}
func (*UnimplementedExternalSchedulerServer) NotifyTasks(context.Context, *NotifyTasksRequest) (*NotifyTasksResponse, error) {
return nil, status.Errorf(codes.Unimplemented, "method NotifyTasks not implemented")
}
func (*UnimplementedExternalSchedulerServer) GetCallbacks(context.Context, *GetCallbacksRequest) (*GetCallbacksResponse, error) {
return nil, status.Errorf(codes.Unimplemented, "method GetCallbacks not implemented")
}
func RegisterExternalSchedulerServer(s prpc.Registrar, srv ExternalSchedulerServer) {
s.RegisterService(&_ExternalScheduler_serviceDesc, srv)
}
func _ExternalScheduler_AssignTasks_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
in := new(AssignTasksRequest)
if err := dec(in); err != nil {
return nil, err
}
if interceptor == nil {
return srv.(ExternalSchedulerServer).AssignTasks(ctx, in)
}
info := &grpc.UnaryServerInfo{
Server: srv,
FullMethod: "/swarming.v1.ExternalScheduler/AssignTasks",
}
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
return srv.(ExternalSchedulerServer).AssignTasks(ctx, req.(*AssignTasksRequest))
}
return interceptor(ctx, in, info, handler)
}
func _ExternalScheduler_GetCancellations_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
in := new(GetCancellationsRequest)
if err := dec(in); err != nil {
return nil, err
}
if interceptor == nil {
return srv.(ExternalSchedulerServer).GetCancellations(ctx, in)
}
info := &grpc.UnaryServerInfo{
Server: srv,
FullMethod: "/swarming.v1.ExternalScheduler/GetCancellations",
}
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
return srv.(ExternalSchedulerServer).GetCancellations(ctx, req.(*GetCancellationsRequest))
}
return interceptor(ctx, in, info, handler)
}
func _ExternalScheduler_NotifyTasks_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
in := new(NotifyTasksRequest)
if err := dec(in); err != nil {
return nil, err
}
if interceptor == nil {
return srv.(ExternalSchedulerServer).NotifyTasks(ctx, in)
}
info := &grpc.UnaryServerInfo{
Server: srv,
FullMethod: "/swarming.v1.ExternalScheduler/NotifyTasks",
}
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
return srv.(ExternalSchedulerServer).NotifyTasks(ctx, req.(*NotifyTasksRequest))
}
return interceptor(ctx, in, info, handler)
}
func _ExternalScheduler_GetCallbacks_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
in := new(GetCallbacksRequest)
if err := dec(in); err != nil {
return nil, err
}
if interceptor == nil {
return srv.(ExternalSchedulerServer).GetCallbacks(ctx, in)
}
info := &grpc.UnaryServerInfo{
Server: srv,
FullMethod: "/swarming.v1.ExternalScheduler/GetCallbacks",
}
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
return srv.(ExternalSchedulerServer).GetCallbacks(ctx, req.(*GetCallbacksRequest))
}
return interceptor(ctx, in, info, handler)
}
var _ExternalScheduler_serviceDesc = grpc.ServiceDesc{
ServiceName: "swarming.v1.ExternalScheduler",
HandlerType: (*ExternalSchedulerServer)(nil),
Methods: []grpc.MethodDesc{
{
MethodName: "AssignTasks",
Handler: _ExternalScheduler_AssignTasks_Handler,
},
{
MethodName: "GetCancellations",
Handler: _ExternalScheduler_GetCancellations_Handler,
},
{
MethodName: "NotifyTasks",
Handler: _ExternalScheduler_NotifyTasks_Handler,
},
{
MethodName: "GetCallbacks",
Handler: _ExternalScheduler_GetCallbacks_Handler,
},
},
Streams: []grpc.StreamDesc{},
Metadata: "go.chromium.org/luci/swarming/proto/api/plugin.proto",
}