Fix bug (#4239)
This commit is contained in:
parent
6cf5989d6c
commit
511d3e15df
|
@ -32,6 +32,7 @@ import org.springframework.context.annotation.Import;
|
||||||
import javax.annotation.PostConstruct;
|
import javax.annotation.PostConstruct;
|
||||||
|
|
||||||
import static ca.uhn.fhir.mdm.batch2.clear.MdmClearAppCtx.MDM_CLEAR_JOB_BEAN_NAME;
|
import static ca.uhn.fhir.mdm.batch2.clear.MdmClearAppCtx.MDM_CLEAR_JOB_BEAN_NAME;
|
||||||
|
import static ca.uhn.fhir.mdm.batch2.submit.MdmSubmitAppCtx.MDM_SUBMIT_JOB_BEAN_NAME;
|
||||||
|
|
||||||
@Configuration
|
@Configuration
|
||||||
@Import({
|
@Import({
|
||||||
|
@ -47,7 +48,9 @@ public class MdmBatch2Config {
|
||||||
|
|
||||||
@PostConstruct
|
@PostConstruct
|
||||||
public void start() {
|
public void start() {
|
||||||
JobDefinition jobDefinition = myApplicationContext.getBean(MDM_CLEAR_JOB_BEAN_NAME, JobDefinition.class);
|
JobDefinition clearJobDefinition = myApplicationContext.getBean(MDM_CLEAR_JOB_BEAN_NAME, JobDefinition.class);
|
||||||
myJobDefinitionRegistry.addJobDefinitionIfNotRegistered(jobDefinition);
|
myJobDefinitionRegistry.addJobDefinitionIfNotRegistered(clearJobDefinition);
|
||||||
|
JobDefinition submitJobDefinition = myApplicationContext.getBean(MDM_SUBMIT_JOB_BEAN_NAME, JobDefinition.class);
|
||||||
|
myJobDefinitionRegistry.addJobDefinitionIfNotRegistered(clearJobDefinition);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -35,7 +35,7 @@ import org.springframework.context.annotation.Configuration;
|
||||||
@Configuration
|
@Configuration
|
||||||
public class MdmSubmitAppCtx {
|
public class MdmSubmitAppCtx {
|
||||||
|
|
||||||
private static final String MDM_SUBMIT_JOB_BEAN_NAME = "mdmSubmitJobDefinition";
|
public static final String MDM_SUBMIT_JOB_BEAN_NAME = "mdmSubmitJobDefinition";
|
||||||
public static String MDM_SUBMIT_JOB= "MDM_SUBMIT";
|
public static String MDM_SUBMIT_JOB= "MDM_SUBMIT";
|
||||||
|
|
||||||
@Bean
|
@Bean
|
||||||
|
|
Loading…
Reference in New Issue