Thakkar-Khushang opened a new pull request, #10618:
URL: https://github.com/apache/gravitino/pull/10618

   ## What changes were proposed in this pull request?
   
   Fix `dropPartitionStatistics` so the REST exception handler does not throw a 
secondary
   `NullPointerException` when the request body is invalid and `drops` is null.
   
   Previously, the catch block in `StatisticOperations` called 
`request.getDrops().stream()`
   while building the partition name string for the error response. If 
`request` or
   `request.getDrops()` was null, that masked the original validation failure 
and could turn
   a client-side bad request into an internal server error.
   
   This PR:
   - adds a null-safe helper for extracting drop partition names
   - uses that helper in the `dropPartitionStatistics` catch block
   - adds a regression test for `{"drops": null}`
   
   ## How was this patch tested?
   
   ```bash
   ./gradlew :server:test --tests 
org.apache.gravitino.server.web.rest.TestStatisticOperations


-- 
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]

Reply via email to