Documentation
¶
Index ¶
- Variables
- func ErrorFilename(planBaseName string) string
- func FinishedFilename(planBaseName string, id string) string
- func IsErrorFilename(name string) (bool, string)
- func IsFinishedFilename(name string) (bool, string, string)
- func IsPlanFilename(name string) (bool, string)
- func IsProgressFilename(name string) (bool, string, time.Time)
- func PreparePlanFileReader(planFile string, in io.Reader) (io.Reader, error)
- func ProgressFilename(planBaseName string, t time.Time) string
- func RegisterSchedulerServer(s *grpc.Server, srv SchedulerServer)
- func StartingFilename(planBaseName string, t time.Time) string
- type AllowedUsers
- type NextPlanRequest
- func (*NextPlanRequest) Descriptor() ([]byte, []int)
- func (this *NextPlanRequest) Equal(that interface{}) bool
- func (m *NextPlanRequest) GetName() string
- func (this *NextPlanRequest) GoString() string
- func (m *NextPlanRequest) Marshal() (dAtA []byte, err error)
- func (m *NextPlanRequest) MarshalTo(dAtA []byte) (int, error)
- func (m *NextPlanRequest) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*NextPlanRequest) ProtoMessage()
- func (m *NextPlanRequest) Reset()
- func (m *NextPlanRequest) Size() (n int)
- func (this *NextPlanRequest) String() string
- func (m *NextPlanRequest) Unmarshal(dAtA []byte) error
- func (m *NextPlanRequest) XXX_DiscardUnknown()
- func (m *NextPlanRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *NextPlanRequest) XXX_Merge(src proto.Message)
- func (m *NextPlanRequest) XXX_Size() int
- func (m *NextPlanRequest) XXX_Unmarshal(b []byte) error
- type NextPlanResponse
- func (*NextPlanResponse) Descriptor() ([]byte, []int)
- func (this *NextPlanResponse) Equal(that interface{}) bool
- func (m *NextPlanResponse) GetPlanFile() string
- func (m *NextPlanResponse) GetProgressFile() string
- func (this *NextPlanResponse) GoString() string
- func (m *NextPlanResponse) Marshal() (dAtA []byte, err error)
- func (m *NextPlanResponse) MarshalTo(dAtA []byte) (int, error)
- func (m *NextPlanResponse) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*NextPlanResponse) ProtoMessage()
- func (m *NextPlanResponse) Reset()
- func (m *NextPlanResponse) Size() (n int)
- func (this *NextPlanResponse) String() string
- func (m *NextPlanResponse) Unmarshal(dAtA []byte) error
- func (m *NextPlanResponse) XXX_DiscardUnknown()
- func (m *NextPlanResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *NextPlanResponse) XXX_Merge(src proto.Message)
- func (m *NextPlanResponse) XXX_Size() int
- func (m *NextPlanResponse) XXX_Unmarshal(b []byte) error
- type PlanEntry
- type SchedulerClient
- type SchedulerServer
- type SharedConfig
- type UnimplementedSchedulerServer
Constants ¶
This section is empty.
Variables ¶
View Source
var (
ErrInvalidLengthScheduler = fmt.Errorf("proto: negative length found during unmarshaling")
ErrIntOverflowScheduler = fmt.Errorf("proto: integer overflow")
)
View Source
var AllowAllUsers = AllowedUsers(nil)
Functions ¶
func ErrorFilename ¶
func ErrorFilename(planBaseName string) string
func FinishedFilename ¶
func FinishedFilename(planBaseName string, id string) string
func IsErrorFilename ¶
func IsErrorFilename(name string) (bool, string)
func IsFinishedFilename ¶
func IsFinishedFilename(name string) (bool, string, string)
func IsPlanFilename ¶
func IsPlanFilename(name string) (bool, string)
Returns true and "base name" or false and empty string.
func IsProgressFilename ¶
func IsProgressFilename(name string) (bool, string, time.Time)
func PreparePlanFileReader ¶
func PreparePlanFileReader(planFile string, in io.Reader) (io.Reader, error)
func ProgressFilename ¶
func ProgressFilename(planBaseName string, t time.Time) string
func RegisterSchedulerServer ¶
func RegisterSchedulerServer(s *grpc.Server, srv SchedulerServer)
func StartingFilename ¶
func StartingFilename(planBaseName string, t time.Time) string
Types ¶
type AllowedUsers ¶
type AllowedUsers map[string]struct{}
func ParseAllowedUsers ¶
func ParseAllowedUsers(commaSeparated string) AllowedUsers
func ParseAllowedUsersFromFile ¶
func ParseAllowedUsersFromFile(file string) (AllowedUsers, error)
func (AllowedUsers) AllUsersAllowed ¶
func (a AllowedUsers) AllUsersAllowed() bool
func (AllowedUsers) GetAllowedUsers ¶
func (a AllowedUsers) GetAllowedUsers(users []string) []string
type NextPlanRequest ¶
type NextPlanRequest struct {
// Name of service requesting the plan.
Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
}
func (*NextPlanRequest) Descriptor ¶
func (*NextPlanRequest) Descriptor() ([]byte, []int)
func (*NextPlanRequest) MarshalToSizedBuffer ¶
func (m *NextPlanRequest) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*NextPlanRequest) ProtoMessage ¶
func (*NextPlanRequest) ProtoMessage()
func (*NextPlanRequest) XXX_DiscardUnknown ¶
func (m *NextPlanRequest) XXX_DiscardUnknown()
func (*NextPlanRequest) XXX_Marshal ¶
func (m *NextPlanRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*NextPlanRequest) XXX_Unmarshal ¶
func (m *NextPlanRequest) XXX_Unmarshal(b []byte) error
type NextPlanResponse ¶
type NextPlanResponse struct {
PlanFile string `protobuf:"bytes,1,opt,name=planFile,proto3" json:"planFile,omitempty"`
ProgressFile string `protobuf:"bytes,2,opt,name=progressFile,proto3" json:"progressFile,omitempty"`
}
func (*NextPlanResponse) Descriptor ¶
func (*NextPlanResponse) Descriptor() ([]byte, []int)
func (*NextPlanResponse) GetPlanFile ¶
func (m *NextPlanResponse) GetPlanFile() string
func (*NextPlanResponse) GetProgressFile ¶
func (m *NextPlanResponse) GetProgressFile() string
func (*NextPlanResponse) MarshalToSizedBuffer ¶
func (m *NextPlanResponse) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*NextPlanResponse) ProtoMessage ¶
func (*NextPlanResponse) ProtoMessage()
func (*NextPlanResponse) XXX_DiscardUnknown ¶
func (m *NextPlanResponse) XXX_DiscardUnknown()
func (*NextPlanResponse) XXX_Marshal ¶
func (m *NextPlanResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*NextPlanResponse) XXX_Unmarshal ¶
func (m *NextPlanResponse) XXX_Unmarshal(b []byte) error
type PlanEntry ¶
type PlanEntry struct {
// Header
User string `json:"user,omitempty"`
DayIndex int `json:"day_index,omitempty"`
// Entries
SeriesID string `json:"sid,omitempty"`
Chunks []string `json:"cs,omitempty"`
// Footer
Complete bool `json:"complete,omitempty"`
}
type SchedulerClient ¶
type SchedulerClient interface {
// Returns next plan that builder should work on.
NextPlan(ctx context.Context, in *NextPlanRequest, opts ...grpc.CallOption) (*NextPlanResponse, error)
}
SchedulerClient is the client API for Scheduler service.
For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.
func NewSchedulerClient ¶
func NewSchedulerClient(cc *grpc.ClientConn) SchedulerClient
type SchedulerServer ¶
type SchedulerServer interface {
// Returns next plan that builder should work on.
NextPlan(context.Context, *NextPlanRequest) (*NextPlanResponse, error)
}
SchedulerServer is the server API for Scheduler service.
type SharedConfig ¶
type SharedConfig struct {
SchemaConfig chunk.SchemaConfig // Flags registered by main.go
StorageConfig storage.Config
Bucket bucket.Config
BucketPrefix string
}
func (*SharedConfig) GetBucket ¶
func (cfg *SharedConfig) GetBucket(l log.Logger, reg prometheus.Registerer) (objstore.Bucket, error)
func (*SharedConfig) RegisterFlags ¶
func (cfg *SharedConfig) RegisterFlags(f *flag.FlagSet)
type UnimplementedSchedulerServer ¶
type UnimplementedSchedulerServer struct {
}
UnimplementedSchedulerServer can be embedded to have forward compatible implementations.
Click to show internal directories.
Click to hide internal directories.