BpmPlatform or ManagedProcessingEngineFactory

Hi

Can anyone explained to be about the differences between getting ProcessEngine from BpmPlatform and ManagedProcessEngineFactoryBean?

Hi @Brandon,

It just depends just what your aim is and which Camunda setup/technologies you use. The ManagedProcessEngineFactoryBean is to configure a Container-Managed Process Engine as a Spring Bean, whereas the BpmPlatform is one possibility to access the camunda BPM platform services.

Best
Johannes

Hi @JoHeinem,

Thanks for the reply.

I just want to have a simple container managed process engine Spring MVC web application. However, it is very confusing for me when I see difference bean usage in documentation and example.

In the documentation https://docs.camunda.org/manual/7.6/user-guide/spring-framework-integration/configuration/#configure-a-container-managed-process-engine-as-a-spring-bean
It shows that in Spring, container managed application must use https://docs.camunda.org/javadoc/camunda-bpm-platform/7.6/org/camunda/bpm/engine/spring/container/ManagedProcessEngineFactoryBean.html

Where as in the example https://docs.camunda.org/get-started/spring/shared-process-engine/#alternative-configuration-using-shared-process-engine
It shows that in bean configuration bootstrapped with https://docs.camunda.org/javadoc/camunda-bpm-platform/7.6/org/camunda/bpm/BpmPlatform.html

Hence my confusion.

Can you point me to the right direction for my simple Spring web application?
How should I bootstrap my Spring webapp? Using BpmPlatform or ManagedProcessEngineFactoryBean to get my ProcessEngine?

Hi @Brandon,

I have to admit that this is not clear from the documentation. I’ll try to shed some light into that matter.

You use this version if an engine does not exist yet and you want to bootstrap the engine using Spring. The ManagedProcessEngineFactoryBean is actually also just registering the engine with the BpmPlatform.

In the example the engine is already bootstrap with the following line:

<bean id="processApplication" class="org.camunda.bpm.engine.spring.application.SpringServletProcessApplication" />

Because the engine is already bootstraped and registered as a service, you can just retrieve it from the BpmPlatform.

As a side mark: actually it does not matter how you bootstrap the engine and then retrieve it. Both ways are fine.

Hope that helps :slight_smile:

Best
Johannes