code: public static String getPlanAsJSON(Plan plan) {
  		List<DataSinkNode> sinks = Optimizer.createPreOptimizedPlan(plan);
  		return new PlanJSONDumpGenerator().getPactPlanAsJSON(sinks);
  	}
docs: Creates a JSON representation of the given dataflow plan.
  
  @param plan The dataflow plan.
  @return The dataflow plan (prior to optimization) as a JSON string.