zooo-code commented on PR #25158:
URL: https://github.com/apache/pulsar/pull/25158#issuecomment-3773328197

   Hi @lhotari,
   
   I've refactored the code so that sync calls async as you suggested. However, 
I'm encountering a test failure in CI.
   
   **Test failure:**
   
   * Test: `AdminApiSchemaTest.createKeyValueSchema[V2]`
   * CI run: 
[https://github.com/zooo-code/pulsar/actions/runs/21166460377/job/60873078404](https://github.com/zooo-code/pulsar/actions/runs/21166460377/job/60873078404)
   * Error:
     Failed to deserialize payload for key
     `/admin/local-policies/schematest/test`
     Caused by: `MismatchedInputException: No content to map due to 
end-of-input`
   
   **Root cause:**
   When `LocalPolicies` has corrupted/empty data in the metadata store, 
deserialization fails. The `.exceptionally()` handler doesn't catch this 
because the exception occurs inside `MetadataCacheImpl`'s `CompletableFuture` 
chain.
   
   **Possible solutions:**
   
   1. Add exception handling to all `getLocalPoliciesAsync()` call sites (8 
places)
   2. Modify `LocalPoliciesResources.getLocalPoliciesAsync()` to handle 
deserialization failures gracefully
   3. Different approach?
   
   Could you advise on the preferred solution?
   
   Thanks!
   


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