SaketaChalamchala opened a new pull request, #9985:
URL: https://github.com/apache/ozone/pull/9985
## What changes were proposed in this pull request?
Currently, the snapshot diff process ties snapshot diff job cleanup with
re-submission i.e., new snapshot diff cannot be submitted until old snapshot
diff job is cleaned up from the DB as there is a single rpc call used for
submitting snap diff and gettng the report. Hence, the cleanup has to be inline
with the default wait time (1m) because,
- CLI requests are asked to wait default wait time to retrieve the
report/status of the job.
- If cleanup runs at T0, T1 and so on... snapshot diff job that is
submitted at T0.5 which fails immediately is cleaned up from the DB at T1.
-- When the user tries to get the report/status at T1.5 they do not know
about the failure and just resubmit.
-- This will continue to go on at T2.5 and so on...
The proposal is to refactor the snapshot diff workflow by splitting the
process into two distinct RPC calls and removing the dependency between cleanup
and submission:
- Submit Job: Initiates the snapshot diff job and returns immediately with
a status.
- Get Report: A separate call to retrieve the results once the job is
complete.
**RPC Layer:** Updated the Ozone Manager protocol to support separate
submitSnapshotDiff and getSnapshotDiffReport requests.
**Client Side:** Updated the ozone sh snapshot diff command to handle the
new asynchronous flow. It now submits the job and provides instructions to the
user on how to poll for the report using the --get-report option.
**Response Handling:** Introduced SubmitSnapshotDiffResponse to provide
clear feedback to the user regarding the job status (e.g., if a job is already
in progress, completed, or newly submitted).
## What is the link to the Apache JIRA
https://issues.apache.org/jira/browse/HDDS-14829
## How was this patch tested?
Acceptance tests and Unit tests to be added.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]