how to stop message from being sent to next solace topic while going through chain of function?

ajinkyasagar Member Posts: 24
edited June 2022 in General Discussions #1

how to stop message from being sent to next solace topic while going through chain of function?


inTechVal|inFuncVal|map|persist|report-in-0: input
inTechVal|inFuncVal|map|persist|report-out-0: output

here message goes through inTechVal|inFuncVal|map|persist|report all of these functions but if i want to terminate and drop message in between how i can do it with solace streaming?


  • giri
    giri Member, Administrator, Employee Posts: 99 admin

    Hi @ajinkyasagar

    This is an interesting question indeed - first I want to draw the distinction between function composition and integration flows. If you would like to wield control over the flow in terms of message ack, drop or skip processing, Spring Integration would be a good choice. Spring Cloud Steam's function composition is just to sequence the execution via the use of one or more functions - and not necessarily a flow. If you notice the error channels are associated with the composed function (as a single entity), rather than at a function level.

    Essentially, a function definition

    inTechVal|inFuncVal|map|persist|report-in-0: input

    would execute each of the functions before returning the outcome at the application level.

    However, this can be managed at a logical level with custom property in the MesageHeader and Client Acknowledgement. The logic has to be composed entirely in the Spring boot application.

    Please refer to the response to a similar question by Oleg Zhurakousky, a prominent member of Spring team here -

    I have put together a quick sample on how you might be able to manage this at the application level for function composition. Hope this helps.


    This is just an approach - Let me know if this serves your purpose.