private static JavaApplication<SimpleJavaApplication> launch(Class<?> clz,
			boolean remoteDebug, Properties systemProperties, List<String> args) throws IOException {
		String classpath = System.getProperty("java.class.path");

		logger.info("Launching {}", clz);
		logger.info("	args: {}", args);
		logger.info("	properties: {}", systemProperties);
		logger.info("	classpath: {}", classpath);

		SimpleJavaApplicationSchema schema = new SimpleJavaApplicationSchema(clz.getName(), classpath);
		if (args != null) {
			for (String arg : args) {
				schema.addArgument(arg);
			}
		}
		if (systemProperties != null) {
			schema.setSystemProperties(new PropertiesBuilder(systemProperties));
		}

		NativeJavaApplicationBuilder<SimpleJavaApplication, SimpleJavaApplicationSchema> builder =
				new NativeJavaApplicationBuilder<SimpleJavaApplication, SimpleJavaApplicationSchema>();
		builder.setRemoteDebuggingEnabled(remoteDebug);
		return builder.realize(schema, clz.getName(), new SystemApplicationConsole());
	}
Launch the given class's {@code main} method in a separate JVM.

@param clz               class to launch
@param remoteDebug       if true, enable remote debugging
@param systemProperties  system properties for new process
@param args              command line arguments
@return launched application

@throws IOException if an exception was thrown launching the process
spring-xd-distributed-test/src/main/java/org/springframework/xd/distributed/util/ServerProcessUtils.java