code: public void writeProblemsToHDFS(List<Frontier> problems) throws IOException {
          FileSystem fs = FileSystem.get(configuration);
          log.info("hdfsFileRoot = " + hdfsFileRoot);
  
          StringBuilder sb = new StringBuilder();
          for (Frontier problem : problems) {
              SCXMLGapper gapper = new SCXMLGapper();
              Map<String, String> decomposition = gapper.decompose(problem, stateMachineText);
              String problemString = decomposition.get("target") + "|" + decomposition.get("variables") + "|";
  
              sb.append(problemString.replace("\n", "").replace("\t", "").replace("\r", ""));
              sb.append("\n");
          }
  
          try (FSDataOutputStream out = fs.create(mapperInputFilePath)) {
              out.write(sb.toString().getBytes());
          } catch (IOException e) {
              log.error("Problem writing " + mapperInputFilePath + " prior to MR job execution");
          }
      }
docs: Convert a set of SearchProblem objects to Strings of JSON text, writing the array to
  the HDFS location given by the HDFS file root. The written file serves as input to the
  Mapper tasks (one Mapper per line in the file, which is also one SearchProblem)
  
  @param problems A List of Search Problems to write
  @throws IOException if the file cannot be written to HDFS