cancel
Showing results for 
Search instead for 
Did you mean: 

Default camelBehaviorClass

sdeschenes
Champ in-the-making
Champ in-the-making
Hi,

In CamelBehavior javadoc it is written:

<blockcode>
The chosen implementation should be set within your ProcessEngineConfiguration. To specify the implementation using Spring, include the following line in your configuration file as part of the properties for "org.activiti.spring.SpringProcessEngineConfiguration":

<property name="camelBehaviorClass" value="org.activiti.camel.impl.CamelBehaviorCamelBodyImpl"/>
</blockcode>

Can you provide an example of that? Can you explain how it works?

Thanks in avance!
5 REPLIES 5

jbarrez
Star Contributor
Star Contributor
there should be multiple examples in the unit tests in the activiti-camel module

sdeschenes
Champ in-the-making
Champ in-the-making
Probably I don't know where to look for it, but I didn't see any SpringProcessEngineConfiguration definition that have a property named "camelBehaviorClass".

It is specified at the process level, but not on the engine Configuration. And, if I understand well what is happening in DefaultActivityBehaviorFactory the default class is instanciated direcly with "Class.forName()". So it never look on the engine configuration.

The only possible solution is that the engine is injecting the property to the FieldExtensions directly. But, even that, there's no way to set the property on the SprinEngineConfiguration directly. This is why I ask. Smiley Happy

jbarrez
Star Contributor
Star Contributor
This is what I found whne doing a global search:
https://github.com/Activiti/Activiti/blob/master/modules/activiti-camel/src/test/resources/process/H... and https://github.com/Activiti/Activiti/blob/master/modules/activiti-camel/src/test/resources/process/H...

I don't see the way that is mentioned in the docs though, by setting it on the process engine config …

jbarrez
Star Contributor
Star Contributor
This is what I found whne doing a global search:
https://github.com/Activiti/Activiti/blob/master/modules/activiti-camel/src/test/resources/process/H... and https://github.com/Activiti/Activiti/blob/master/modules/activiti-camel/src/test/resources/process/H...

I don't see the way that is mentioned in the docs though, by setting it on the process engine config …

sdeschenes
Champ in-the-making
Champ in-the-making
Thank you, it confirm what I was thinking.

The javadoc should be adjusted or the property added to  the process engine to represent that. Smiley Happy