Free Trial

Safari Books Online is a digital library providing on-demand subscription access to thousands of learning resources.

  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint
Share this Page URL
Help

6. Flow Components > Filters

Filters

Consumers have different message requirements, with some wanting one type of message and others wanting a different type. Spring Integration Framework uses Filters and sets up criteria to decide which applications should receive the messages and which should not.

Let’s look at an example of Trades being published onto a trades-in-channel, which is configured to receive all types of Trades published by producers.

This requirement can be fulfilled in two ways without using Framework.

  • Create and configure NewTradeConsumer to only pick up messages with tradeType=NEW and throw away everything else, and create and configure CancelTradeReceiver to only consume Trades with tradeType=CANCEL.


  

You are currently reading a PREVIEW of this book.

                                                                                                                    

Get instant access to over $1 million worth of books and videos.

  

Start a Free 10-Day Trial


  
  • Safari Books Online
  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint