Github user zhijiangW commented on a diff in the pull request:
https://github.com/apache/flink/pull/4735#discussion_r141400676
--- Diff:
flink-runtime/src/test/java/org/apache/flink/runtime/io/network/buffer/LocalBufferPoolTest.java
---
@@ -211,10 +210,15 @@ public void testSetLessThanRequiredNumBuffers()
throws IOException {
@Test
public void testPendingRequestWithListenerAfterRecycle() throws
Exception {
- EventListener<Buffer> listener = spy(new
EventListener<Buffer>() {
+ BufferListener listener = spy(new BufferListener() {
@Override
- public void onEvent(Buffer buffer) {
+ public boolean notifyBufferAvailable(Buffer buffer) {
buffer.recycle();
+ return false;
--- End diff --
Yes, I also consider the issue of verifying notification multi times.
And I guess you may point out it. :)
It can not work to return true for that, and I will think of proper way of
verifying it.
---