Skip to content

Commit

Permalink
koordlet: support blkio-cost user cost model configuration (#1942)
Browse files Browse the repository at this point in the history
Signed-off-by: Wang Xiaoqiang <wangxiaoqiang@qiyi.com>
  • Loading branch information
wangxiaoq committed Mar 13, 2024
1 parent 9184517 commit 42bca6f
Show file tree
Hide file tree
Showing 8 changed files with 316 additions and 8 deletions.
21 changes: 21 additions & 0 deletions apis/slo/v1alpha1/nodeslo_types.go
Original file line number Diff line number Diff line change
Expand Up @@ -199,6 +199,27 @@ type IOCfg struct {
// +kubebuilder:validation:Maximum=100
// +kubebuilder:validation:Minimum=0
WriteLatencyPercent *int64 `json:"writeLatencyPercent,omitempty"`
// configure the cost model of blkio-cost manually
// whether the user model is enabled. Default value: false
EnableUserModel *bool `json:"enableUserModel,omitempty"`
// the read BPS of user model
// +kubebuilder:validation:Minimum=1
ModelReadBPS *int64 `json:"modelReadBPS,omitempty"`
// the write BPS of user model
// +kubebuilder:validation:Minimum=1
ModelWriteBPS *int64 `json:"modelWriteBPS,omitempty"`
// the sequential read iops of user model
// +kubebuilder:validation:Minimum=1
ModelReadSeqIOPS *int64 `json:"modelReadSeqIOPS,omitempty"`
// the sequential write iops of user model
// +kubebuilder:validation:Minimum=1
ModelWriteSeqIOPS *int64 `json:"modelWriteSeqIOPS,omitempty"`
// the random read iops of user model
// +kubebuilder:validation:Minimum=1
ModelReadRandIOPS *int64 `json:"modelReadRandIOPS,omitempty"`
// the random write iops of user model
// +kubebuilder:validation:Minimum=1
ModelWriteRandIOPS *int64 `json:"modelWriteRandIOPS,omitempty"`
}

type BlockCfg struct {
Expand Down
35 changes: 35 additions & 0 deletions apis/slo/v1alpha1/zz_generated.deepcopy.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

185 changes: 185 additions & 0 deletions config/crd/bases/slo.koordinator.sh_nodeslos.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -114,6 +114,11 @@ spec:
properties:
ioCfg:
properties:
enableUserModel:
description: 'configure the cost model of blkio-cost
manually whether the user model is enabled.
Default value: false'
type: boolean
ioWeightPercent:
description: 'This field is used to set the
weight of a sub-group. Default value: 100.
Expand All @@ -122,6 +127,38 @@ spec:
maximum: 100
minimum: 1
type: integer
modelReadBPS:
description: the read BPS of user model
format: int64
minimum: 1
type: integer
modelReadRandIOPS:
description: the random read iops of user model
format: int64
minimum: 1
type: integer
modelReadSeqIOPS:
description: the sequential read iops of user
model
format: int64
minimum: 1
type: integer
modelWriteBPS:
description: the write BPS of user model
format: int64
minimum: 1
type: integer
modelWriteRandIOPS:
description: the random write iops of user model
format: int64
minimum: 1
type: integer
modelWriteSeqIOPS:
description: the sequential write iops of user
model
format: int64
minimum: 1
type: integer
readBPS:
description: Throttling of throughput The value
is set to 0, which indicates that the feature
Expand Down Expand Up @@ -404,6 +441,11 @@ spec:
properties:
ioCfg:
properties:
enableUserModel:
description: 'configure the cost model of blkio-cost
manually whether the user model is enabled.
Default value: false'
type: boolean
ioWeightPercent:
description: 'This field is used to set the
weight of a sub-group. Default value: 100.
Expand All @@ -412,6 +454,38 @@ spec:
maximum: 100
minimum: 1
type: integer
modelReadBPS:
description: the read BPS of user model
format: int64
minimum: 1
type: integer
modelReadRandIOPS:
description: the random read iops of user model
format: int64
minimum: 1
type: integer
modelReadSeqIOPS:
description: the sequential read iops of user
model
format: int64
minimum: 1
type: integer
modelWriteBPS:
description: the write BPS of user model
format: int64
minimum: 1
type: integer
modelWriteRandIOPS:
description: the random write iops of user model
format: int64
minimum: 1
type: integer
modelWriteSeqIOPS:
description: the sequential write iops of user
model
format: int64
minimum: 1
type: integer
readBPS:
description: Throttling of throughput The value
is set to 0, which indicates that the feature
Expand Down Expand Up @@ -694,6 +768,11 @@ spec:
properties:
ioCfg:
properties:
enableUserModel:
description: 'configure the cost model of blkio-cost
manually whether the user model is enabled.
Default value: false'
type: boolean
ioWeightPercent:
description: 'This field is used to set the
weight of a sub-group. Default value: 100.
Expand All @@ -702,6 +781,38 @@ spec:
maximum: 100
minimum: 1
type: integer
modelReadBPS:
description: the read BPS of user model
format: int64
minimum: 1
type: integer
modelReadRandIOPS:
description: the random read iops of user model
format: int64
minimum: 1
type: integer
modelReadSeqIOPS:
description: the sequential read iops of user
model
format: int64
minimum: 1
type: integer
modelWriteBPS:
description: the write BPS of user model
format: int64
minimum: 1
type: integer
modelWriteRandIOPS:
description: the random write iops of user model
format: int64
minimum: 1
type: integer
modelWriteSeqIOPS:
description: the sequential write iops of user
model
format: int64
minimum: 1
type: integer
readBPS:
description: Throttling of throughput The value
is set to 0, which indicates that the feature
Expand Down Expand Up @@ -984,6 +1095,11 @@ spec:
properties:
ioCfg:
properties:
enableUserModel:
description: 'configure the cost model of blkio-cost
manually whether the user model is enabled.
Default value: false'
type: boolean
ioWeightPercent:
description: 'This field is used to set the
weight of a sub-group. Default value: 100.
Expand All @@ -992,6 +1108,38 @@ spec:
maximum: 100
minimum: 1
type: integer
modelReadBPS:
description: the read BPS of user model
format: int64
minimum: 1
type: integer
modelReadRandIOPS:
description: the random read iops of user model
format: int64
minimum: 1
type: integer
modelReadSeqIOPS:
description: the sequential read iops of user
model
format: int64
minimum: 1
type: integer
modelWriteBPS:
description: the write BPS of user model
format: int64
minimum: 1
type: integer
modelWriteRandIOPS:
description: the random write iops of user model
format: int64
minimum: 1
type: integer
modelWriteSeqIOPS:
description: the sequential write iops of user
model
format: int64
minimum: 1
type: integer
readBPS:
description: Throttling of throughput The value
is set to 0, which indicates that the feature
Expand Down Expand Up @@ -1284,6 +1432,11 @@ spec:
properties:
ioCfg:
properties:
enableUserModel:
description: 'configure the cost model of blkio-cost
manually whether the user model is enabled.
Default value: false'
type: boolean
ioWeightPercent:
description: 'This field is used to set the
weight of a sub-group. Default value: 100.
Expand All @@ -1292,6 +1445,38 @@ spec:
maximum: 100
minimum: 1
type: integer
modelReadBPS:
description: the read BPS of user model
format: int64
minimum: 1
type: integer
modelReadRandIOPS:
description: the random read iops of user model
format: int64
minimum: 1
type: integer
modelReadSeqIOPS:
description: the sequential read iops of user
model
format: int64
minimum: 1
type: integer
modelWriteBPS:
description: the write BPS of user model
format: int64
minimum: 1
type: integer
modelWriteRandIOPS:
description: the random write iops of user model
format: int64
minimum: 1
type: integer
modelWriteSeqIOPS:
description: the sequential write iops of user
model
format: int64
minimum: 1
type: integer
readBPS:
description: Throttling of throughput The value
is set to 0, which indicates that the feature
Expand Down
Loading

0 comments on commit 42bca6f

Please sign in to comment.