Signal Expression is not considered while creating xml from BPMNModel object

In my application, I generate the BPMNModel object thorough the java api’s.
Then pass the bytearray of the same for the deployment.

I have a requirement where i need to have IntermediateSignalCatchEvent with the signal name as dynamic.
For this i used : org.flowable.bpmn.model.SignalEventDefinition#setSignalExpression method.
SignalEventDefinition definition = new SignalEventDefinition();
I observed that the BPMNModel object has the information about the signalExpression.

But when I use org.flowable.bpmn.converter.BpmnXMLConverter#convertToXML(org.flowable.bpmn.model.BpmnModel) to generate the byte array
The generate byte array does not have the information about the signalExpression and only the empty signalEventDefinition tag is present.

On debugging I found that the following code does not appear to consider the signalExpression from the SignalEventDefinition object.

protected void writeSignalDefinition(Event parentEvent, SignalEventDefinition signalDefinition, XMLStreamWriter xtw) throws Exception {
writeDefaultAttribute(ATTRIBUTE_SIGNAL_REF, signalDefinition.getSignalRef(), xtw);
if (parentEvent instanceof ThrowEvent && signalDefinition.isAsync()) {
BpmnXMLUtil.writeQualifiedAttribute(ATTRIBUTE_ACTIVITY_ASYNCHRONOUS, “true”, xtw);
boolean didWriteExtensionStartElement = BpmnXMLUtil.writeExtensionElements(signalDefinition, false, xtw);
if (didWriteExtensionStartElement) {

Is this the intended behavior or is it a bug?
If it is the intended behavior then can you please share the info as to how i can add the signalExpression to the finale byte array?

Correct analysis, that is indeed a bug. Fixed it here: (thanks for pointing in the right direction!).

Thanks for your confirmation.


I am a user on flowable forum and when posting new question, getting message ‘Sorry, new users can only mention 2 users in a post’ thus unable to create any topic/post new question.
I am messaging only 1 admin user and even with no user , I am getting above message. Kindly help me to start posting questions.