yew1eb opened a new pull request, #3846:
URL: https://github.com/apache/celeborn/pull/3846

   ### What changes were proposed in this pull request?
   
   Fix the enum casing in the REST examples of `docs/decommissioning.md`. The 
REST API only accepts uppercase enum values (`DECOMMISSION`, 
`DECOMMISSIONTHENIDLE`, ...), so the documented PascalCase values fail with 
HTTP 400:
   
   ```
   Cannot deserialize value of type `SendWorkerEventRequest$EventTypeEnum` from 
String "Decommission":
   not one of the values accepted for Enum class: [GRACEFUL, NONE, 
DECOMMISSION, DECOMMISSIONTHENIDLE, IMMEDIATELY, RECOMMISSION]
   ```
   
   - `{"type":"Decommission"}` -> `{"type":"DECOMMISSION"}` (worker exit)
   - `{"eventType":"Decommission",...}` -> `{"eventType":"DECOMMISSION",...}` 
(master events)
   - `{"eventType":"DecommissionThenIdle",...}` -> 
`{"eventType":"DECOMMISSIONTHENIDLE",...}` (master events)
   
   ### Why are the changes needed?
   
   The documented `curl` commands fail with HTTP 400 as-is, since 
`WorkerExitRequest.TypeEnum` / `SendWorkerEventRequest.EventTypeEnum` only 
accept uppercase values.
   
   ### Does this PR introduce _any_ user-facing change?
   
   Docs only, no code change.
   
   ### How was this patch tested?
   
   Manually verified against a running cluster: the documented command fails 
with HTTP 400, the fixed uppercase value is accepted.
   
    


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