All Products
Search
Document Center

PolarDB:AddPolarFsQuota

Last Updated:Jun 10, 2026

Menambahkan aturan kuota direktori baru ke instans Polarlakebase.

Deskripsi operasi

Request description

  • This operation adds a new path policy—a directory quota rule—to a specified Polarlakebase instance.

  • The Quotas parameter is a list. Each element represents a new quota rule. You can add up to 11 rules in a single request.

  • Each rule must include the Name and Include fields. Other fields, such as Description and Exclude, are optional.

  • To define the quota limit, specify at least one of the following parameters: SizeLimit, FileCountLimit, AccessTTL, or ChangeTTL.

  • The Priority field specifies the rule priority. A larger value indicates higher priority. The default value is 0.

  • The Enabled field determines whether the rule takes effect immediately. The default value is true.

Coba sekarang

Coba API ini di OpenAPI Explorer tanpa perlu penandatanganan manual. Panggilan yang berhasil akan secara otomatis menghasilkan contoh kode SDK sesuai dengan parameter Anda. Unduh kode tersebut dengan kredensial bawaan yang aman untuk penggunaan lokal.

Test

RAM authorization

Tabel berikut menjelaskan otorisasi yang diperlukan untuk memanggil API ini. Anda dapat menentukannya dalam kebijakan Resource Access Management (RAM). Kolom pada tabel dijelaskan sebagai berikut:

  • Action: Aksi yang dapat digunakan dalam elemen Action pada pernyataan kebijakan izin RAM untuk memberikan izin guna melakukan operasi tersebut.

  • API: API yang dapat Anda panggil untuk melakukan aksi tersebut.

  • Access level: Tingkat akses yang telah ditentukan untuk setiap API. Nilai yang valid: create, list, get, update, dan delete.

  • Resource type: Jenis resource yang mendukung otorisasi untuk melakukan aksi tersebut. Ini menunjukkan apakah aksi tersebut mendukung izin tingkat resource. Resource yang ditentukan harus kompatibel dengan aksi tersebut. Jika tidak, kebijakan tersebut tidak akan berlaku.

    • Untuk API dengan izin tingkat resource, jenis resource yang diperlukan ditandai dengan tanda bintang (*). Tentukan Nama Sumber Daya Alibaba Cloud (ARN) yang sesuai dalam elemen Resource pada kebijakan.

    • Untuk API tanpa izin tingkat resource, ditampilkan sebagai All Resources. Gunakan tanda bintang (*) dalam elemen Resource pada kebijakan.

  • Condition key: Kunci kondisi yang didefinisikan oleh layanan. Kunci ini memungkinkan kontrol granular, berlaku baik hanya untuk aksi maupun untuk aksi yang terkait dengan resource tertentu. Selain kunci kondisi spesifik layanan, Alibaba Cloud menyediakan serangkaian common condition keys yang berlaku di semua layanan yang didukung RAM.

  • Dependent action: Aksi dependen yang diperlukan untuk menjalankan aksi tersebut. Untuk menyelesaikan aksi tersebut, pengguna RAM atau role RAM harus memiliki izin untuk melakukan semua aksi dependen.

Action

Access level

Resource type

Condition key

Dependent action

polardb:AddPolarFsQuota

none

*全部资源

*

None None

Sintaks permintaan

POST  HTTP/1.1

Parameter permintaan

Parameter

Type

Required

Description

Example

PolarFsInstanceId

string

Yes

ID instans Polarlakebase.

pfs-2ze0i74ka607*****

Quotas

array<object>

Yes

Detail aturan Kuota.

object

No

The details of the quota.

Name

string

Yes

The name of the rule.

rule1

Description

string

No

The description of the resource quota.

quota_policy

Include

string

Yes

The wildcard pattern to match paths.

  • A path pattern that starts with a forward slash (/). Supports glob syntax, including *, ?, and **.

/b/*project*

Exclude

string

No

The rule to exclude specific paths from matching.

  • A path pattern that starts with a forward slash (/). Supports glob syntax, including *, ?, and **.

/a/*project*

SizeLimit

integer

No

The total size limit for files in the directory. Unit: GB.

  • Note: The value must be at least 1 GB.

1

FileCountLimit

integer

No

The limit on the number of files for a user in the directory.

222

AccessTTL

integer

No

The time to live (TTL) for the access time. Unit: seconds.

7200

ChangeTTL

integer

No

The TTL for the change time. Unit: seconds.

7200

Priority

integer

No

The priority of the quota rule.

1

Enabled

boolean

No

Specifies whether to enable the rule. Valid values:

  • True: The rule immediately applies to new items. This is the default value.

  • False: The rule does not apply to new items.

True

DBClusterId

string

No

ID instans PolarDB Basis Data Relasional Cloud-Native tempat aplikasi bergantung.

pc-**************

Elemen respons

Element

Type

Description

Example

object

Schema of Response

RequestId

string

The ID of the request.

7F2007D3-7E74-4ECB-89A8-BF130D******

PolarFsInstanceId

string

The ID of the Polarlakebase instance.

pfs-2ze0i74ka607*****

Contoh

Respons sukses

JSONformat

{
  "RequestId": "7F2007D3-7E74-4ECB-89A8-BF130D******",
  "PolarFsInstanceId": "pfs-2ze0i74ka607*****"
}

Kode kesalahan

Lihat Error Codes untuk daftar lengkap.

Catatan rilis

Lihat Release Notes untuk daftar lengkap.