MessageSelector Example

The MessageSelector example contains an adapter configuration, a business process and a JMS connection. The example shows how to use JMS trigger messages to transfer files in SFT mode.

The adapter configuration is MessageSelector.adfilesmodel, the business process is TriggerMessageSelector.bwp. After the TriggerMessageSelector.bwp process starts, the JMS topic publisher sends a JMS message to the messagePub topic. Publication Service is triggered and sends the ftp_ecm.txt file to the selected subscribers. The JMS connection is used by the JMS topic publisher.

The MessageSelector.adfilesmodel contains a Publication Service service and two Subscription Service services.
  • PublicationService

    Publication Service parses the ftp_ecm.txt file. The transfer mode is Simple File Transfer, the life cycle is Repeating, the polling method is JMS (topic) Message, and the polling destination is messagePub. When Publication Service is triggered, it publishes the file content to the selected subscribers.

  • SubscriptionService

    Subscription Service subscribes to messages and writes them to the outselector.txt file. The transfer mode is Simple File Transfer, and the polling method is JMS (topic) Message.

    The JMS message selector specified on the SubscriptionService endpoint is as follows:

    (Branch = 'New York' OR Branch = 'ALL') AND ((SalesUpper >= 30
    AND SalesUpper <= 70) OR SalesVolume = 'ALL')
  • SubscriptionService1

    Subscription Service subscribes to messages and writes them to the outselector1.txt file. The transfer mode is Simple File Transfer, and the polling method is JMS (topic) Message.

    The JMS message selector specified on the SubscriptionService1 endpoint is as follows:

    Branch IN ('Boston','ALL') AND ((SalesUpper >= 20 AND SalesUpper
    <= 50) OR SalesVolume = 'ALL')