Viewing table maintenance status
You can verify the table maintenance action status on the Lakehouse Optimizer UI or using REST APIs.
-
Use one of the following methods to verify the table maintenance status on the Cloudera Management Console > Lakehouse Optimizer UI:
- Go to the Policies tab, and click Actions > View for the required policy.
The policy details appear on the View Policy page, and the Status column shows the current status for the table.
- On the Tables tab, find the required table. The Status column shows the current status for the table.
- Go to the Policies tab, and click Actions > View for the required policy.
-
Perform the following steps to verify the table maintenance status using REST
APIs:
- Fetch the submitted task details for a specific policy and tables using the GET /tasks/policies/{policyName}/tables/{tableName}/submitted API.
-
Monitor the status of all the tasks using the GET
/tasks API. You can fetch the task metadata of a specific
task ID using the GET /tasks/id/{id} API.
The following sample snippet shows the response for the
019348e0-2d6f-7997-b117-8441d8d757a6taskID.{ "status": 200, "action": "READ", "message": "Success", "result": [ { "taskId": "019348e0-2d6f-7997-b117-8441d8d757a6", "createAt": "2024-11-20T09:21:11.534Z", "createdBy": 1, "tablePath": "hive.default.itest", "policyName": "ClouderaAdaptive", "policyVersion": "0be2a330-0282-56d6-bbc4-67c96ad7e9c0", "currentAction": "EXPIRE_SNAPSHOT", "actions": { "EXPIRE_SNAPSHOT": { "result": { "deletedDataFilesCount": 0.0, "deletedEqualityDeleteFilesCount": 0.0, "deletedPositionDeleteFilesCount": 0.0, "deletedManifestsCount": 0.0, "deletedManifestListsCount": 4.0, "deletedStatisticsFilesCount": 0.0 }, "sparkMetrics": { "jvmGcTime": 4637.0, "totalBytesRead": 65983.0, "totalBytesWritten": 0.0, "taskCount": 610.0, "executorCpuTime": 3.4583323352E10 }, "sparkRuntime": { "applicationId": "application_1732084186181_0015", "jobIds": [ 9.0, 10.0, 11.0, 12.0, 13.0, 14.0 ] }, "status": "Success" } }, "status": "SUBMITTED" } ] } - Verify whether the statistics improved after the maintenance actions completed using the GET /tables/{tableId}/stats API.
