bot_scaling: Refactor usage message types
Refactor resource message types to make it easier to track global and
region usage. This will introduce a new message type that will allow me
to phase out the current message for one that will support regional
associations. Smarter, not harder.
Bug: chromium:1087113
Change-Id: I79bd68079a6f6752fe49a1b1d4c4049d121ab758
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/infra/proto/+/2220335
Reviewed-by: Dhanya Ganesh <dhanyaganesh@chromium.org>
Reviewed-by: David Burger <dburger@chromium.org>
Commit-Queue: Mike Nichols <mikenichols@chromium.org>
Tested-by: Mike Nichols <mikenichols@chromium.org>
diff --git a/go/chromiumos/bot_scaling.pb.go b/go/chromiumos/bot_scaling.pb.go
index be2d57f..11f19b1 100644
--- a/go/chromiumos/bot_scaling.pb.go
+++ b/go/chromiumos/bot_scaling.pb.go
@@ -730,65 +730,84 @@
return 0
}
-// ResourceUsage for each region that bots are deployed.
-type RegionalResourceUsage struct {
+// Resource utilization based on regional assignment.
+type ResourceUtilization struct {
// Region of the bot sub-group.
Region string `protobuf:"bytes,1,opt,name=region,proto3" json:"region,omitempty"`
- // ResourceUsage message type
- ResourceUsage *ResourceUsage `protobuf:"bytes,2,opt,name=resource_usage,json=resourceUsage,proto3" json:"resource_usage,omitempty"`
- XXX_NoUnkeyedLiteral struct{} `json:"-"`
- XXX_unrecognized []byte `json:"-"`
- XXX_sizecache int32 `json:"-"`
+ // Number of VMs allocated across all bot groups.
+ Vms int32 `protobuf:"varint,2,opt,name=vms,proto3" json:"vms,omitempty"`
+ // Number of CPUs allocated across all bot groups.
+ Cpus float32 `protobuf:"fixed32,3,opt,name=cpus,proto3" json:"cpus,omitempty"`
+ // Amount of memory in GB allocated across all bot groups.
+ MemoryGb float32 `protobuf:"fixed32,4,opt,name=memory_gb,json=memoryGb,proto3" json:"memory_gb,omitempty"`
+ XXX_NoUnkeyedLiteral struct{} `json:"-"`
+ XXX_unrecognized []byte `json:"-"`
+ XXX_sizecache int32 `json:"-"`
}
-func (m *RegionalResourceUsage) Reset() { *m = RegionalResourceUsage{} }
-func (m *RegionalResourceUsage) String() string { return proto.CompactTextString(m) }
-func (*RegionalResourceUsage) ProtoMessage() {}
-func (*RegionalResourceUsage) Descriptor() ([]byte, []int) {
+func (m *ResourceUtilization) Reset() { *m = ResourceUtilization{} }
+func (m *ResourceUtilization) String() string { return proto.CompactTextString(m) }
+func (*ResourceUtilization) ProtoMessage() {}
+func (*ResourceUtilization) Descriptor() ([]byte, []int) {
return fileDescriptor_dbe70eabfd64e7ef, []int{6}
}
-func (m *RegionalResourceUsage) XXX_Unmarshal(b []byte) error {
- return xxx_messageInfo_RegionalResourceUsage.Unmarshal(m, b)
+func (m *ResourceUtilization) XXX_Unmarshal(b []byte) error {
+ return xxx_messageInfo_ResourceUtilization.Unmarshal(m, b)
}
-func (m *RegionalResourceUsage) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
- return xxx_messageInfo_RegionalResourceUsage.Marshal(b, m, deterministic)
+func (m *ResourceUtilization) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
+ return xxx_messageInfo_ResourceUtilization.Marshal(b, m, deterministic)
}
-func (m *RegionalResourceUsage) XXX_Merge(src proto.Message) {
- xxx_messageInfo_RegionalResourceUsage.Merge(m, src)
+func (m *ResourceUtilization) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_ResourceUtilization.Merge(m, src)
}
-func (m *RegionalResourceUsage) XXX_Size() int {
- return xxx_messageInfo_RegionalResourceUsage.Size(m)
+func (m *ResourceUtilization) XXX_Size() int {
+ return xxx_messageInfo_ResourceUtilization.Size(m)
}
-func (m *RegionalResourceUsage) XXX_DiscardUnknown() {
- xxx_messageInfo_RegionalResourceUsage.DiscardUnknown(m)
+func (m *ResourceUtilization) XXX_DiscardUnknown() {
+ xxx_messageInfo_ResourceUtilization.DiscardUnknown(m)
}
-var xxx_messageInfo_RegionalResourceUsage proto.InternalMessageInfo
+var xxx_messageInfo_ResourceUtilization proto.InternalMessageInfo
-func (m *RegionalResourceUsage) GetRegion() string {
+func (m *ResourceUtilization) GetRegion() string {
if m != nil {
return m.Region
}
return ""
}
-func (m *RegionalResourceUsage) GetResourceUsage() *ResourceUsage {
+func (m *ResourceUtilization) GetVms() int32 {
if m != nil {
- return m.ResourceUsage
+ return m.Vms
}
- return nil
+ return 0
+}
+
+func (m *ResourceUtilization) GetCpus() float32 {
+ if m != nil {
+ return m.Cpus
+ }
+ return 0
+}
+
+func (m *ResourceUtilization) GetMemoryGb() float32 {
+ if m != nil {
+ return m.MemoryGb
+ }
+ return 0
}
// All the actions that will be executed by RoboCrop.
type RoboCropAction struct {
// List of an action per bot group scaled by RoboCrop.
- ScalingActions []*ScalingAction `protobuf:"bytes,1,rep,name=scaling_actions,json=scalingActions,proto3" json:"scaling_actions,omitempty"`
- ResourceUsage *ResourceUsage `protobuf:"bytes,2,opt,name=resource_usage,json=resourceUsage,proto3" json:"resource_usage,omitempty"`
- RegionalResourceUsage []*RegionalResourceUsage `protobuf:"bytes,3,rep,name=regional_resource_usage,json=regionalResourceUsage,proto3" json:"regional_resource_usage,omitempty"`
- XXX_NoUnkeyedLiteral struct{} `json:"-"`
- XXX_unrecognized []byte `json:"-"`
- XXX_sizecache int32 `json:"-"`
+ ScalingActions []*ScalingAction `protobuf:"bytes,1,rep,name=scaling_actions,json=scalingActions,proto3" json:"scaling_actions,omitempty"`
+ // To be phased out for ResourceUtilization message type.
+ ResourceUsage *ResourceUsage `protobuf:"bytes,2,opt,name=resource_usage,json=resourceUsage,proto3" json:"resource_usage,omitempty"`
+ ResourceUtilization []*ResourceUtilization `protobuf:"bytes,3,rep,name=resource_utilization,json=resourceUtilization,proto3" json:"resource_utilization,omitempty"`
+ XXX_NoUnkeyedLiteral struct{} `json:"-"`
+ XXX_unrecognized []byte `json:"-"`
+ XXX_sizecache int32 `json:"-"`
}
func (m *RoboCropAction) Reset() { *m = RoboCropAction{} }
@@ -830,9 +849,9 @@
return nil
}
-func (m *RoboCropAction) GetRegionalResourceUsage() []*RegionalResourceUsage {
+func (m *RoboCropAction) GetResourceUtilization() []*ResourceUtilization {
if m != nil {
- return m.RegionalResourceUsage
+ return m.ResourceUtilization
}
return nil
}
@@ -850,74 +869,74 @@
proto.RegisterType((*ScalingAction)(nil), "chromiumos.ScalingAction")
proto.RegisterType((*ScalingAction_RegionalAction)(nil), "chromiumos.ScalingAction.RegionalAction")
proto.RegisterType((*ResourceUsage)(nil), "chromiumos.ResourceUsage")
- proto.RegisterType((*RegionalResourceUsage)(nil), "chromiumos.RegionalResourceUsage")
+ proto.RegisterType((*ResourceUtilization)(nil), "chromiumos.ResourceUtilization")
proto.RegisterType((*RoboCropAction)(nil), "chromiumos.RoboCropAction")
}
func init() { proto.RegisterFile("chromiumos/bot_scaling.proto", fileDescriptor_dbe70eabfd64e7ef) }
var fileDescriptor_dbe70eabfd64e7ef = []byte{
- // 983 bytes of a gzipped FileDescriptorProto
- 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xac, 0x56, 0xed, 0x6e, 0xe3, 0x44,
- 0x17, 0x5e, 0x27, 0x4d, 0xd3, 0x9c, 0x34, 0x69, 0x3a, 0xdd, 0xbe, 0xaf, 0x5b, 0x40, 0x64, 0x2d,
- 0x10, 0x91, 0x90, 0x52, 0xa9, 0x20, 0x40, 0xe2, 0x0f, 0xcd, 0x47, 0xbb, 0x11, 0xd4, 0x89, 0x26,
- 0xad, 0xa0, 0xf0, 0xc3, 0xb2, 0x9d, 0xa9, 0x3b, 0x5a, 0xdb, 0xe3, 0x9d, 0x71, 0xba, 0x74, 0x2f,
- 0x80, 0x3b, 0xe0, 0x32, 0xb8, 0x2b, 0x6e, 0x80, 0x3b, 0x40, 0xf3, 0xe1, 0x36, 0x5f, 0xfd, 0x81,
- 0xe0, 0xdf, 0x9c, 0x67, 0x66, 0x9e, 0x39, 0xe7, 0x39, 0xcf, 0x89, 0x03, 0x1f, 0x86, 0x77, 0x9c,
- 0x25, 0x74, 0x9e, 0x30, 0x71, 0x12, 0xb0, 0xdc, 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 0x36, 0xe7, 0x21, 0xb9, 0x16, 0x7e, 0x24, 0x7d,
- 0x5b, 0xbe, 0x4f, 0x84, 0x99, 0x56, 0xb9, 0x94, 0x5f, 0x8b, 0x30, 0x9b, 0x0b, 0x95, 0x4f, 0x09,
- 0xab, 0xf5, 0xf2, 0x37, 0xa7, 0xbc, 0xf2, 0xcd, 0x79, 0x0b, 0x87, 0x45, 0xb1, 0xcb, 0xdc, 0xcf,
- 0xd5, 0xfc, 0x1d, 0x34, 0xb9, 0x39, 0xe8, 0xcd, 0xe5, 0x49, 0x63, 0xa1, 0xa3, 0xc5, 0xee, 0x2c,
- 0x51, 0xe1, 0x06, 0x5f, 0x0c, 0x9d, 0xbf, 0x2c, 0x68, 0x62, 0x16, 0xb0, 0x3e, 0x67, 0x99, 0x11,
- 0xb8, 0x07, 0x7b, 0xc5, 0xcf, 0x5b, 0xd1, 0x73, 0xed, 0xfe, 0xa3, 0x67, 0x7b, 0x8e, 0x9b, 0x62,
- 0x31, 0x14, 0xff, 0x3e, 0x31, 0x74, 0x03, 0xff, 0x7f, 0xb4, 0xde, 0x0a, 0x55, 0x59, 0x65, 0xf3,
- 0x6a, 0x99, 0x6a, 0x83, 0x6c, 0xf8, 0x90, 0x6f, 0x82, 0x7b, 0x5f, 0xfd, 0xfc, 0x65, 0xc4, 0x1e,
- 0x6f, 0x77, 0x19, 0x8f, 0x4e, 0x16, 0xfe, 0x9f, 0xd0, 0xf4, 0x96, 0xfb, 0x27, 0xea, 0x9f, 0xc9,
- 0x49, 0xc4, 0x16, 0x76, 0x82, 0x6d, 0x05, 0x7e, 0xf1, 0x77, 0x00, 0x00, 0x00, 0xff, 0xff, 0x13,
- 0x77, 0x56, 0x84, 0xce, 0x08, 0x00, 0x00,
+ // 988 bytes of a gzipped FileDescriptorProto
+ 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xac, 0x56, 0xdd, 0x6e, 0x23, 0x35,
+ 0x14, 0xde,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x6e, 0x0b, 0xf1, 0xe6, 0x4a,
+ 0x1d, 0x6b, 0xed, 0x35, 0x8a, 0x35, 0xf9, 0x70, 0x85, 0xaf, 0xa9, 0x89, 0xe1, 0x64, 0xc9, 0xb0,
+ 0xd4, 0x42, 0xbf, 0xa6, 0xe5, 0xf3, 0x57, 0x3b, 0x79, 0x96, 0xdb, 0x70, 0x9d, 0x6f, 0x83, 0x9d,
+ 0xaf, 0x7e, 0xfe, 0x32, 0x64, 0x8b, 0x93, 0x6d, 0xc6, 0xc3, 0xb3, 0x95, 0xff, 0x25, 0x34, 0xb9,
+ 0xe3, 0xfe, 0x99, 0xfe, 0x47, 0x72, 0x16, 0xb2, 0x95, 0x95, 0x60, 0x5f, 0x83, 0x5f, 0xfc, 0x13,
+ 0x00, 0x00, 0xff, 0xff, 0xe8, 0xc0, 0x0c, 0x4d, 0xc6, 0x08, 0x00, 0x00,
}
diff --git a/src/chromiumos/bot_scaling.proto b/src/chromiumos/bot_scaling.proto
index 50249e6..68f7956 100644
--- a/src/chromiumos/bot_scaling.proto
+++ b/src/chromiumos/bot_scaling.proto
@@ -154,18 +154,23 @@
float memory_gb = 3;
}
-// ResourceUsage for each region that bots are deployed.
-message RegionalResourceUsage {
+// Resource utilization based on regional assignment.
+message ResourceUtilization {
// Region of the bot sub-group.
string region = 1;
- // ResourceUsage message type
- ResourceUsage resource_usage = 2;
+ // Number of VMs allocated across all bot groups.
+ int32 vms = 2;
+ // Number of CPUs allocated across all bot groups.
+ float cpus = 3;
+ // Amount of memory in GB allocated across all bot groups.
+ float memory_gb = 4;
}
// All the actions that will be executed by RoboCrop.
message RoboCropAction {
// List of an action per bot group scaled by RoboCrop.
repeated ScalingAction scaling_actions = 1;
+ // To be phased out for ResourceUtilization message type.
ResourceUsage resource_usage = 2;
- repeated RegionalResourceUsage regional_resource_usage = 3;
+ repeated ResourceUtilization resource_utilization = 3;
}
\ No newline at end of file