use of org.camunda.bpm.engine.impl.migration.MigrationInstructionGenerator in project camunda-bpm-platform by camunda.
the class CreateMigrationPlanCmd method generateInstructions.
protected List<MigrationInstruction> generateInstructions(CommandContext commandContext, ProcessDefinitionImpl sourceProcessDefinition, ProcessDefinitionImpl targetProcessDefinition, boolean updateEventTriggers) {
ProcessEngineConfigurationImpl processEngineConfiguration = commandContext.getProcessEngineConfiguration();
// generate instructions
MigrationInstructionGenerator migrationInstructionGenerator = processEngineConfiguration.getMigrationInstructionGenerator();
ValidatingMigrationInstructions generatedInstructions = migrationInstructionGenerator.generate(sourceProcessDefinition, targetProcessDefinition, updateEventTriggers);
// filter only valid instructions
generatedInstructions.filterWith(processEngineConfiguration.getMigrationInstructionValidators());
return generatedInstructions.asMigrationInstructions();
}
Aggregations