| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258 |
- // Code generated by protoc-gen-go. DO NOT EDIT.
- // versions:
- // protoc-gen-go v1.36.9
- // protoc v6.32.1
- // source: kubemodel/container.proto
- package kubemodel
- import (
- 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"
- 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)
- )
- // Container represents a container within a pod (allocated resource)
- type Container struct {
- state protoimpl.MessageState `protogen:"open.v1"`
- // Identification
- PodID string `protobuf:"bytes,1,opt,name=podID,proto3" json:"podID,omitempty"`
- // Properties
- Name string `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty"`
- // Resource lifecycle (only when different from cluster window)
- CreationTime *timestamppb.Timestamp `protobuf:"bytes,3,opt,name=creationTime,proto3,oneof" json:"creationTime,omitempty"`
- DeletionTime *timestamppb.Timestamp `protobuf:"bytes,4,opt,name=deletionTime,proto3,oneof" json:"deletionTime,omitempty"`
- // Usage metrics
- // CPU usage in core-hours
- CpuCoreHours float32 `protobuf:"fixed32,5,opt,name=cpuCoreHours,proto3" json:"cpuCoreHours,omitempty"`
- // CPU request average in cores
- CpuCoreRequestAverage float32 `protobuf:"fixed32,6,opt,name=cpuCoreRequestAverage,proto3" json:"cpuCoreRequestAverage,omitempty"`
- // CPU usage average in cores
- CpuCoreUsageAverage float32 `protobuf:"fixed32,7,opt,name=cpuCoreUsageAverage,proto3" json:"cpuCoreUsageAverage,omitempty"`
- // CPU usage max in cores
- CpuCoreUsageMax float32 `protobuf:"fixed32,8,opt,name=cpuCoreUsageMax,proto3" json:"cpuCoreUsageMax,omitempty"`
- // RAM usage in byte-hours
- RamByteHours int64 `protobuf:"varint,9,opt,name=ramByteHours,proto3" json:"ramByteHours,omitempty"`
- // RAM request average in bytes
- RamBytesRequestAverage int64 `protobuf:"varint,10,opt,name=ramBytesRequestAverage,proto3" json:"ramBytesRequestAverage,omitempty"`
- // RAM usage average in bytes
- RamBytesUsageAverage int64 `protobuf:"varint,11,opt,name=ramBytesUsageAverage,proto3" json:"ramBytesUsageAverage,omitempty"`
- // RAM usage max in bytes
- RamBytesUsageMax int64 `protobuf:"varint,12,opt,name=ramBytesUsageMax,proto3" json:"ramBytesUsageMax,omitempty"`
- // Diagnostic information about this resource
- Diagnostic *DiagnosticResult `protobuf:"bytes,99,opt,name=diagnostic,proto3,oneof" json:"diagnostic,omitempty"`
- unknownFields protoimpl.UnknownFields
- sizeCache protoimpl.SizeCache
- }
- func (x *Container) Reset() {
- *x = Container{}
- mi := &file_kubemodel_container_proto_msgTypes[0]
- ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
- ms.StoreMessageInfo(mi)
- }
- func (x *Container) String() string {
- return protoimpl.X.MessageStringOf(x)
- }
- func (*Container) ProtoMessage() {}
- func (x *Container) ProtoReflect() protoreflect.Message {
- mi := &file_kubemodel_container_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 Container.ProtoReflect.Descriptor instead.
- func (*Container) Descriptor() ([]byte, []int) {
- return file_kubemodel_container_proto_rawDescGZIP(), []int{0}
- }
- func (x *Container) GetPodID() string {
- if x != nil {
- return x.PodID
- }
- return ""
- }
- func (x *Container) GetName() string {
- if x != nil {
- return x.Name
- }
- return ""
- }
- func (x *Container) GetCreationTime() *timestamppb.Timestamp {
- if x != nil {
- return x.CreationTime
- }
- return nil
- }
- func (x *Container) GetDeletionTime() *timestamppb.Timestamp {
- if x != nil {
- return x.DeletionTime
- }
- return nil
- }
- func (x *Container) GetCpuCoreHours() float32 {
- if x != nil {
- return x.CpuCoreHours
- }
- return 0
- }
- func (x *Container) GetCpuCoreRequestAverage() float32 {
- if x != nil {
- return x.CpuCoreRequestAverage
- }
- return 0
- }
- func (x *Container) GetCpuCoreUsageAverage() float32 {
- if x != nil {
- return x.CpuCoreUsageAverage
- }
- return 0
- }
- func (x *Container) GetCpuCoreUsageMax() float32 {
- if x != nil {
- return x.CpuCoreUsageMax
- }
- return 0
- }
- func (x *Container) GetRamByteHours() int64 {
- if x != nil {
- return x.RamByteHours
- }
- return 0
- }
- func (x *Container) GetRamBytesRequestAverage() int64 {
- if x != nil {
- return x.RamBytesRequestAverage
- }
- return 0
- }
- func (x *Container) GetRamBytesUsageAverage() int64 {
- if x != nil {
- return x.RamBytesUsageAverage
- }
- return 0
- }
- func (x *Container) GetRamBytesUsageMax() int64 {
- if x != nil {
- return x.RamBytesUsageMax
- }
- return 0
- }
- func (x *Container) GetDiagnostic() *DiagnosticResult {
- if x != nil {
- return x.Diagnostic
- }
- return nil
- }
- var File_kubemodel_container_proto protoreflect.FileDescriptor
- const file_kubemodel_container_proto_rawDesc = "" +
- "\n" +
- "\x19kubemodel/container.proto\x12\tkubemodel\x1a\x1akubemodel/diagnostic.proto\x1a\x1fgoogle/protobuf/timestamp.proto\"\xa4\x05\n" +
- "\tContainer\x12\x14\n" +
- "\x05podID\x18\x01 \x01(\tR\x05podID\x12\x12\n" +
- "\x04name\x18\x02 \x01(\tR\x04name\x12C\n" +
- "\fcreationTime\x18\x03 \x01(\v2\x1a.google.protobuf.TimestampH\x00R\fcreationTime\x88\x01\x01\x12C\n" +
- "\fdeletionTime\x18\x04 \x01(\v2\x1a.google.protobuf.TimestampH\x01R\fdeletionTime\x88\x01\x01\x12\"\n" +
- "\fcpuCoreHours\x18\x05 \x01(\x02R\fcpuCoreHours\x124\n" +
- "\x15cpuCoreRequestAverage\x18\x06 \x01(\x02R\x15cpuCoreRequestAverage\x120\n" +
- "\x13cpuCoreUsageAverage\x18\a \x01(\x02R\x13cpuCoreUsageAverage\x12(\n" +
- "\x0fcpuCoreUsageMax\x18\b \x01(\x02R\x0fcpuCoreUsageMax\x12\"\n" +
- "\framByteHours\x18\t \x01(\x03R\framByteHours\x126\n" +
- "\x16ramBytesRequestAverage\x18\n" +
- " \x01(\x03R\x16ramBytesRequestAverage\x122\n" +
- "\x14ramBytesUsageAverage\x18\v \x01(\x03R\x14ramBytesUsageAverage\x12*\n" +
- "\x10ramBytesUsageMax\x18\f \x01(\x03R\x10ramBytesUsageMax\x12@\n" +
- "\n" +
- "diagnostic\x18c \x01(\v2\x1b.kubemodel.DiagnosticResultH\x02R\n" +
- "diagnostic\x88\x01\x01B\x0f\n" +
- "\r_creationTimeB\x0f\n" +
- "\r_deletionTimeB\r\n" +
- "\v_diagnosticB:Z8github.com/opencost/opencost/core/pkg/model/pb/kubemodelb\x06proto3"
- var (
- file_kubemodel_container_proto_rawDescOnce sync.Once
- file_kubemodel_container_proto_rawDescData []byte
- )
- func file_kubemodel_container_proto_rawDescGZIP() []byte {
- file_kubemodel_container_proto_rawDescOnce.Do(func() {
- file_kubemodel_container_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_kubemodel_container_proto_rawDesc), len(file_kubemodel_container_proto_rawDesc)))
- })
- return file_kubemodel_container_proto_rawDescData
- }
- var file_kubemodel_container_proto_msgTypes = make([]protoimpl.MessageInfo, 1)
- var file_kubemodel_container_proto_goTypes = []any{
- (*Container)(nil), // 0: kubemodel.Container
- (*timestamppb.Timestamp)(nil), // 1: google.protobuf.Timestamp
- (*DiagnosticResult)(nil), // 2: kubemodel.DiagnosticResult
- }
- var file_kubemodel_container_proto_depIdxs = []int32{
- 1, // 0: kubemodel.Container.creationTime:type_name -> google.protobuf.Timestamp
- 1, // 1: kubemodel.Container.deletionTime:type_name -> google.protobuf.Timestamp
- 2, // 2: kubemodel.Container.diagnostic:type_name -> kubemodel.DiagnosticResult
- 3, // [3:3] is the sub-list for method output_type
- 3, // [3:3] is the sub-list for method input_type
- 3, // [3:3] is the sub-list for extension type_name
- 3, // [3:3] is the sub-list for extension extendee
- 0, // [0:3] is the sub-list for field type_name
- }
- func init() { file_kubemodel_container_proto_init() }
- func file_kubemodel_container_proto_init() {
- if File_kubemodel_container_proto != nil {
- return
- }
- file_kubemodel_diagnostic_proto_init()
- file_kubemodel_container_proto_msgTypes[0].OneofWrappers = []any{}
- type x struct{}
- out := protoimpl.TypeBuilder{
- File: protoimpl.DescBuilder{
- GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
- RawDescriptor: unsafe.Slice(unsafe.StringData(file_kubemodel_container_proto_rawDesc), len(file_kubemodel_container_proto_rawDesc)),
- NumEnums: 0,
- NumMessages: 1,
- NumExtensions: 0,
- NumServices: 0,
- },
- GoTypes: file_kubemodel_container_proto_goTypes,
- DependencyIndexes: file_kubemodel_container_proto_depIdxs,
- MessageInfos: file_kubemodel_container_proto_msgTypes,
- }.Build()
- File_kubemodel_container_proto = out.File
- file_kubemodel_container_proto_goTypes = nil
- file_kubemodel_container_proto_depIdxs = nil
- }
|