Skip to Content

Combine Single Values and replace the values in Incoming Message

Hello Experts,

I have a scenario where i need to replace string Value from different branches in the main message.

Branch 1: Single Value :


Branch 2: Single Value:


Branch 3: Main Message">










I need to replace the String Values with node <pkp> and <bkp> in the main message payload.

Can anybody please advice how it can be done.



image1.jpg (33.5 kB)
Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

2 Answers

  • Best Answer
    Jan 23, 2018 at 08:19 AM


    You can store single values from branch 1 & 2 in property/header of a content modifier. And then create branch 3 message body using that property/header inside a second content modifier.





    Add comment
    10|10000 characters needed characters exceeded

  • Jan 30, 2018 at 11:29 AM

    Another more complex solution, if the other one doesn't work:

    With the incoming data - You could store one value in a message header, one value in a message exchange property and one value in the body to keep them separate. To replace the string values you could use a Groovy Script and manipulate the properties using the tags:

    def message_body = message.getBody();

    def message_headers= message.getHeaders();

    branch1Val = flow_headers.get("branch1Val");

    def message_properties = message.getProperties();

    branch2Val = flow_properties.get("exprop2");

    Then combine them within the script as you please. Using a substring function to find and replace the text between <pkp> </pkp> , and <bkp> </bkp>

    Add comment
    10|10000 characters needed characters exceeded