You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pulsar.apache.org by GitBox <gi...@apache.org> on 2023/01/06 04:03:53 UTC

[GitHub] [pulsar] nodece commented on a diff in pull request #19141: [improve][broker,proxy] Use ChannelVoidPromise to avoid useless promise objects creation

nodece commented on code in PR #19141:
URL: https://github.com/apache/pulsar/pull/19141#discussion_r1063076775


##########
pulsar-proxy/src/main/java/org/apache/pulsar/proxy/server/LookupProxyHandler.java:
##########
@@ -446,5 +447,9 @@ private ServerError getServerError(Throwable error) {
         return responseError;
     }
 
+    private void writeAndFlushVoidPromise(ByteBuf cmd) {
+        proxyConnection.ctx().writeAndFlush(cmd);

Review Comment:
   ```suggestion
           ChannelHandlerContext ctx = proxyConnection.ctx();
           ctx.writeAndFlush(cmd, ctx.voidPromise());
   ```



-- 
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: commits-unsubscribe@pulsar.apache.org

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