In order to facilitate efficient and timely data migration functionality, which often requires iterative reloading of data, the <MODULE> needs the ability to Delete purchase orders in bulk, rather than processing records individually.
For deleting a list of records RMB needs to provide a method PgUtil.delete, but this is still missing, we have
RMB-389 for developing it.
- Users shall be able to DELETE to a single endpoint with a CQL query. All records matching that query shall be deleted. Deleting by id using CQL is restricted to 54 records because of the URL maximum length
- Users shall be able to DELETE to a single endpoint with a list of ids in the body of the DELETE request.
- Records shall be deleted from the database in a single transaction
- For CQL the endpoint shall respect a "dry run" parameter, which will return the count of records to be deleted, without actually deleting them from the database.
- Deletes shall not cascade. If a record cannot be deleted due to foreign key constraints, then the whole operation shall return an error.
- Should the operation fail due to an error in an individual record, an error message shall be returned that alerts the user where to look in the record set to find the problem.
- On success, the endpoint shall return a JSON object with the count of the number of records deleted.