BeanDefinitionBuilder defBuilder = BeanDefinitionBuilder.genericBeanDefinition(LaunchCommandsFactoryBean.class);
YarnNamespaceUtils.setValueIfAttributeDefined(defBuilder, containerRunnerElement, "command");
if (containerRunnerElement.hasAttribute("runner")) {
defBuilder.addPropertyValue("runner", containerRunnerElement.getAttribute("runner"));
} else {
defBuilder.addPropertyValue("runner", CommandLineContainerRunner.class);
}
YarnNamespaceUtils.setValueIfAttributeDefined(defBuilder, containerRunnerElement, "context-file", false, "container-context.xml");
YarnNamespaceUtils.setValueIfAttributeDefined(defBuilder, containerRunnerElement, "bean-name", false, YarnSystemConstants.DEFAULT_ID_CONTAINER);
YarnNamespaceUtils.setReferenceIfAttributeDefined(defBuilder, containerRunnerElement, "arguments");
YarnNamespaceUtils.setValueIfAttributeDefined(defBuilder, containerRunnerElement, "stdout", false, "<LOG_DIR>/Container.stdout");