ozone
ozone copied to clipboard
HDDS-11561. Refactor Open Key Search Endpoint and Consolidate with OmDBInsightEndpoint Using StartPrefix Parameter.
What changes were proposed in this pull request?
This pull request introduces the following changes:
- Addition of startPrefix to
/open
endpoint: ThestartPrefix
parameter has been added to the/open
endpoint to enable filtering of open keys based on a specific prefix. This change mirrors the behaviour implemented for the /deletePending endpoint and improves search efficiency for open keys. - Consolidation of Search Functionality:
The search functionality for open keys, previously handled in the
OmDBInsightsSearchEndpoint
, has been fully integrated into the/open
endpoint inOMDBInsightEndpoint
. TheOmDBInsightsSearchEndpoint
file has been removed as it is no longer needed. - Test Class Renaming:
The test class
TestOmDBSearchEndpoint
has been renamed toTestOpenKeysSearchEndpoint
to better reflect its purpose, as it now only tests the open keys search functionality.
What is the link to the Apache JIRA
https://issues.apache.org/jira/browse/HDDS-11561
How was this patch tested?
- Unit tests were updated to reflect the changes made to the /open endpoint.
- The renamed TestOpenKeysSearchEndpoint class has been run to verify the correctness of the open key search functionality.
- Manual testing was performed to ensure that both /open and /deletePending endpoints handle startPrefix correctly and return expected results.