Page tree
Skip to end of metadata
Go to start of metadata

There may come a day when you're in need of letting the workflow author be able to decide which input values should go into your custom command and also let him decide how to act on the output value you inject back into the workflow xml. Thanks to this article you'll be perfectly prepared in case of emergency.

 

<!-- set an input parameter -->
<set field="myField" value="myValue"/>
 
<!-- call custom command -->
<participant ref="command-catalogName-commandName"/>
// read the input parameter
String myField = (String) ctx.get("myField");
 
// inject field into workflow xml
ctx.put("myCustomField", "myCustomValue");
<!-- access the injected field -->
${field:myCustomField}

The custom command has to implement the Interface org.apache.commons.chain.Command.

 

Further information about workflow and commands can be found here:

  • No labels