Documentation
¶
Index ¶
- Variables
- func FileDescriptorSet() *descriptorpb.FileDescriptorSet
- func RegisterStatsServer(s prpc.Registrar, srv StatsServer)
- type DataSet
- type FetchMetricsRequest
- func (*FetchMetricsRequest) Descriptor() ([]byte, []int)deprecated
- func (x *FetchMetricsRequest) GetDataSource() string
- func (x *FetchMetricsRequest) GetDates() []string
- func (x *FetchMetricsRequest) GetMetrics() []string
- func (x *FetchMetricsRequest) GetPeriod() Period
- func (*FetchMetricsRequest) ProtoMessage()
- func (x *FetchMetricsRequest) ProtoReflect() protoreflect.Message
- func (x *FetchMetricsRequest) Reset()
- func (x *FetchMetricsRequest) String() string
- type FetchMetricsResponse
- func (*FetchMetricsResponse) Descriptor() ([]byte, []int)deprecated
- func (x *FetchMetricsResponse) GetSections() []*Section
- func (*FetchMetricsResponse) ProtoMessage()
- func (x *FetchMetricsResponse) ProtoReflect() protoreflect.Message
- func (x *FetchMetricsResponse) Reset()
- func (x *FetchMetricsResponse) String() string
- type Metric
- func (*Metric) Descriptor() ([]byte, []int)deprecated
- func (x *Metric) GetData() *DataSet
- func (x *Metric) GetName() string
- func (x *Metric) GetSections() map[string]*DataSet
- func (*Metric) ProtoMessage()
- func (x *Metric) ProtoReflect() protoreflect.Message
- func (x *Metric) Reset()
- func (x *Metric) String() string
- type Period
- type Section
- type StatsClient
- type StatsServer
- type UnimplementedStatsServer
Constants ¶
This section is empty.
Variables ¶
var ( Period_name = map[int32]string{ 0: "UNSPECIFIED", 1: "WEEK", 2: "DAY", } Period_value = map[string]int32{ "UNSPECIFIED": 0, "WEEK": 1, "DAY": 2, } )
Enum value maps for Period.
var File_go_chromium_org_infra_appengine_statsui_api_service_proto protoreflect.FileDescriptor
Functions ¶
func FileDescriptorSet ¶
func FileDescriptorSet() *descriptorpb.FileDescriptorSet
FileDescriptorSet returns a descriptor set for this proto package, which includes all defined services, and all transitive dependencies.
Will not return nil.
Do NOT modify the returned descriptor.
func RegisterStatsServer ¶
func RegisterStatsServer(s prpc.Registrar, srv StatsServer)
Types ¶
type DataSet ¶
type DataSet struct { // A set of data. This is a map of dates (in YYYY-MM-DD format) to numbers. Data map[string]float32 `` /* 137-byte string literal not displayed */ // contains filtered or unexported fields }
func (*DataSet) Descriptor
deprecated
func (*DataSet) ProtoMessage ¶
func (*DataSet) ProtoMessage()
func (*DataSet) ProtoReflect ¶
func (x *DataSet) ProtoReflect() protoreflect.Message
type FetchMetricsRequest ¶
type FetchMetricsRequest struct { // Data source to pull the metrics from. // See datasources.yaml for valid values. DataSource string `protobuf:"bytes,1,opt,name=data_source,json=dataSource,proto3" json:"data_source,omitempty"` // Time period to fetch. Period Period `protobuf:"varint,2,opt,name=period,proto3,enum=statsui.Period" json:"period,omitempty"` // Dates to fetch. This should align to the period. // Dates should be specified in YYYY-MM-DD format. Dates []string `protobuf:"bytes,3,rep,name=dates,proto3" json:"dates,omitempty"` // Metrics to fetch. These are specific to th datasource. // This is required. If no metrics are specified an error is returned. Metrics []string `protobuf:"bytes,4,rep,name=metrics,proto3" json:"metrics,omitempty"` // contains filtered or unexported fields }
func (*FetchMetricsRequest) Descriptor
deprecated
func (*FetchMetricsRequest) Descriptor() ([]byte, []int)
Deprecated: Use FetchMetricsRequest.ProtoReflect.Descriptor instead.
func (*FetchMetricsRequest) GetDataSource ¶
func (x *FetchMetricsRequest) GetDataSource() string
func (*FetchMetricsRequest) GetDates ¶
func (x *FetchMetricsRequest) GetDates() []string
func (*FetchMetricsRequest) GetMetrics ¶
func (x *FetchMetricsRequest) GetMetrics() []string
func (*FetchMetricsRequest) GetPeriod ¶
func (x *FetchMetricsRequest) GetPeriod() Period
func (*FetchMetricsRequest) ProtoMessage ¶
func (*FetchMetricsRequest) ProtoMessage()
func (*FetchMetricsRequest) ProtoReflect ¶
func (x *FetchMetricsRequest) ProtoReflect() protoreflect.Message
func (*FetchMetricsRequest) Reset ¶
func (x *FetchMetricsRequest) Reset()
func (*FetchMetricsRequest) String ¶
func (x *FetchMetricsRequest) String() string
type FetchMetricsResponse ¶
type FetchMetricsResponse struct { // The various sections fetched for the given metrics. Sections []*Section `protobuf:"bytes,1,rep,name=sections,proto3" json:"sections,omitempty"` // contains filtered or unexported fields }
func (*FetchMetricsResponse) Descriptor
deprecated
func (*FetchMetricsResponse) Descriptor() ([]byte, []int)
Deprecated: Use FetchMetricsResponse.ProtoReflect.Descriptor instead.
func (*FetchMetricsResponse) GetSections ¶
func (x *FetchMetricsResponse) GetSections() []*Section
func (*FetchMetricsResponse) ProtoMessage ¶
func (*FetchMetricsResponse) ProtoMessage()
func (*FetchMetricsResponse) ProtoReflect ¶
func (x *FetchMetricsResponse) ProtoReflect() protoreflect.Message
func (*FetchMetricsResponse) Reset ¶
func (x *FetchMetricsResponse) Reset()
func (*FetchMetricsResponse) String ¶
func (x *FetchMetricsResponse) String() string
type Metric ¶
type Metric struct { // Name of the metric. Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` // Either data or sections should be defined, but not both. // Set of data for the metric. Data *DataSet `protobuf:"bytes,2,opt,name=data,proto3" json:"data,omitempty"` // Sections if the data is grouped by label. Sections map[string]*DataSet `` /* 143-byte string literal not displayed */ // contains filtered or unexported fields }
func (*Metric) Descriptor
deprecated
func (*Metric) GetSections ¶
func (*Metric) ProtoMessage ¶
func (*Metric) ProtoMessage()
func (*Metric) ProtoReflect ¶
func (x *Metric) ProtoReflect() protoreflect.Message
type Period ¶
type Period int32
Enumeration to specify the time period to fetch
func (Period) Descriptor ¶
func (Period) Descriptor() protoreflect.EnumDescriptor
func (Period) EnumDescriptor
deprecated
func (Period) Number ¶
func (x Period) Number() protoreflect.EnumNumber
func (Period) Type ¶
func (Period) Type() protoreflect.EnumType
type Section ¶
type Section struct { // Name, or grouping label for the metrics. Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` // Metrics fetched. Metrics []*Metric `protobuf:"bytes,2,rep,name=metrics,proto3" json:"metrics,omitempty"` // contains filtered or unexported fields }
func (*Section) Descriptor
deprecated
func (*Section) GetMetrics ¶
func (*Section) ProtoMessage ¶
func (*Section) ProtoMessage()
func (*Section) ProtoReflect ¶
func (x *Section) ProtoReflect() protoreflect.Message
type StatsClient ¶
type StatsClient interface { // FetchMetrics is called by the frontend to fetch metrics from the database. FetchMetrics(ctx context.Context, in *FetchMetricsRequest, opts ...grpc.CallOption) (*FetchMetricsResponse, error) }
StatsClient is the client API for Stats service.
For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.
func NewStatsClient ¶
func NewStatsClient(cc grpc.ClientConnInterface) StatsClient
func NewStatsPRPCClient ¶
func NewStatsPRPCClient(client *prpc.Client) StatsClient
type StatsServer ¶
type StatsServer interface { // FetchMetrics is called by the frontend to fetch metrics from the database. FetchMetrics(context.Context, *FetchMetricsRequest) (*FetchMetricsResponse, error) }
StatsServer is the server API for Stats service.
type UnimplementedStatsServer ¶
type UnimplementedStatsServer struct { }
UnimplementedStatsServer can be embedded to have forward compatible implementations.
func (*UnimplementedStatsServer) FetchMetrics ¶
func (*UnimplementedStatsServer) FetchMetrics(context.Context, *FetchMetricsRequest) (*FetchMetricsResponse, error)