poorbarcode opened a new pull request, #15929:
URL: https://github.com/apache/pulsar/pull/15929

   ### Motivation
   
   Lego ran into an issue where they would call the 
/admin/v2/persistent/{tenant}/{namespace}/{topic}/retention endpoint after 
creating a topic, but the call appeared to have no effect, despite returning 
HTTP 204.
   
   After some initial debugging, they determined that the root cause was 
related to the casing of the parameters in their JSON payload. They initially 
provided this:
   
   ```
   {"RetentionSizeInMb":-1,"RetentionTimeInMinutes":40320}
   ```
   
   Which should have been this:
   
   ```
   {"retentionSizeInMB":-1,"retentionTimeInMinutes":40320}
   ```
   
   This will trick the user into thinking the setup succeeded when it didn't
   
   #### Observed behavior
   When an invalid config is submitted, 
/admin/v2/persistent/{tenant}/{namespace}/{topic}/retention returns HTTP 204
   
   #### Expected behavior
   When an invalid config is submitted, 
/admin/v2/persistent/{tenant}/{namespace}/{topic}/retention returns HTTP 400
   
   
   
   
   ### Modifications
   
   Enhanced verification
   
   
   
   ### Documentation
   
   
   
   - [ ] `doc-required` 
   
     
   - [x] `doc-not-needed` 
   
     
   - [ ] `doc` 
   
   
   - [ ] `doc-complete`
   


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