kapua icon indicating copy to clipboard operation
kapua copied to clipboard

✨ [REST-API] Add support to query operations by `status` in `GET /{scopeId}/devices/{deviceId}/operations`

Open MDeLuise opened this issue 4 months ago • 1 comments

Description

This PR implements the capability to search operations by their status using the GET /{scopeId}/devices/{deviceId}/operations endpoint.

Changes Made

  • New Feature: Added functionality to filter operations based on their status.
  • Refactor: Modified the DeviceManagementOperations query method:
    • Deprecation: The current query method has been deprecated. It previously required the @PathParam("deviceId") EntityId deviceId parameter.
    • New Method: Introduced a new query1 method that conforms to the parameters accepted and usage patterns of other query methods. The deviceId parameter was removed, improving consistency across endpoints.
  • Future Plans:
    1. The _query (deprecated) endpoint will be removed in a future release.
    2. The _query1 endpoint will eventually be deprecated in favor of a new _query endpoint with the same behavior but a "correct" name.
    3. _query1 will be deleted in a subsequent release, following a smooth deprecation process.

Impact

These changes are backward-compatible but introduce a new method for querying operations. Users relying on the existing query method should migrate to the new query1 method or prepare for the upcoming changes.

Notes

  • The naming of query1 is provisional and can be adjusted based on feedback. It was chosen to maintain backward compatibility while moving towards a cleaner design.
  • Documentation have been updated to reflect these changes.

MDeLuise avatar Oct 18 '24 15:10 MDeLuise