Hi, we debugged the source code for this problem,we found the program will run the following code when the workflow with run_config,
Code: Select all	public void runProcessDefinition() {
		if (drawed) {
			if (manager.getValidationProcessor().validate()) {
				runProcessDefinitionWithValues();
			} else {
				workflowWidgetToFire.hasPendingProcessDefinitionForms();
			}
		} else {
			getProcessDefinitionForms(name);
		}
	}
 
the condition, manager.getValidationProcessor().validate(),will return true, so it will call runProcessDefinitionWithValues() which create a workflow instance, but manager.getValidationProcessor().validate() as following:
Code: Select allpublic boolean validate(List<String> uuids, String... names) {
		this.uuids = uuids;
		result = true;
		pluginsValidated = 0;
		result = result && super.validate(names);
		// Always evaluate plugins rpc calls at ends
		if (plugins > 0 && validatorToFire != null) {
			waitUntilValidatorsFinished();
		} else if (plugins == 0 && validatorToFire != null) {
			validatorToFire.validationWithPluginsFinished(result);
		}
		return result;
	}
 
it will call the validatorToFire.validationWithPluginsFinished(result), this funciton also includes a runProcessDefinitionWithValues()  as following:
Code: Select all	public void validationWithPluginsFinished(boolean result) {
		if (result) {
			runProcessDefinitionWithValues();
		} else {
			workflowWidgetToFire.hasPendingProcessDefinitionForms();
		}
	}
 
it will again call runProcessDefinitionWithValues() which will create second workflow instance.
I did not understand  function of manager.getValidationProcessor().validate(), so why it need call runProcessDefinitionWithValues() again. May it is a bug or my configuration issue?