merlimat commented on a change in pull request #10513:
URL: https://github.com/apache/pulsar/pull/10513#discussion_r630359286



##########
File path: 
pulsar-client-admin/src/main/java/org/apache/pulsar/client/admin/internal/TopicsImpl.java
##########
@@ -1397,9 +1399,14 @@ public OffloadProcessStatus offloadStatus(String topic)
         WebTarget path = topicPath(tn, "offload");
         final CompletableFuture<OffloadProcessStatus> future = new 
CompletableFuture<>();
         asyncGetRequest(path,
-                new InvocationCallback<OffloadProcessStatus>() {
+                new InvocationCallback<String>() {
                     @Override
-                    public void completed(OffloadProcessStatus 
offloadProcessStatus) {
+                    public void completed(String jsonString) {
+                        Gson gson = new 
GsonBuilder().registerTypeAdapter(MessageId.class,

Review comment:
       We want to make sure to use Jackson, through the 
`ObjectMapperFactory.getThreadLocal()` since it comes configured with some 
settings. 
   
   If `@JsonDeserialize` annotations are the problem, there will be bigger 
problems porting the POJOs defined in `pulsar-common`.
   
   The better option here is to untie the `pulsar-client-admin-api` from the 
POJOs. Instead, `pulsar-client-admin-api` should return Java interfaces instead 
of POJOs that are used for serialization.




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

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to