yunfengzhou-hub commented on code in PR #97: URL: https://github.com/apache/flink-ml/pull/97#discussion_r889669964
########## flink-ml-iteration/src/main/java/org/apache/flink/iteration/datacache/nonkeyed/Segment.java: ########## @@ -18,61 +18,37 @@ package org.apache.flink.iteration.datacache.nonkeyed; -import org.apache.flink.core.fs.Path; +import org.apache.flink.annotation.Internal; -import java.io.Serializable; -import java.util.Objects; +/** A segment contains the information about a cache unit. */ +@Internal +class Segment { -/** A segment represents a single file for the cache. */ -public class Segment implements Serializable { + private FileSegment fileSegment; Review Comment: We need to create the `Segment` instance before we persist the segment to disk and acquire enough information to create `FileSegment`. This means that the `fileSegment` field need to be set after the creation of `Segment`, and it cannot be final. -- 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-unsubscr...@flink.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org