proto: go.chromium.org/chromiumos/infra/proto/go/test_platform/migration/scheduler Index | Files

package scheduler

import "go.chromium.org/chromiumos/infra/proto/go/test_platform/migration/scheduler"

Index

Package Files

traffic_split.pb.go

Variables

var Backend_name = map[int32]string{
    0:  "BACKEND_UNSPECIFIED",
    1:  "BACKEND_AUTOTEST",
    2:  "BACKEND_SKYLAB",
}
var Backend_value = map[string]int32{
    "BACKEND_UNSPECIFIED": 0,
    "BACKEND_AUTOTEST":    1,
    "BACKEND_SKYLAB":      2,
}

type Backend Uses

type Backend int32
const (
    Backend_BACKEND_UNSPECIFIED Backend = 0
    Backend_BACKEND_AUTOTEST    Backend = 1
    Backend_BACKEND_SKYLAB      Backend = 2
)

func (Backend) EnumDescriptor Uses

func (Backend) EnumDescriptor() ([]byte, []int)

func (Backend) String Uses

func (x Backend) String() string

type Request Uses

type Request struct {
    Scheduling           *test_platform.Request_Params_Scheduling `protobuf:"bytes,1,opt,name=scheduling,proto3" json:"scheduling,omitempty"`
    Model                string                                   `protobuf:"bytes,2,opt,name=model,proto3" json:"model,omitempty"`
    BuildTarget          *chromiumos.BuildTarget                  `protobuf:"bytes,3,opt,name=build_target,json=buildTarget,proto3" json:"build_target,omitempty"`
    XXX_NoUnkeyedLiteral struct{}                                 `json:"-"`
    XXX_unrecognized     []byte                                   `json:"-"`
    XXX_sizecache        int32                                    `json:"-"`
}

Request is a subset of test_platform.Request that is relevant to the scheduler backend traffic splitting decision.

func (*Request) Descriptor Uses

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

func (*Request) GetBuildTarget Uses

func (m *Request) GetBuildTarget() *chromiumos.BuildTarget

func (*Request) GetModel Uses

func (m *Request) GetModel() string

func (*Request) GetScheduling Uses

func (m *Request) GetScheduling() *test_platform.Request_Params_Scheduling

func (*Request) ProtoMessage Uses

func (*Request) ProtoMessage()

func (*Request) Reset Uses

func (m *Request) Reset()

func (*Request) String Uses

func (m *Request) String() string

func (*Request) XXX_DiscardUnknown Uses

func (m *Request) XXX_DiscardUnknown()

func (*Request) XXX_Marshal Uses

func (m *Request) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*Request) XXX_Merge Uses

func (m *Request) XXX_Merge(src proto.Message)

func (*Request) XXX_Size Uses

func (m *Request) XXX_Size() int

func (*Request) XXX_Unmarshal Uses

func (m *Request) XXX_Unmarshal(b []byte) error

type RequestMod Uses

type RequestMod struct {
    Scheduling           *test_platform.Request_Params_Scheduling `protobuf:"bytes,1,opt,name=scheduling,proto3" json:"scheduling,omitempty"`
    XXX_NoUnkeyedLiteral struct{}                                 `json:"-"`
    XXX_unrecognized     []byte                                   `json:"-"`
    XXX_sizecache        int32                                    `json:"-"`
}

RequestMod contains the test_platform.Requset arguments that must be overridden when forwarding a request to the chosen scheduler backend.

func (*RequestMod) Descriptor Uses

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

func (*RequestMod) GetScheduling Uses

func (m *RequestMod) GetScheduling() *test_platform.Request_Params_Scheduling

func (*RequestMod) ProtoMessage Uses

func (*RequestMod) ProtoMessage()

func (*RequestMod) Reset Uses

func (m *RequestMod) Reset()

func (*RequestMod) String Uses

func (m *RequestMod) String() string

func (*RequestMod) XXX_DiscardUnknown Uses

func (m *RequestMod) XXX_DiscardUnknown()

func (*RequestMod) XXX_Marshal Uses

func (m *RequestMod) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*RequestMod) XXX_Merge Uses

func (m *RequestMod) XXX_Merge(src proto.Message)

func (*RequestMod) XXX_Size Uses

func (m *RequestMod) XXX_Size() int

func (*RequestMod) XXX_Unmarshal Uses

func (m *RequestMod) XXX_Unmarshal(b []byte) error

type Rule Uses

type Rule struct {
    Request              *Request    `protobuf:"bytes,1,opt,name=request,proto3" json:"request,omitempty"`
    Backend              Backend     `protobuf:"varint,2,opt,name=backend,proto3,enum=test_platform.migration.scheduler.Backend" json:"backend,omitempty"`
    RequestMod           *RequestMod `protobuf:"bytes,3,opt,name=request_mod,json=requestMod,proto3" json:"request_mod,omitempty"`
    XXX_NoUnkeyedLiteral struct{}    `json:"-"`
    XXX_unrecognized     []byte      `json:"-"`
    XXX_sizecache        int32       `json:"-"`
}

func (*Rule) Descriptor Uses

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

func (*Rule) GetBackend Uses

func (m *Rule) GetBackend() Backend

func (*Rule) GetRequest Uses

func (m *Rule) GetRequest() *Request

func (*Rule) GetRequestMod Uses

func (m *Rule) GetRequestMod() *RequestMod

func (*Rule) ProtoMessage Uses

func (*Rule) ProtoMessage()

func (*Rule) Reset Uses

func (m *Rule) Reset()

func (*Rule) String Uses

func (m *Rule) String() string

func (*Rule) XXX_DiscardUnknown Uses

func (m *Rule) XXX_DiscardUnknown()

func (*Rule) XXX_Marshal Uses

func (m *Rule) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*Rule) XXX_Merge Uses

func (m *Rule) XXX_Merge(src proto.Message)

func (*Rule) XXX_Size Uses

func (m *Rule) XXX_Size() int

func (*Rule) XXX_Unmarshal Uses

func (m *Rule) XXX_Unmarshal(b []byte) error

type SuiteOverride Uses

type SuiteOverride struct {
    // Incoming request must target this suite, in addition to the requirements
    // of the rule specified below.
    Suite                *test_platform.Request_Suite `protobuf:"bytes,1,opt,name=suite,proto3" json:"suite,omitempty"`
    Rule                 *Rule                        `protobuf:"bytes,2,opt,name=rule,proto3" json:"rule,omitempty"`
    XXX_NoUnkeyedLiteral struct{}                     `json:"-"`
    XXX_unrecognized     []byte                       `json:"-"`
    XXX_sizecache        int32                        `json:"-"`
}

SuiteOverride provides per-suite overrides for the traffic split laid down by the basic rules.

func (*SuiteOverride) Descriptor Uses

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

func (*SuiteOverride) GetRule Uses

func (m *SuiteOverride) GetRule() *Rule

func (*SuiteOverride) GetSuite Uses

func (m *SuiteOverride) GetSuite() *test_platform.Request_Suite

func (*SuiteOverride) ProtoMessage Uses

func (*SuiteOverride) ProtoMessage()

func (*SuiteOverride) Reset Uses

func (m *SuiteOverride) Reset()

func (*SuiteOverride) String Uses

func (m *SuiteOverride) String() string

func (*SuiteOverride) XXX_DiscardUnknown Uses

func (m *SuiteOverride) XXX_DiscardUnknown()

func (*SuiteOverride) XXX_Marshal Uses

func (m *SuiteOverride) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*SuiteOverride) XXX_Merge Uses

func (m *SuiteOverride) XXX_Merge(src proto.Message)

func (*SuiteOverride) XXX_Size Uses

func (m *SuiteOverride) XXX_Size() int

func (*SuiteOverride) XXX_Unmarshal Uses

func (m *SuiteOverride) XXX_Unmarshal(b []byte) error

type TrafficSplit Uses

type TrafficSplit struct {
    // Rules are expected to be exhaustive. If an incoming request does not match
    // any available rule, the traffic splitter will fail.
    //
    // This policy prevents requests for newly deployed models / pools from getting
    // scheduled on the incorrect scheduler and then timing out due to lack of
    // devices.
    Rules []*Rule `protobuf:"bytes,1,rep,name=rules,proto3" json:"rules,omitempty"`
    // Unlike rules, suite overrides are only specified for suites that need
    // different handling from the rule that otherwise matches the request.
    SuiteOverrides       []*SuiteOverride `protobuf:"bytes,2,rep,name=suite_overrides,json=suiteOverrides,proto3" json:"suite_overrides,omitempty"`
    XXX_NoUnkeyedLiteral struct{}         `json:"-"`
    XXX_unrecognized     []byte           `json:"-"`
    XXX_sizecache        int32            `json:"-"`
}

The cros_test_platform traffic splitting stage interprets this config in two phases. 1. First, the request is matched to any of the rules in the suite_overrides,

including the requested suite. If matching rules are found, second phase
is skipped.

2. Next, the request is matched against the base rules (exluding suite name)

If no matching rules are found, the steps fails.

If multiple rules are found, they *must agree on the traffic splitting decision* including any pool overrides. In case of conflicting rules, the step fails.

func (*TrafficSplit) Descriptor Uses

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

func (*TrafficSplit) GetRules Uses

func (m *TrafficSplit) GetRules() []*Rule

func (*TrafficSplit) GetSuiteOverrides Uses

func (m *TrafficSplit) GetSuiteOverrides() []*SuiteOverride

func (*TrafficSplit) ProtoMessage Uses

func (*TrafficSplit) ProtoMessage()

func (*TrafficSplit) Reset Uses

func (m *TrafficSplit) Reset()

func (*TrafficSplit) String Uses

func (m *TrafficSplit) String() string

func (*TrafficSplit) XXX_DiscardUnknown Uses

func (m *TrafficSplit) XXX_DiscardUnknown()

func (*TrafficSplit) XXX_Marshal Uses

func (m *TrafficSplit) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*TrafficSplit) XXX_Merge Uses

func (m *TrafficSplit) XXX_Merge(src proto.Message)

func (*TrafficSplit) XXX_Size Uses

func (m *TrafficSplit) XXX_Size() int

func (*TrafficSplit) XXX_Unmarshal Uses

func (m *TrafficSplit) XXX_Unmarshal(b []byte) error

Package scheduler imports 5 packages (graph) and is imported by 1 packages. Updated 2019-09-20. Refresh now. Tools for package owners.