Queries storage details of tables in a MaxCompute project.
Try it now
Test
RAM authorization
|
Action |
Access level |
Resource type |
Condition key |
Dependent action |
|
odps:ListStorageTablesInfo |
get |
*Storage
|
None | None |
Request syntax
GET /api/v1/observations/analysis/storage/projects/{project}/tablesInfo HTTP/1.1
Path Parameters
|
Parameter |
Type |
Required |
Description |
Example |
| project |
string |
Yes |
The name of the MaxCompute project. |
odps_project |
Request parameters
|
Parameter |
Type |
Required |
Description |
Example |
| tenantId |
string |
No |
The tenant ID. You can view the tenant ID by logging on to the MaxCompute console and choosing Tenant Management>Tenant Properties in the left-side navigation pane. |
28074710977**** |
| region |
string |
No |
The region ID. |
cn-beijing |
| date |
string |
Yes |
The date for the statistics query, at the daily level. Specify the date in the |
20241205 |
| recentDays |
integer |
No |
The number of days for year-over-year comparison. |
1 |
| schema |
string |
No |
The schema to which the table belongs. |
schema |
| tablePrefix |
string |
No |
The table name for fuzzy matching. |
bank |
| types |
array |
No |
The storage type. |
|
|
string |
No |
The storage type. |
standardStorage |
|
| orderColumn |
string |
No |
The column used for sorting. |
totalFrequency |
| ascOrder |
boolean |
No |
Specifies whether to sort results in ascending order. |
false |
| pageSize |
integer |
No |
The number of entries per page. Default value: 10. |
10 |
| pageNumber |
integer |
No |
The page number. |
1 |
Response elements
|
Element |
Type |
Description |
Example |
|
object |
The response parameters. |
||
| requestId |
string |
The request ID. |
0bc12e6a16679892465424670db3eb |
| httpCode |
integer |
The HTTP status code.
|
200 |
| errorCode |
string |
The error code. |
OBJECT_NOT_EXIST |
| errorMsg |
string |
The error message. |
This object does not exist. |
| data |
object |
The returned data. |
|
| storageTableInfoList |
array<object> |
The list of table storage information. |
|
|
object |
The table storage information. |
||
| date |
string |
The statistics date (not returned). |
20241205 |
| projectName |
string |
The project name. |
odps_project |
| schemaName |
string |
The schema name. |
schema |
| tableName |
string |
The table name. |
bank_data |
| isPartitioned |
boolean |
Indicates whether the table is partitioned. |
false |
| storageType |
string |
The storage type of the table.
|
standard |
| lastAccessTime |
integer |
The last access time of the table data. This value is returned only for non-partitioned tables. Note
The collection of this data has been progressively upgraded since July 2023. The last_access_time cannot be collected for tables that have not been accessed since the upgrade or that are accessed through ALGO jobs or Hologres direct reads. |
1694589365 |
| totalStorageFileCount |
integer |
The total number of files. |
2 |
| totalStorage |
number |
The total storage usage. For partitioned tables, this is the sum of storage usage across all partitions. If partitions have different storage types, the value is the sum of storage usage across all types. |
600 |
| totalStorageUnit |
string |
The unit of storage usage. |
KB |
| rate |
number |
The year-over-year comparison of total storage over the recent {$recentDays} days. |
0 |
| standardStorageFileCount |
integer |
The number of standard storage files. |
2 |
| standardStorage |
number |
The standard storage usage. |
600 |
| standardStorageUnit |
string |
The unit of standard storage usage. |
KB |
| longTermStorageFileCount |
integer |
The number of long-term storage files. |
0 |
| longTermStorage |
number |
The long-term storage usage. |
0 |
| longTermStorageUnit |
string |
The unit of long-term storage usage. |
B |
| lowFreqStorageFileCount |
integer |
The number of Infrequent Access (IA) storage files. |
0 |
| lowFreqStorage |
number |
The Infrequent Access (IA) storage usage. |
0 |
| lowFreqStorageUnit |
string |
The unit of Infrequent Access (IA) storage usage. |
B |
| totalFrequency |
integer |
The access frequency. Note
Note
|
10 |
| totalInputAmount |
number |
The total amount of accessed data. Note
The total volume of data read by all access operations. |
1 |
| totalInputAmountUnit |
string |
The unit of the total amount of accessed data. |
GB |
| date |
string |
The statistics date. |
20241205 |
| totalCount |
integer |
The total number of returned entries. |
1 |
| pageNumber |
integer |
The page number. |
1 |
| pageSize |
integer |
The number of entries per page. |
10 |
Examples
Success response
JSON format
{
"requestId": "0bc12e6a16679892465424670db3eb",
"httpCode": 200,
"errorCode": "OBJECT_NOT_EXIST",
"errorMsg": "This object does not exist.\n",
"data": {
"storageTableInfoList": [
{
"date": "20241205",
"projectName": "odps_project",
"schemaName": "schema",
"tableName": "bank_data",
"isPartitioned": false,
"storageType": "standard",
"lastAccessTime": 1694589365,
"totalStorageFileCount": 2,
"totalStorage": 600,
"totalStorageUnit": "KB",
"rate": 0,
"standardStorageFileCount": 2,
"standardStorage": 600,
"standardStorageUnit": "KB",
"longTermStorageFileCount": 0,
"longTermStorage": 0,
"longTermStorageUnit": "B",
"lowFreqStorageFileCount": 0,
"lowFreqStorage": 0,
"lowFreqStorageUnit": "B",
"totalFrequency": 10,
"totalInputAmount": 1,
"totalInputAmountUnit": "GB"
}
],
"date": "20241205",
"totalCount": 1,
"pageNumber": 1,
"pageSize": 10
}
}
Error codes
See Error Codes for a complete list.
Release notes
See Release Notes for a complete list.