Hi,
I am currently executing a DMF project from my code with:
DMFQuickImportExport::doPGImport(defintionGroup, executionId, true);
This works great, but it runs synchronous. I want to run it in batch mode. I tried the following (DMFBatchImporter):
public void runInBatchMode(DMFExecutionId executionId, str definitionGroup) { BatchHeader batchHeader; BatchInfo localBatchInfo; DMFBatchImporter importAsBatch = new DMFBatchImporter(); importAsBatch.parmExecutionId(executionId); importAsBatch.parmReadyForBatchRun(true); SysRecurrenceData sysRecurrenceData = SysRecurrence::defaultRecurrence(); sysRecurrenceData = SysRecurrence::setRecurrenceEndAfter(sysRecurrenceData, 1); localBatchInfo = importAsBatch.batchinfo(); localBatchInfo.parmGroupId(definitionGroup); batchHeader = batchHeader::construct(); batchHeader.addTask(importAsBatch); batchHeader.parmRecurrenceData(sysRecurrenceData); batchHeader.save(); info("Batch job created"); }
The batch job kicks off, but never finishes. The data is stuck in Pending status:
Any thoughts?
Thanks.