rishi-rana opened a new pull request, #23716:
URL: https://github.com/apache/kafka/pull/23716

   ## Summary
   
   `Admin#deleteRecords` throws `PolicyViolationException` (surfaced via the
   per-partition future, see `Partition.deleteRecordsOnLeader` in
   `core/src/main/scala/kafka/cluster/Partition.scala`) when a topic's
   `cleanup.policy` does not permit record deletion — e.g. 
`cleanup.policy=compact`
   without `delete`. This was never documented in the javadoc.
   
   - Added the standard "exceptions anticipated when calling `get()`" block,
     matching the convention already used elsewhere in `Admin.java` (e.g.
     `incrementalAlterConfigs`).
   - No behavior change — documentation only.
   
   Developed with AI assistance.
   
   ## Test plan
   
   - [x] `./gradlew :clients:spotlessCheck :clients:checkstyleMain 
:clients:javadoc` — clean


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