[ https://issues.apache.org/jira/browse/HDFS-879?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12798247#action_12798247 ]
Hairong Kuang commented on HDFS-879: ------------------------------------ > Data Node heartbeat the size. You meant heatbeat the size to NN or the client? Before talking about how we do it, I am not convinced why FileStatus needs to provide visible length & whether it is "under construction"? Isn't it good enough that DFSOutputStream provides those information? > FileStatus should have the visible length of the file > ----------------------------------------------------- > > Key: HDFS-879 > URL: https://issues.apache.org/jira/browse/HDFS-879 > Project: Hadoop HDFS > Issue Type: Improvement > Reporter: Zheng Shao > Assignee: Zheng Shao > > Currently, {{FileStatus}} returned by {{DistributedFileSystem.listStatus()}} > (which goes through {{DFSClient.listPath()}} then {{NameNode.getListing()}}) > does not have the latest file length, if the file is still open for write. > We should make changes in {{DFSClient.listPath()}} to override the length of > the file, if the file is under construction. > This depends on adding a {{isUnderConstruction}} field in {{FileStatus}}. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.