code: @Override
    public FSDataOutputStream create(Path path, FsPermission permission, boolean overwrite,
        int bufferSize, short replication, long blockSize, Progressable progress) throws IOException {
      LOG.debug("create({}, {}, {}, {}, {}, {}, {})", path, permission, overwrite, bufferSize,
          replication, blockSize, progress);
      if (mStatistics != null) {
        mStatistics.incrementWriteOps(1);
      }
  
      AlluxioURI uri = new AlluxioURI(HadoopUtils.getPathWithoutScheme(path));
      CreateFilePOptions options = CreateFilePOptions.newBuilder().setBlockSizeBytes(blockSize)
          .setMode(new Mode(permission.toShort()).toProto()).setRecursive(true).build();
  
      FileOutStream outStream;
      try {
        outStream = mFileSystem.createFile(uri, options);
      } catch (AlluxioException e) {
        //now we should consider the override parameter
        try {
          if (mFileSystem.exists(uri)) {
            if (!overwrite) {
              throw new IOException(ExceptionMessage.FILE_ALREADY_EXISTS.getMessage(uri));
            }
            if (mFileSystem.getStatus(uri).isFolder()) {
              throw new IOException(
                  ExceptionMessage.FILE_CREATE_IS_DIRECTORY.getMessage(uri));
            }
            mFileSystem.delete(uri);
          }
          outStream = mFileSystem.createFile(uri, options);
        } catch (AlluxioException e2) {
          throw new IOException(e2);
        }
      }
      return new FSDataOutputStream(outStream, mStatistics);
    }
docs: Attempts to create a file. Overwrite will not succeed if the path exists and is a folder.
  
  @param path path to create
  @param permission permissions of the created file/folder
  @param overwrite overwrite if file exists
  @param bufferSize the size in bytes of the buffer to be used
  @param replication under filesystem replication factor, this is ignored
  @param blockSize block size in bytes
  @param progress queryable progress
  @return an {@link FSDataOutputStream} created at the indicated path of a file