// Code generated by protoc-gen-go. DO NOT EDIT. // versions: // protoc-gen-go v1.36.11 // protoc v7.34.1 // source: stats.proto package statsv1 import ( protoreflect "google.golang.org/protobuf/reflect/protoreflect" protoimpl "google.golang.org/protobuf/runtime/protoimpl" reflect "reflect" sync "sync" unsafe "unsafe" ) 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) ) // Control message. First frame from client must be HELLO with target. type Frame_Kind int32 const ( Frame_UNKNOWN Frame_Kind = 0 Frame_HELLO Frame_Kind = 1 Frame_DATA Frame_Kind = 2 Frame_CLOSE Frame_Kind = 3 ) // Enum value maps for Frame_Kind. var ( Frame_Kind_name = map[int32]string{ 0: "UNKNOWN", 1: "HELLO", 2: "DATA", 3: "CLOSE", } Frame_Kind_value = map[string]int32{ "UNKNOWN": 0, "HELLO": 1, "DATA": 2, "CLOSE": 3, } ) func (x Frame_Kind) Enum() *Frame_Kind { p := new(Frame_Kind) *p = x return p } func (x Frame_Kind) String() string { return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x)) } func (Frame_Kind) Descriptor() protoreflect.EnumDescriptor { return file_stats_proto_enumTypes[0].Descriptor() } func (Frame_Kind) Type() protoreflect.EnumType { return &file_stats_proto_enumTypes[0] } func (x Frame_Kind) Number() protoreflect.EnumNumber { return protoreflect.EnumNumber(x) } // Deprecated: Use Frame_Kind.Descriptor instead. func (Frame_Kind) EnumDescriptor() ([]byte, []int) { return file_stats_proto_rawDescGZIP(), []int{5, 0} } type Filter struct { state protoimpl.MessageState `protogen:"open.v1"` Node string `protobuf:"bytes,1,opt,name=node,proto3" json:"node,omitempty"` // "fl" | "pl1" | "" (all) Limit int32 `protobuf:"varint,2,opt,name=limit,proto3" json:"limit,omitempty"` // 1..1000 Since string `protobuf:"bytes,3,opt,name=since,proto3" json:"since,omitempty"` // RFC3339, optional unknownFields protoimpl.UnknownFields sizeCache protoimpl.SizeCache } func (x *Filter) Reset() { *x = Filter{} mi := &file_stats_proto_msgTypes[0] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } func (x *Filter) String() string { return protoimpl.X.MessageStringOf(x) } func (*Filter) ProtoMessage() {} func (x *Filter) ProtoReflect() protoreflect.Message { mi := &file_stats_proto_msgTypes[0] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) } return ms } return mi.MessageOf(x) } // Deprecated: Use Filter.ProtoReflect.Descriptor instead. func (*Filter) Descriptor() ([]byte, []int) { return file_stats_proto_rawDescGZIP(), []int{0} } func (x *Filter) GetNode() string { if x != nil { return x.Node } return "" } func (x *Filter) GetLimit() int32 { if x != nil { return x.Limit } return 0 } func (x *Filter) GetSince() string { if x != nil { return x.Since } return "" } type Sample struct { state protoimpl.MessageState `protogen:"open.v1"` Node string `protobuf:"bytes,1,opt,name=node,proto3" json:"node,omitempty"` Timestamp string `protobuf:"bytes,2,opt,name=timestamp,proto3" json:"timestamp,omitempty"` // RFC3339 HttpLatencyMs float64 `protobuf:"fixed64,3,opt,name=http_latency_ms,json=httpLatencyMs,proto3" json:"http_latency_ms,omitempty"` TcpRttMs float64 `protobuf:"fixed64,4,opt,name=tcp_rtt_ms,json=tcpRttMs,proto3" json:"tcp_rtt_ms,omitempty"` DnsResolveMs float64 `protobuf:"fixed64,5,opt,name=dns_resolve_ms,json=dnsResolveMs,proto3" json:"dns_resolve_ms,omitempty"` TlsHandshakeMs float64 `protobuf:"fixed64,6,opt,name=tls_handshake_ms,json=tlsHandshakeMs,proto3" json:"tls_handshake_ms,omitempty"` ThroughputKbps int64 `protobuf:"varint,7,opt,name=throughput_kbps,json=throughputKbps,proto3" json:"throughput_kbps,omitempty"` unknownFields protoimpl.UnknownFields sizeCache protoimpl.SizeCache } func (x *Sample) Reset() { *x = Sample{} mi := &file_stats_proto_msgTypes[1] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } func (x *Sample) String() string { return protoimpl.X.MessageStringOf(x) } func (*Sample) ProtoMessage() {} func (x *Sample) ProtoReflect() protoreflect.Message { mi := &file_stats_proto_msgTypes[1] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) } return ms } return mi.MessageOf(x) } // Deprecated: Use Sample.ProtoReflect.Descriptor instead. func (*Sample) Descriptor() ([]byte, []int) { return file_stats_proto_rawDescGZIP(), []int{1} } func (x *Sample) GetNode() string { if x != nil { return x.Node } return "" } func (x *Sample) GetTimestamp() string { if x != nil { return x.Timestamp } return "" } func (x *Sample) GetHttpLatencyMs() float64 { if x != nil { return x.HttpLatencyMs } return 0 } func (x *Sample) GetTcpRttMs() float64 { if x != nil { return x.TcpRttMs } return 0 } func (x *Sample) GetDnsResolveMs() float64 { if x != nil { return x.DnsResolveMs } return 0 } func (x *Sample) GetTlsHandshakeMs() float64 { if x != nil { return x.TlsHandshakeMs } return 0 } func (x *Sample) GetThroughputKbps() int64 { if x != nil { return x.ThroughputKbps } return 0 } type Range struct { state protoimpl.MessageState `protogen:"open.v1"` Node string `protobuf:"bytes,1,opt,name=node,proto3" json:"node,omitempty"` Since string `protobuf:"bytes,2,opt,name=since,proto3" json:"since,omitempty"` Until string `protobuf:"bytes,3,opt,name=until,proto3" json:"until,omitempty"` unknownFields protoimpl.UnknownFields sizeCache protoimpl.SizeCache } func (x *Range) Reset() { *x = Range{} mi := &file_stats_proto_msgTypes[2] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } func (x *Range) String() string { return protoimpl.X.MessageStringOf(x) } func (*Range) ProtoMessage() {} func (x *Range) ProtoReflect() protoreflect.Message { mi := &file_stats_proto_msgTypes[2] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) } return ms } return mi.MessageOf(x) } // Deprecated: Use Range.ProtoReflect.Descriptor instead. func (*Range) Descriptor() ([]byte, []int) { return file_stats_proto_rawDescGZIP(), []int{2} } func (x *Range) GetNode() string { if x != nil { return x.Node } return "" } func (x *Range) GetSince() string { if x != nil { return x.Since } return "" } func (x *Range) GetUntil() string { if x != nil { return x.Until } return "" } type Histogram struct { state protoimpl.MessageState `protogen:"open.v1"` Buckets []*Bucket `protobuf:"bytes,1,rep,name=buckets,proto3" json:"buckets,omitempty"` unknownFields protoimpl.UnknownFields sizeCache protoimpl.SizeCache } func (x *Histogram) Reset() { *x = Histogram{} mi := &file_stats_proto_msgTypes[3] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } func (x *Histogram) String() string { return protoimpl.X.MessageStringOf(x) } func (*Histogram) ProtoMessage() {} func (x *Histogram) ProtoReflect() protoreflect.Message { mi := &file_stats_proto_msgTypes[3] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) } return ms } return mi.MessageOf(x) } // Deprecated: Use Histogram.ProtoReflect.Descriptor instead. func (*Histogram) Descriptor() ([]byte, []int) { return file_stats_proto_rawDescGZIP(), []int{3} } func (x *Histogram) GetBuckets() []*Bucket { if x != nil { return x.Buckets } return nil } type Bucket struct { state protoimpl.MessageState `protogen:"open.v1"` UpperMs float64 `protobuf:"fixed64,1,opt,name=upper_ms,json=upperMs,proto3" json:"upper_ms,omitempty"` Count int64 `protobuf:"varint,2,opt,name=count,proto3" json:"count,omitempty"` unknownFields protoimpl.UnknownFields sizeCache protoimpl.SizeCache } func (x *Bucket) Reset() { *x = Bucket{} mi := &file_stats_proto_msgTypes[4] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } func (x *Bucket) String() string { return protoimpl.X.MessageStringOf(x) } func (*Bucket) ProtoMessage() {} func (x *Bucket) ProtoReflect() protoreflect.Message { mi := &file_stats_proto_msgTypes[4] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) } return ms } return mi.MessageOf(x) } // Deprecated: Use Bucket.ProtoReflect.Descriptor instead. func (*Bucket) Descriptor() ([]byte, []int) { return file_stats_proto_rawDescGZIP(), []int{4} } func (x *Bucket) GetUpperMs() float64 { if x != nil { return x.UpperMs } return 0 } func (x *Bucket) GetCount() int64 { if x != nil { return x.Count } return 0 } type Frame struct { state protoimpl.MessageState `protogen:"open.v1"` Kind Frame_Kind `protobuf:"varint,1,opt,name=kind,proto3,enum=stats.v1.Frame_Kind" json:"kind,omitempty"` Target string `protobuf:"bytes,2,opt,name=target,proto3" json:"target,omitempty"` // "ip:port" — only used in HELLO Payload []byte `protobuf:"bytes,3,opt,name=payload,proto3" json:"payload,omitempty"` // raw TCP bytes Padding []byte `protobuf:"bytes,4,opt,name=padding,proto3" json:"padding,omitempty"` // random padding для frame-length obfuscation unknownFields protoimpl.UnknownFields sizeCache protoimpl.SizeCache } func (x *Frame) Reset() { *x = Frame{} mi := &file_stats_proto_msgTypes[5] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } func (x *Frame) String() string { return protoimpl.X.MessageStringOf(x) } func (*Frame) ProtoMessage() {} func (x *Frame) ProtoReflect() protoreflect.Message { mi := &file_stats_proto_msgTypes[5] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) } return ms } return mi.MessageOf(x) } // Deprecated: Use Frame.ProtoReflect.Descriptor instead. func (*Frame) Descriptor() ([]byte, []int) { return file_stats_proto_rawDescGZIP(), []int{5} } func (x *Frame) GetKind() Frame_Kind { if x != nil { return x.Kind } return Frame_UNKNOWN } func (x *Frame) GetTarget() string { if x != nil { return x.Target } return "" } func (x *Frame) GetPayload() []byte { if x != nil { return x.Payload } return nil } func (x *Frame) GetPadding() []byte { if x != nil { return x.Padding } return nil } type RecordSpeedTestRequest struct { state protoimpl.MessageState `protogen:"open.v1"` // Unix epoch seconds. Required. Timestamp int64 `protobuf:"varint,1,opt,name=timestamp,proto3" json:"timestamp,omitempty"` // Node identifier: "fl" or "pl1". Required. Node string `protobuf:"bytes,2,opt,name=node,proto3" json:"node,omitempty"` // ISO-2 country code resolved from client IP at the edge node. "XX" if unknown. Country string `protobuf:"bytes,3,opt,name=country,proto3" json:"country,omitempty"` // Mbps. >= 0. DlMbps float64 `protobuf:"fixed64,4,opt,name=dl_mbps,json=dlMbps,proto3" json:"dl_mbps,omitempty"` // Mbps. >= 0. UlMbps float64 `protobuf:"fixed64,5,opt,name=ul_mbps,json=ulMbps,proto3" json:"ul_mbps,omitempty"` // Milliseconds. >= 0. PingMs float64 `protobuf:"fixed64,6,opt,name=ping_ms,json=pingMs,proto3" json:"ping_ms,omitempty"` // Milliseconds. >= 0. JitterMs float64 `protobuf:"fixed64,7,opt,name=jitter_ms,json=jitterMs,proto3" json:"jitter_ms,omitempty"` unknownFields protoimpl.UnknownFields sizeCache protoimpl.SizeCache } func (x *RecordSpeedTestRequest) Reset() { *x = RecordSpeedTestRequest{} mi := &file_stats_proto_msgTypes[6] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } func (x *RecordSpeedTestRequest) String() string { return protoimpl.X.MessageStringOf(x) } func (*RecordSpeedTestRequest) ProtoMessage() {} func (x *RecordSpeedTestRequest) ProtoReflect() protoreflect.Message { mi := &file_stats_proto_msgTypes[6] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) } return ms } return mi.MessageOf(x) } // Deprecated: Use RecordSpeedTestRequest.ProtoReflect.Descriptor instead. func (*RecordSpeedTestRequest) Descriptor() ([]byte, []int) { return file_stats_proto_rawDescGZIP(), []int{6} } func (x *RecordSpeedTestRequest) GetTimestamp() int64 { if x != nil { return x.Timestamp } return 0 } func (x *RecordSpeedTestRequest) GetNode() string { if x != nil { return x.Node } return "" } func (x *RecordSpeedTestRequest) GetCountry() string { if x != nil { return x.Country } return "" } func (x *RecordSpeedTestRequest) GetDlMbps() float64 { if x != nil { return x.DlMbps } return 0 } func (x *RecordSpeedTestRequest) GetUlMbps() float64 { if x != nil { return x.UlMbps } return 0 } func (x *RecordSpeedTestRequest) GetPingMs() float64 { if x != nil { return x.PingMs } return 0 } func (x *RecordSpeedTestRequest) GetJitterMs() float64 { if x != nil { return x.JitterMs } return 0 } type RecordSpeedTestResponse struct { state protoimpl.MessageState `protogen:"open.v1"` // Server-assigned monotonic ID for the inserted row. Id int64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"` unknownFields protoimpl.UnknownFields sizeCache protoimpl.SizeCache } func (x *RecordSpeedTestResponse) Reset() { *x = RecordSpeedTestResponse{} mi := &file_stats_proto_msgTypes[7] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } func (x *RecordSpeedTestResponse) String() string { return protoimpl.X.MessageStringOf(x) } func (*RecordSpeedTestResponse) ProtoMessage() {} func (x *RecordSpeedTestResponse) ProtoReflect() protoreflect.Message { mi := &file_stats_proto_msgTypes[7] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) } return ms } return mi.MessageOf(x) } // Deprecated: Use RecordSpeedTestResponse.ProtoReflect.Descriptor instead. func (*RecordSpeedTestResponse) Descriptor() ([]byte, []int) { return file_stats_proto_rawDescGZIP(), []int{7} } func (x *RecordSpeedTestResponse) GetId() int64 { if x != nil { return x.Id } return 0 } var File_stats_proto protoreflect.FileDescriptor const file_stats_proto_rawDesc = "" + "\n" + "\vstats.proto\x12\bstats.v1\"H\n" + "\x06Filter\x12\x12\n" + "\x04node\x18\x01 \x01(\tR\x04node\x12\x14\n" + "\x05limit\x18\x02 \x01(\x05R\x05limit\x12\x14\n" + "\x05since\x18\x03 \x01(\tR\x05since\"\xf9\x01\n" + "\x06Sample\x12\x12\n" + "\x04node\x18\x01 \x01(\tR\x04node\x12\x1c\n" + "\ttimestamp\x18\x02 \x01(\tR\ttimestamp\x12&\n" + "\x0fhttp_latency_ms\x18\x03 \x01(\x01R\rhttpLatencyMs\x12\x1c\n" + "\n" + "tcp_rtt_ms\x18\x04 \x01(\x01R\btcpRttMs\x12$\n" + "\x0edns_resolve_ms\x18\x05 \x01(\x01R\fdnsResolveMs\x12(\n" + "\x10tls_handshake_ms\x18\x06 \x01(\x01R\x0etlsHandshakeMs\x12'\n" + "\x0fthroughput_kbps\x18\a \x01(\x03R\x0ethroughputKbps\"G\n" + "\x05Range\x12\x12\n" + "\x04node\x18\x01 \x01(\tR\x04node\x12\x14\n" + "\x05since\x18\x02 \x01(\tR\x05since\x12\x14\n" + "\x05until\x18\x03 \x01(\tR\x05until\"7\n" + "\tHistogram\x12*\n" + "\abuckets\x18\x01 \x03(\v2\x10.stats.v1.BucketR\abuckets\"9\n" + "\x06Bucket\x12\x19\n" + "\bupper_ms\x18\x01 \x01(\x01R\aupperMs\x12\x14\n" + "\x05count\x18\x02 \x01(\x03R\x05count\"\xb2\x01\n" + "\x05Frame\x12(\n" + "\x04kind\x18\x01 \x01(\x0e2\x14.stats.v1.Frame.KindR\x04kind\x12\x16\n" + "\x06target\x18\x02 \x01(\tR\x06target\x12\x18\n" + "\apayload\x18\x03 \x01(\fR\apayload\x12\x18\n" + "\apadding\x18\x04 \x01(\fR\apadding\"3\n" + "\x04Kind\x12\v\n" + "\aUNKNOWN\x10\x00\x12\t\n" + "\x05HELLO\x10\x01\x12\b\n" + "\x04DATA\x10\x02\x12\t\n" + "\x05CLOSE\x10\x03\"\xcc\x01\n" + "\x16RecordSpeedTestRequest\x12\x1c\n" + "\ttimestamp\x18\x01 \x01(\x03R\ttimestamp\x12\x12\n" + "\x04node\x18\x02 \x01(\tR\x04node\x12\x18\n" + "\acountry\x18\x03 \x01(\tR\acountry\x12\x17\n" + "\adl_mbps\x18\x04 \x01(\x01R\x06dlMbps\x12\x17\n" + "\aul_mbps\x18\x05 \x01(\x01R\x06ulMbps\x12\x17\n" + "\aping_ms\x18\x06 \x01(\x01R\x06pingMs\x12\x1b\n" + "\tjitter_ms\x18\a \x01(\x01R\bjitterMs\")\n" + "\x17RecordSpeedTestResponse\x12\x0e\n" + "\x02id\x18\x01 \x01(\x03R\x02id2\xff\x01\n" + "\vSpeedStatus\x125\n" + "\rRecentResults\x12\x10.stats.v1.Filter\x1a\x10.stats.v1.Sample0\x01\x121\n" + "\tAggregate\x12\x0f.stats.v1.Range\x1a\x13.stats.v1.Histogram\x12.\n" + "\x06Tunnel\x12\x0f.stats.v1.Frame\x1a\x0f.stats.v1.Frame(\x010\x01\x12V\n" + "\x0fRecordSpeedTest\x12 .stats.v1.RecordSpeedTestRequest\x1a!.stats.v1.RecordSpeedTestResponseB9Z7github.com/bergabruh/stats-gateway/gen/stats/v1;statsv1b\x06proto3" var ( file_stats_proto_rawDescOnce sync.Once file_stats_proto_rawDescData []byte ) func file_stats_proto_rawDescGZIP() []byte { file_stats_proto_rawDescOnce.Do(func() { file_stats_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_stats_proto_rawDesc), len(file_stats_proto_rawDesc))) }) return file_stats_proto_rawDescData } var file_stats_proto_enumTypes = make([]protoimpl.EnumInfo, 1) var file_stats_proto_msgTypes = make([]protoimpl.MessageInfo, 8) var file_stats_proto_goTypes = []any{ (Frame_Kind)(0), // 0: stats.v1.Frame.Kind (*Filter)(nil), // 1: stats.v1.Filter (*Sample)(nil), // 2: stats.v1.Sample (*Range)(nil), // 3: stats.v1.Range (*Histogram)(nil), // 4: stats.v1.Histogram (*Bucket)(nil), // 5: stats.v1.Bucket (*Frame)(nil), // 6: stats.v1.Frame (*RecordSpeedTestRequest)(nil), // 7: stats.v1.RecordSpeedTestRequest (*RecordSpeedTestResponse)(nil), // 8: stats.v1.RecordSpeedTestResponse } var file_stats_proto_depIdxs = []int32{ 5, // 0: stats.v1.Histogram.buckets:type_name -> stats.v1.Bucket 0, // 1: stats.v1.Frame.kind:type_name -> stats.v1.Frame.Kind 1, // 2: stats.v1.SpeedStatus.RecentResults:input_type -> stats.v1.Filter 3, // 3: stats.v1.SpeedStatus.Aggregate:input_type -> stats.v1.Range 6, // 4: stats.v1.SpeedStatus.Tunnel:input_type -> stats.v1.Frame 7, // 5: stats.v1.SpeedStatus.RecordSpeedTest:input_type -> stats.v1.RecordSpeedTestRequest 2, // 6: stats.v1.SpeedStatus.RecentResults:output_type -> stats.v1.Sample 4, // 7: stats.v1.SpeedStatus.Aggregate:output_type -> stats.v1.Histogram 6, // 8: stats.v1.SpeedStatus.Tunnel:output_type -> stats.v1.Frame 8, // 9: stats.v1.SpeedStatus.RecordSpeedTest:output_type -> stats.v1.RecordSpeedTestResponse 6, // [6:10] is the sub-list for method output_type 2, // [2:6] is the sub-list for method input_type 2, // [2:2] is the sub-list for extension type_name 2, // [2:2] is the sub-list for extension extendee 0, // [0:2] is the sub-list for field type_name } func init() { file_stats_proto_init() } func file_stats_proto_init() { if File_stats_proto != nil { return } type x struct{} out := protoimpl.TypeBuilder{ File: protoimpl.DescBuilder{ GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: unsafe.Slice(unsafe.StringData(file_stats_proto_rawDesc), len(file_stats_proto_rawDesc)), NumEnums: 1, NumMessages: 8, NumExtensions: 0, NumServices: 1, }, GoTypes: file_stats_proto_goTypes, DependencyIndexes: file_stats_proto_depIdxs, EnumInfos: file_stats_proto_enumTypes, MessageInfos: file_stats_proto_msgTypes, }.Build() File_stats_proto = out.File file_stats_proto_goTypes = nil file_stats_proto_depIdxs = nil }