Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Configure ¶
type Configure struct { // CPU使用率限制,100表示1个核心 CPUQuota int64 `json:"cpu_quota" yaml:"cpu_quota" kv:"cpu_quota"` // 内存使用限制 Memory utils.Bytes `json:"memory_limit" yaml:"memory_limit" kv:"memory_limit"` // 磁盘限制 Disks diskLimits `json:"disk_limit" yaml:"disk_limit" kv:"disk_limit"` }
Configure 资源限制配置
type DiskLimit ¶
type DiskLimit struct { // 磁盘设备编号,可使用lsblk进行查询,如: 8:0 Dev string `json:"dev" yaml:"dev" kv:"dev"` // 每秒读取字节数,为0表示不限制 ReadBytes utils.Bytes `json:"read_bytes" yaml:"read_bytes" kv:"read_bytes"` // 每秒写入字节数,为0表示不限制 WriteBytes utils.Bytes `json:"write_bytes" yaml:"write_bytes" kv:"write_bytes"` // 每秒并发读取次数,为0表示不限制 ReadIOPS uint64 `json:"read_iops" yaml:"read_iops" kv:"read_iops"` // 每秒并发写入次数,为0表示不限制 WriteIOPS uint64 `json:"write_iops" yaml:"write_iops" kv:"write_iops"` }
DiskLimit 磁盘限制配置
Click to show internal directories.
Click to hide internal directories.