You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@flink.apache.org by GitBox <gi...@apache.org> on 2020/03/20 08:19:05 UTC
[GitHub] [flink] GJL commented on a change in pull request #11453:
[FLINK-13553][tests] Fix ByteBuf leak in KvStateServerHandlerTest
GJL commented on a change in pull request #11453: [FLINK-13553][tests] Fix ByteBuf leak in KvStateServerHandlerTest
URL: https://github.com/apache/flink/pull/11453#discussion_r395488302
##########
File path: flink-queryable-state/flink-queryable-state-runtime/src/test/java/org/apache/flink/queryablestate/network/KvStateServerHandlerTest.java
##########
@@ -544,6 +552,7 @@ public void testIncomingBufferIsRecycled() throws Exception {
channel.writeInbound(unexpected);
assertEquals("Buffer not recycled", 0L, unexpected.refCnt());
+ channel.finishAndReleaseAll();
Review comment:
Here we are sending an expected message, i.e., a bad request, which will be answered with a request failure response:
https://github.com/apache/flink/blob/0619a5b3e000855f00d11e71ae2f1b9deef05c98/flink-queryable-state/flink-queryable-state-client-java/src/main/java/org/apache/flink/queryablestate/network/AbstractServerHandler.java#L262-L264
However, we are not reading the response and releasing the `ByteBuf` instance. You can set a breakpoint and debug into the `EmbeddedChannel` and check that there are indeed unread outbound messages.
----------------------------------------------------------------
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:
users@infra.apache.org
With regards,
Apache Git Services