Sets file quota rules for a specified directory in a Polarlakebase instance.
Operation description
Request description
This operation sets file quota rules for a specific directory in a Polarlakebase instance. By configuring the FilePathQuotas parameter, you can specify the directories to which quota rules are applied and their related attributes. When you use FilePathId to specify a directory, ensure that the path is an absolute path from the root directory rather than a mount point path. You can also use the Strategy parameter to control how rules take effect on existing files. By default, rules take effect only when they are missing.
Notes
The maximum length of the
FilePathQuotaslist is 21.To apply rules to multiple levels of subdirectories under
FilePathId, set theMaxDepthparameter. To traverse to the deepest level, set this value to 0.
Try it now
Test
RAM authorization
|
Action |
Access level |
Resource type |
Condition key |
Dependent action |
|
polardb:SetPolarFsFileQuota |
none |
*All Resource
|
None | None |
Request syntax
POST HTTP/1.1
Request parameters
|
Parameter |
Type |
Required |
Description |
Example |
| PolarFsInstanceId |
string |
Yes |
The Polarlakebase instance ID. |
pfs-2ze0i74ka607***** |
| FilePathQuotas |
array<object> |
Yes |
The details of the quota rules to apply to directories. |
|
|
object |
No |
The details of the directory to which quota rules are applied. |
||
| FilePathId |
string |
No |
The directory path. |
/a/project |
| QuotaIds |
string |
No |
The IDs of the rules to apply, separated by commas (,). |
1,2 |
| Strategy |
string |
No |
The mode in which rules take effect on existing files. Valid values:
|
missing |
| MaxDepth |
integer |
No |
The number of subdirectory levels to traverse under |
1 |
| Capacity |
integer |
No |
The quota capacity. Unit: GB. |
100 |
| Inodes |
integer |
No |
The quota inodes. |
100 |
| DBClusterId |
string |
No |
The cluster ID. |
pc-************** |
Response elements
|
Element |
Type |
Description |
Example |
|
object |
Schema of Response |
||
| RequestId |
string |
Id of the request |
925B84D9-CA72-432C-95CF-738C22****** |
| PolarFsInstanceId |
string |
The Polarlakebase instance ID. |
pfs-2ze0i74ka607***** |
Examples
Success response
JSON format
{
"RequestId": "925B84D9-CA72-432C-95CF-738C22******",
"PolarFsInstanceId": "pfs-2ze0i74ka607*****"
}
Error codes
See Error Codes for a complete list.
Release notes
See Release Notes for a complete list.