Uploaded image for project: 'Hadoop HDFS'
  1. Hadoop HDFS
  2. HDFS-4160

libhdfs / fuse-dfs should implement O_CREAT | O_EXCL

    XMLWordPrintableJSON

    Details

    • Type: Improvement
    • Status: Patch Available
    • Priority: Minor
    • Resolution: Unresolved
    • Affects Version/s: 2.0.3-alpha
    • Fix Version/s: None
    • Component/s: libhdfs
    • Labels:

      Description

      hdfsOpenFile contains this code:

      if ((flags & O_CREAT) && (flags & O_EXCL)) {                               
        fprintf(stderr, "WARN: hdfs does not truly support O_CREATE && O_EXCL\n");
      } 
      

      But hdfsOpenFile could easily support O_CREAT | O_EXCL by calling FileSystem#create with overwrite = false.

      We should do this. It would also benefit fuse-dfs.

        Attachments

        1. HDFS-4160.001.patch
          9 kB
          Colin McCabe

          Activity

            People

            • Assignee:
              cmccabe Colin McCabe
              Reporter:
              cmccabe Colin McCabe
            • Votes:
              0 Vote for this issue
              Watchers:
              5 Start watching this issue

              Dates

              • Created:
                Updated: