-
Notifications
You must be signed in to change notification settings - Fork 2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Support Quota metrics #6
Conversation
run e2e test |
e2e pass |
|
||
var wg sync.WaitGroup | ||
wg.Add(2) | ||
go func() { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
if so, MaxPowerScaleConnections actually is not 10 ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
if so, MaxPowerScaleConnections actually is not 10 ?
It has nothing to do with the connection. It works like a CountDownLatch for 2 threads: volume level & cluster level
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Per the discussion, we don't interact with PowerScale array in gatherVolumeQuotaMetrics
and gatherClusterQuotaMetrics
, and sem := make(chan struct{}, s.MaxPowerScaleConnections)
in the two classes can be used to control the concurrency of goroutine. IMO it is okay to leave it there.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@P-Cao @baoy1
Still considering,
if getting all quota info for all cluster firstly, it will cost most time, and in gatherVolumeQuotaMetrics and gatherClusterQuotaMetrics, the 20 goroutine cost less; So considering maybe getting quota for one cluster as one cycle is better and is more controllable, not getting all clusters quota then dealing them?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@P-Cao @baoy1 Still considering, if getting all quota info for all cluster firstly, it will cost most time, and in gatherVolumeQuotaMetrics and gatherClusterQuotaMetrics, the 20 goroutine cost less; So considering maybe getting quota for one cluster as one cycle is better and is more controllable, not getting all clusters quota then dealing them?
Maybe improve this later as an independent ticket. This improvement requires the modification of export-push-gather structure.
5937713
to
b7217c7
Compare
run e2e test |
internal/service/service.go
Outdated
@@ -28,12 +28,14 @@ const ( | |||
DefaultMaxPowerScaleConnections = 10 | |||
// ExpectedVolumeHandleProperties is the number of properties that the VolumeHandle contains | |||
ExpectedVolumeHandleProperties = 4 | |||
// VolumeQuotaType is the type of Quota corresponding to a volume | |||
VolumeQuotaType = "directory" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
VolumeQuotaType
looks generic. The field name should be specific to "directory".
b7217c7
to
292be03
Compare
run e2e test |
internal/service/types.go
Outdated
@@ -26,6 +26,11 @@ type VolumeMeta struct { | |||
NameSpace string | |||
} | |||
|
|||
// ClusterMeta is the details of a volume in an SDC |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
SDC?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fixed
292be03
to
db256f0
Compare
run e2e test |
db256f0
to
f3190e2
Compare
Volume Metric labels are updated |
run e2e test |
- Implement quota metrics powerscale_volume_hard_quota_remaining_gigabytes powerscale_volume_quota_subscribed_gigabytes powerscale_volume_hard_quota_remaining_percentage powerscale_volume_quota_subscribed_percentage powerscale_directory_total_hard_quota_gigabytes powerscale_directory_total_hard_quota_percentage
f3190e2
to
ebabfbf
Compare
run e2e test |
Description
powerscale_volume_hard_quota_remaining_gigabytes
powerscale_volume_quota_subscribed_gigabytes
powerscale_volume_hard_quota_remaining_percentage
powerscale_volume_quota_subscribed_percentage
powerscale_directory_total_hard_quota_gigabytes
powerscale_directory_total_hard_quota_percentage
GitHub Issues
Checklist:
How Has This Been Tested?
make check test
Volume metrics:
Directory metrics:
Manual inspection of the GUI
I have verified that the dashboards show the data properly while generating I/O and storage resources