Support Questions

Find answers, ask questions, and share your expertise

Difference between spaceConsumed vs length parameters in getContentSummary using webHDFS REST API

avatar
Expert Contributor

According to the following doc, spaceConsumed refers to the "The disk space consumed by the content." and length refers to "The number of bytes used by the content."

https://hadoop.apache.org/docs/r1.0.4/webhdfs.html#ContentSummary

What would be the real difference here in terms of space taken from HDFS?

Consider that most of time, if not always, spaceConsumed has a lot larger value then length. What does spaceConsumed consider that length does not?

1 ACCEPTED SOLUTION

avatar
Expert Contributor

spaceConsumed = length * replicationFactor

View solution in original post

1 REPLY 1

avatar
Expert Contributor

spaceConsumed = length * replicationFactor