Skip to content

监控指标读取已弃用的 BucketQuota.Quota 字段导致 Quota 指标无值 #106

Description

@mumu-lab

问题描述

在监控/指标采集代码中,Bucket Quota 指标仍然在读取 BucketQuota 中已废弃的 Quota 字段,而不是当前生效的 Size 字段,导致采集到的配额指标为空或为 0。影响metrics-v2.gometrics-v3.go的quota指标值

代码背景

依赖github.com/minio/madmin-go/v3BucketQuota 结构体中明确标注 Quota 已于 2023 年 8 月弃用:

type BucketQuota struct {
    Quota    uint64    `json:"quota"`    // Deprecated Aug 2023
    Size     uint64    `json:"size"`     // Indicates maximum size allowed per bucket
    Rate     uint64    `json:"rate"`     // Indicates bandwidth rate allocated per bucket
    Requests uint64    `json:"requests"` // Indicates number of requests allocated per bucket
    Type     QuotaType `json:"quotatype,omitempty"`
}

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    • Status
      Backlog

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions