List statistics
GET/metalakes/:metalake/objects/:metadataObjectType/:metadataObjectFullName/statistics
Returns the statistics of a table, each with its value, whether it is reserved or modifiable, and audit information. Statistics are supported only for objects of type TABLE.
Sign in with a bearer token or a local user's password; see Authentication.
Request
Path Parameters
The name of the metalake
Possible values: [TABLE]
The type of the metadata object. Statistics are supported for tables only; any other type fails with IllegalArgumentException. The server matches the value case-insensitively.
The full name of the metadata object
Responses
- 200
- 400
- 404
- 501
- 5xx
The table's statistics, each with its value, whether it is reserved or modifiable, and audit information.
- application/vnd.gravitino.v1+json
- Schema
- Example (from schema)
- StatisticListResponse
Schema
Array [
- MOD1
- MOD2
- MOD3
- MOD4
- MOD5
- MOD6
Array [
]
]
Possible values: [0]
Status code of the response
statistics
object[]
The name of the statistic
value
object
The statistic's value, present only when the statistic has one. Its type depends on the statistic: a string, number, integer, boolean, array, or object.
oneOf
string
number
integer
boolean
Whether the statistic is reserved
Whether the statistic is modifiable
audit
object
required
Audit information for a Gravitino resource.
The user who created the resource
The time the resource was created
The user who last modified the resource
The time the resource was last modified
{
"code": 0,
"statistics": [
{
"name": "string",
"value": "string",
"reserved": true,
"modifiable": true,
"audit": {
"creator": "string",
"createTime": "2024-07-29T15:51:28.071Z",
"lastModifier": "string",
"lastModifiedTime": "2024-07-29T15:51:28.071Z"
}
}
]
}
{
"code": 0,
"statistics": [
{
"name": "row_count",
"value": "1000",
"reserved": true,
"modifiable": false,
"audit": {
"creator": "user1",
"createTime": "2023-10-01T12:00:00Z",
"lastModifier": "user2",
"lastModifiedTime": "2023-10-02T12:00:00Z"
}
},
{
"name": "file_size",
"value": "500MB",
"reserved": true,
"modifiable": false,
"audit": {
"creator": "user1",
"createTime": "2023-10-01T12:00:00Z",
"lastModifier": "user2",
"lastModifiedTime": "2023-10-02T12:00:00Z"
}
},
{
"name": "custom-k1",
"value": "v1",
"reserved": false,
"modifiable": true,
"audit": {
"creator": "user1",
"createTime": "2023-10-01T12:00:00Z",
"lastModifier": "user2",
"lastModifiedTime": "2023-10-02T12:00:00Z"
}
}
]
}
The request is malformed or fails validation, for example because of invalid JSON, a missing required field or an invalid parameter value. The body is normally an error model, although the server's middleware can return plain text instead.
- application/vnd.gravitino.v1+json
- Schema
- Example (from schema)
- Example
Schema
Possible values: >= 1000 and <= 1100
HTTP response code
Internal type definition of the error
A human-readable message
Deprecated diagnostic stack trace. Enterprise omits it by default because it can expose internal implementation details. Operators can opt in for controlled diagnostics with gravitino.server.webserver.includeErrorStackTrace=true. See OWASP REST Security: Error handling and CWE-209.
{
"code": 1002,
"type": "string",
"message": "string"
}
{
"code": 1003,
"type": "BadRequestException",
"message": "Malformed request"
}
The metalake or the metadata object does not exist.
- application/vnd.gravitino.v1+json
- Schema
- Example (from schema)
- NoSuchMetadataObjectException
Schema
Possible values: >= 1000 and <= 1100
HTTP response code
Internal type definition of the error
A human-readable message
Deprecated diagnostic stack trace. Enterprise omits it by default because it can expose internal implementation details. Operators can opt in for controlled diagnostics with gravitino.server.webserver.includeErrorStackTrace=true. See OWASP REST Security: Error handling and CWE-209.
{
"code": 1002,
"type": "string",
"message": "string"
}
{
"code": 1003,
"type": "NoSuchMetadataObjectException",
"message": "Metadata object does not exist",
"stack": [
"org.apache.gravitino.exceptions.NoSuchMetadataObjectException: Metadata object does not exist",
"..."
]
}
The server's statistics storage does not support the requested operation.
- application/vnd.gravitino.v1+json
- Schema
- Example (from schema)
Schema
Possible values: >= 1000 and <= 1100
HTTP response code
Internal type definition of the error
A human-readable message
Deprecated diagnostic stack trace. Enterprise omits it by default because it can expose internal implementation details. Operators can opt in for controlled diagnostics with gravitino.server.webserver.includeErrorStackTrace=true. See OWASP REST Security: Error handling and CWE-209.
{
"code": 1002,
"type": "string",
"message": "string"
}
The server hit an internal error that the client usually cannot fix by changing the request.
- application/vnd.gravitino.v1+json
- Schema
- Example (from schema)
- Example
Schema
Possible values: >= 1000 and <= 1100
HTTP response code
Internal type definition of the error
A human-readable message
Deprecated diagnostic stack trace. Enterprise omits it by default because it can expose internal implementation details. Operators can opt in for controlled diagnostics with gravitino.server.webserver.includeErrorStackTrace=true. See OWASP REST Security: Error handling and CWE-209.
{
"code": 1002,
"type": "string",
"message": "string"
}
{
"code": 1002,
"type": "RuntimeException",
"message": "Internal Server Error",
"stack": [
"java.lang.RuntimeException: Internal Server Error"
]
}