In my project ,use camunda 7.x version. I have a business logic.
1.Call camunda.completeTask
2.My application add @SpringEvent to listen TaskEven(i can listen create delete and complete event notify).
But,the camunda throw exception:
1.when approve remark length greater than 4000
2.when workflowe exists error config(for example error expression)
Exception stack at this file org.camunda.bpm.engine.impl.persistence.entity.TaskEntity .
Look at the code ,i see line 321 fire event and 340 execute entity.
1.line 321 fire event and my applicaiton listen task event and operate my databse.
2.line 340 throw exception ,when match the scenario my listed.
My problem is that in my program has been invoke event and save data to databse(my database is MongoDB,by spring event after TaskEntity class fire event), but Camunda has an exception(at TaskEntity line 340). How can I ensure that my application’s transactions are consistent with Camunda’s transactions?