if(processEngineLookup == null) {
throw new ActivitiException("Could not find an implementation of the org.activiti.cdi.spi.ProcessEngineLookup service " +
"returning a non-null processEngine. Giving up.");
}
ActivitiServices activitiServices = ProgrammaticBeanLookup.lookup(ActivitiServices.class, beanManager);
activitiServices.setProcessEngine(processEngine);
return processEngine;
}