private Map<String, String> getGeneratedConfig() {
    Map<String, String> generatedConfig = new HashMap<>();

    Map<String, String> systemStreamConfigs = generateSystemStreamConfigs(appDesc);
    generatedConfig.putAll(systemStreamConfigs);

    StreamConfig streamConfig = new StreamConfig(new MapConfig(generatedConfig));
    Set<String> inputStreamIds = new HashSet<>(appDesc.getInputStreamIds());
    inputStreamIds.removeAll(appDesc.getOutputStreamIds()); // exclude intermediate streams

    final ApplicationConfig.ApplicationMode mode;
    if (inputStreamIds.isEmpty()) {
      mode = ApplicationConfig.ApplicationMode.STREAM; // use stream by default
    } else {
      mode = inputStreamIds.stream().allMatch(streamConfig::getIsBounded)
          ? ApplicationConfig.ApplicationMode.BATCH
          : ApplicationConfig.ApplicationMode.STREAM;
    }

    generatedConfig.put(ApplicationConfig.APP_MODE, mode.name());

    // adding app.class in the configuration, unless it is LegacyTaskApplication
    if (!LegacyTaskApplication.class.getName().equals(appDesc.getAppClass().getName())) {
      generatedConfig.put(ApplicationConfig.APP_CLASS, appDesc.getAppClass().getName());
    }
    return generatedConfig;
  }
Write the execution plan JSON to a file
@param planJson JSON representation of the plan
samza-core/src/main/java/org/apache/samza/execution/JobPlanner.java