You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@eventmesh.apache.org by "Alonexc (via GitHub)" <gi...@apache.org> on 2023/04/13 01:53:16 UTC

[GitHub] [eventmesh] Alonexc commented on a diff in pull request #3710: [ISSUE #3408]Update SendAsyncRemoteEventProcessor.java

Alonexc commented on code in PR #3710:
URL: https://github.com/apache/eventmesh/pull/3710#discussion_r1164869907


##########
eventmesh-runtime/src/main/java/org/apache/eventmesh/runtime/core/protocol/http/processor/SendAsyncRemoteEventProcessor.java:
##########
@@ -243,7 +243,8 @@ public void handler(final HandlerService.HandlerSpecific handlerSpecific, final
             return;
         }
 
-        final String content = event.getData() == null ? "" : new String(event.getData().toBytes(), StandardCharsets.UTF_8);
+        final String content = event.getData() == null ? "" 

Review Comment:
   There is one NPE to control here:
   ```
   final String content = event.getData() == null ? "" :
               new String(Objects.requireNonNull(event.getData()).toBytes(), StandardCharsets.UTF_8);
   ```



-- 
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: issues-unsubscribe@eventmesh.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@eventmesh.apache.org
For additional commands, e-mail: issues-help@eventmesh.apache.org