Generate dynamic business key


#1

How to generate dynamic business key in Camunda modeler?
I’ve tried to put something like this in business key value -> something_${object.getId().toString()} but it doesn’t work (it prints value as string).

Can anyone help me about this?
Thank you in advance.


#2

Hi @hedza06,

where do you want to set the business key?

Best regards,
Philipp


#3

Hello @Philipp_Ossler,
I want to set business key on activity (Camunda Modeler, field Business Key).

Best regards.


#4

I assume that you want to set the business key at a call activity. The business key expression must have the form ${execution.processBusinessKey}. If you want to concatenate two strings then you can write ${"somthing_".concat(object.getId())}. Or you can build the key previously using your favorite language (e.g. JavaScript).

Does it works for you?

Best regards,
Philipp


#5

@Philipp_Ossler this works perfect! Thank you very much!