zhijiangW commented on a change in pull request #10492: [FLINK-15140][runtime]
Fix shuffle data compression doesn't work with BroadcastRecordWriter.
URL: https://github.com/apache/flink/pull/10492#discussion_r355352770
##########
File path:
flink-runtime/src/main/java/org/apache/flink/runtime/io/network/buffer/BufferConsumer.java
##########
@@ -44,6 +44,9 @@
private int currentReaderPosition;
+ /** Whether this BufferConsumer is copied from another BufferConsumer
instance. */
+ private final boolean isCopied;
Review comment:
> If we are copying the BufferConsumer, the first one will not have this
flag set. Is this an issue?
Exactly, if we agree to rely on this way for handling the special broadcast
case, we should tag this flag as true not only in the `BufferConsumer#copy()`,
but also make sure all the `BufferConsumer` instances tagged if they are
sharing the same `BufferBuilder`.
Also we might need to refactor this field renaming. It should indicate
whether there are multiple `BufferConsumer` instances share the same
`BufferBuilder`, not indicating for neither it is copied by others nor it is
copying from others.
----------------------------------------------------------------
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]
With regards,
Apache Git Services