/**
  * Get a path from the local FS. Pass size as SIZE_UNKNOWN if not known apriori. We round-robin
  * over the set of disks (via the configured dirs) and return the first complete path which has
  * enough space
  *
  * @param pathStr the requested path (this will be created on the first available disk)
  * @param size the size of the file that is going to be written
  * @param conf the Configuration object
  * @param checkWrite ensure that the path is writable
  * @return the complete path to the file on a local disk
  * @throws IOException
  */
 public Path getLocalPathForWrite(
     String pathStr, long size, Configuration conf, boolean checkWrite) throws IOException {
   AllocatorPerContext context = obtainContext(contextCfgItemName);
   return context.getLocalPathForWrite(pathStr, size, conf, checkWrite);
 }