private void processPartitionedJob(Module module) {
if (logger.isDebugEnabled()) {
logger.debug("binding job partitioning channels for " + module);
}
Properties[] properties = extractConsumerProducerProperties(module);
MessageChannel partitionsOut = module.getComponent(JOB_PARTIONER_REQUEST_CHANNEL, MessageChannel.class);
Assert.notNull(partitionsOut, "Partitioned jobs must have a " + JOB_PARTIONER_REQUEST_CHANNEL);
MessageChannel partitionsIn = module.getComponent(JOB_PARTIONER_REPLY_CHANNEL, MessageChannel.class);
Assert.notNull(partitionsIn, "Partitioned jobs must have a " + JOB_PARTIONER_REPLY_CHANNEL);
ModuleDescriptor descriptor = module.getDescriptor();
String name = descriptor.getGroup() + "." + descriptor.getIndex();
messageBus.bindRequestor(name, partitionsOut, partitionsIn, properties[0]);
MessageChannel stepExecutionsIn = module.getComponent(JOB_STEP_EXECUTION_REQUEST_CHANNEL, MessageChannel.class);
Assert.notNull(stepExecutionsIn, "Partitioned jobs must have a " + JOB_STEP_EXECUTION_REQUEST_CHANNEL);
MessageChannel stepExecutionResultsOut = module.getComponent(JOB_STEP_EXECUTION_REPLY_CHANNEL,
MessageChannel.class);
Assert.notNull(stepExecutionResultsOut, "Partitioned jobs must have a " + JOB_STEP_EXECUTION_REPLY_CHANNEL);
messageBus.bindReplier(name, stepExecutionsIn, stepExecutionResultsOut, properties[1]);
}