use of org.jbpm.runtime.manager.impl.deploy.DeploymentDescriptorManager in project jbpm by kiegroup.
the class TransactionalCommandServiceProducer method produceAuditCommandService.
@Produces
@Audit
public TransactionalCommandService produceAuditCommandService() {
DeploymentDescriptorManager manager = new DeploymentDescriptorManager("org.jbpm.domain");
DeploymentDescriptor descriptor = manager.getDefaultDescriptor();
if (!"org.jbpm.domain".equals(descriptor.getAuditPersistenceUnit())) {
return new TransactionalCommandService(EntityManagerFactoryManager.get().getOrCreate(descriptor.getAuditPersistenceUnit()));
}
return new TransactionalCommandService(emf);
}
Aggregations