* @throws Exception
*/
public void createBatchDirector(Flow flow) throws Exception {
if (batch.getBatchDirector() == null) {
Workspace wspace = (flow == null) ? null : flow.workspace();
Director director = DirectorFactory.createNewDirector(
(useNexusStorage) ? DirectorType.RECORDING
: DirectorType.SOLEILSTD, wspace);
batch.setBatchDirector(director);
}
if (flow != null) {