+ All Categories
Home > Documents > TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet -...

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet -...

Date post: 19-Oct-2020
Category:
Upload: others
View: 10 times
Download: 0 times
Share this document with a friend
84
TIBCO ActiveMatrix ® Adapter for SWIFTNet - FIN Examples Software Release 5.11 August 2013 Two-Second Advantage ®
Transcript
Page 1: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix® Adapter for SWIFTNet - FIN

ExamplesSoftware Release 5.11 August 2013

Two-Second Advantage®

Page 2: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

Important Information

SOME TIBCO SOFTWARE EMBEDS OR BUNDLES OTHER TIBCO SOFTWARE. USE OF SUCH EMBEDDED OR BUNDLED TIBCO SOFTWARE IS SOLELY TO ENABLE THE FUNCTIONALITY (OR PROVIDE LIMITED ADD-ON FUNCTIONALITY) OF THE LICENSED TIBCO SOFTWARE. THE EMBEDDED OR BUNDLED SOFTWARE IS NOT LICENSED TO BE USED OR ACCESSED BY ANY OTHER TIBCO SOFTWARE OR FOR ANY OTHER PURPOSE.USE OF TIBCO SOFTWARE AND THIS DOCUMENT IS SUBJECT TO THE TERMS AND CONDITIONS OF A LICENSE AGREEMENT FOUND IN EITHER A SEPARATELY EXECUTED SOFTWARE LICENSE AGREEMENT, OR, IF THERE IS NO SUCH SEPARATE AGREEMENT, THE CLICKWRAP END USER LICENSE AGREEMENT WHICH IS DISPLAYED DURING DOWNLOAD OR INSTALLATION OF THE SOFTWARE (AND WHICH IS DUPLICATED IN LICENSE.PDF) OR IF THERE IS NO SUCH SOFTWARE LICENSE AGREEMENT OR CLICKWRAP END USER LICENSE AGREEMENT, THE LICENSE(S) LOCATED IN THE “LICENSE” FILE(S) OF THE SOFTWARE. USE OF THIS DOCUMENT IS SUBJECT TO THOSE TERMS AND CONDITIONS, AND YOUR USE HEREOF SHALL CONSTITUTE ACCEPTANCE OF AND AN AGREEMENT TO BE BOUND BY THE SAME.This document contains confidential information that is subject to U.S. and international copyright laws and treaties. No part of this document may be reproduced in any form without the written authorization of TIBCO Software Inc.TIBCO, Two-Second Advantage, TIBCO, The Power of Now, TIBCO ActiveMatrix BusinessWorks, TIBCO ActiveEnterprise, TIBCO Rendezvous, TIBCO Designer, TIBCO Administrator, TIBCO Adapter SDK, TIBCO Runtime Agent, TIBCO ActiveMatrix Adapter, TIBCO ActiveMatrix Adapter for MQSeries, TIBCO Enterprise Message Service, and TIBCO Hawk are either registered trademarks or trademarks of TIBCO Software Inc. in the United States and/or other countries.Enterprise Java Beans (EJB), Java Platform Enterprise Edition (Java EE), Java 2 Platform Enterprise Edition (J2EE), and all Java-based trademarks and logos are trademarks or registered trademarks of Oracle Corporation in the U.S. and other countries.All other product and company names and marks mentioned in this document are the property of their respective owners and are mentioned for identification purposes only.THIS SOFTWARE MAY BE AVAILABLE ON MULTIPLE OPERATING SYSTEMS. HOWEVER, NOT ALL OPERATING SYSTEM PLATFORMS FOR A SPECIFIC SOFTWARE VERSION ARE RELEASED AT THE SAME TIME. SEE THE README.TXT FILE FOR THE AVAILABILITY OF THIS SOFTWARE VERSION ON A SPECIFIC OPERATING SYSTEM PLATFORM.THIS DOCUMENT IS PROVIDED “AS IS” WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESS OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE, OR NON-INFRINGEMENT.THIS DOCUMENT COULD INCLUDE TECHNICAL INACCURACIES OR TYPOGRAPHICAL ERRORS. CHANGES ARE PERIODICALLY ADDED TO THE INFORMATION HEREIN; THESE CHANGES WILL BE INCORPORATED IN NEW EDITIONS OF THIS DOCUMENT. TIBCO SOFTWARE INC. MAY MAKE IMPROVEMENTS AND/OR CHANGES IN THE PRODUCT(S) AND/OR THE PROGRAM(S) DESCRIBED IN THIS DOCUMENT AT ANY TIME.THE CONTENTS OF THIS DOCUMENT MAY BE MODIFIED AND/OR QUALIFIED, DIRECTLY OR INDIRECTLY, BY OTHER DOCUMENTATION WHICH ACCOMPANIES THIS SOFTWARE, INCLUDING BUT NOT LIMITED TO ANY RELEASE NOTES AND "READ ME" FILES.Copyright © 1998-2013 TIBCO Software Inc. ALL RIGHTS RESERVED.TIBCO Software Inc. Confidential Information

Page 3: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

| iii

Contents

Figures . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .vii

Preface . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . ix

Related Documentation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . xTIBCO ActiveMatrix Adapter for SWIFTNet - FIN Documentation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . xOther TIBCO Product Documentation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . x

Typographical Conventions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . xi

Connecting with TIBCO Resources . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .xivHow to Join TIBCOmmunity . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .xivHow to Access TIBCO Documentation. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .xivHow to Contact TIBCO Support . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .xiv

Chapter 1 Introduction to Examples . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .1

Examples Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2

Prerequisites for Running the Examples . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3Using TIBCO ActiveMatrix BusinessWorks . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4Working with DAT Files in TIBCO Designer . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4Examples Location . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6

Chapter 2 TIBCO ActiveMatrix BusinessWorks: Requesting Stop Payment of a Cheque by the Drawer Bank . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .7

Example Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8

Setting Up the Example . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9

Testing the Example. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10

Expected Results . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13

Chapter 3 TIBCO ActiveMatrix BusinessWorks: Buying Shares over the SWIFT Network. . . .15

Example Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16

Setting up the Example . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17

Testing the Example. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18

Expected Results . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19

Chapter 4 TIBCO ActiveMatrix BusinessWorks: Sending a Message Directly to a Financial

Page 4: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

iv | Contents

Institution . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 27

Example Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28

Setting Up the Example . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29

Testing the Example . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 30

Expected Results . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 31

Chapter 5 TIBCO ActiveMatrix BusinessWorks: Exchange of Query and Answer Statements33

Example Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 34

Setting Up the Example . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 35

Testing the Example . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 36

Expected Results . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 37

Chapter 6 TIBCO ActiveMatrix BusinessWorks SWIFT Plug-in: Router and Parser Activities 39

Example Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 40

Setting Up the Example . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 42

Testing the Example . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 43

Expected Results . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 45

Chapter 7 TIBCO ActiveMatrix BusinessWorks SWIFT Plug-in: Renderer Activity . . . . . . . . . 47

Example Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 48

Setting Up the Example . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 49

Testing the Example . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 50

Expected Results . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 51

Chapter 8 TIBCO ActiveMatrix BusinessWorks SWIFT Plug-in: BICPlusIBAN Generator and Validator Activities . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 53

Example Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 54

Setting Up the Example . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 56

Testing the Example . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 59

Expected Results . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 60

Chapter 9 TIBCO ActiveMatrix BusinessWorks SWIFT Plug-In: Exchange of Messages Using SOAP Protocol . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 63

Example Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 64

Setting Up the Example . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 66

Testing the Example . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 67

Expected Results . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 68

Page 5: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

Contents | v

Index . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .69

Page 6: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

vi | Contents

Page 7: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

Figures | vii

Figures

Figure 1 Modifying the Tester TRA File . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11

Figure 2 StopPaymentCheque Process in TIBCO ActiveMatrix BusinessWorks . . . . . . . . . . . . . . . . . . . . . . 12

Figure 3 TIBCO ActiveMatrix BusinessWorks SWIFT Plug-in: Router and Parser Activities . . . . . . . . . . . . . 40

Figure 4 Extracted Information from the FIN Messages. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 44

Figure 5 TIBCO ActiveMatrix BusinessWorks SWIFT Plug-in: Renderer Activity . . . . . . . . . . . . . . . . . . . . . 48

Figure 6 SWIFT BICPlusIBAN Generation. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 54

Figure 7 SWIFT BICPlusIBAN Validation. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 55

Figure 8 Configuring the SWIFT BICPlusIBAN Generator . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 57

Figure 9 Configuring the SWIFT BICPlusIBAN Validator . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 58

Figure 10 Output of the SWIFT BICPlusIBAN Generation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 60

Figure 11 Output of the SWIFT BICPlusIBAN Validation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 61

Figure 12 Messages Exchange through SOAP Protocol . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 64

Page 8: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

viii | Figures

Page 9: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

| ix

Preface

This guide contains examples to further your understanding of TIBCO ActiveMatrix Adapter for SWIFTNet - FIN. The preface lists important requirements and conventions.

Topics

• Related Documentation, page x

• Typographical Conventions, page xi

• Connecting with TIBCO Resources, page xiv

Page 10: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

x | Related Documentation

Related Documentation

This section lists documentation resources you may find useful.

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN DocumentationThe following documents form the TIBCO ActiveMatrix Adapter for SWIFTNet - FIN documentation set.

• TIBCO ActiveMatrix Adapter for SWIFT Installation Read this manual for instructions on site preparation and installation.

• TIBCO ActiveMatrix Adapter for SWIFTNet - FIN User’s Guide Read this manual for the concepts relating to the adapter, the applications with which the adapter interacts, configuration and deployment information.

• TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples Guide Read this manual to work through the examples provided with the adapter.

• TIBCO ActiveMatrix Adapter for SWIFT Release Notes Read this release notes for a list of new and changed features. This document also contains lists of closed and known issues (in both the SWIFTNet and SWIFTNet - FIN Adapter components) for this release.

Other TIBCO Product DocumentationYou may find it useful to read the documentation for the following TIBCO products:

• TIBCO ActiveEnterprise™

• TIBCO ActiveMatrix Adapter™ for MQSeries

• TIBCO ActiveMatrix BusinessWorks™

• TIBCO® Adapter SDK

• TIBCO Administrator™

• TIBCO Designer™

• TIBCO Enterprise Message Service™

• TIBCO Hawk®

• TIBCO Rendezvous®

• TIBCO Runtime Agent™

Page 11: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

Preface | xi

Typographical Conventions

The following typographical conventions are used in this manual.

Table 1 General Typographical Conventions

Convention Use

TIBCO_HOME

ENV_NAME

TIB_ADSWIFT_HOME

CONFIG_HOME

TIBCO products are installed into an installation environment. A product installed into an installation environment does not access components in other installation environments. Incompatible products and multiple instances of the same product must be installed into different installation environments.

An installation environment consists of the following properties:

• Name Identifies the installation environment. This name is referenced in documentation as ENV_NAME. On Microsoft Windows, the name is appended to the name of Windows services created by the installer and is a component of the path to the product shortcut in the Windows Start > All Programs menu.

• Path The directory into which the product is installed. This directory is referenced in documentation as TIBCO_HOME. The value of TIBCO_HOME depends on the operating system. For example, on Windows systems the default value is C:\tibco.

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN is installed into a directory within TIBCO_HOME. This directory is referenced in documentation as TIB_ADSWIFT_HOME. The default value of TIBCO_ADSWIFT_HOME depends on the operating system. For example, on Windows systems, the default value is C:\tibco\adapter\adswift\version.

A TIBCO configuration directory stores configuration data generated by TIBCO products. Configuration data can include sample scripts, session data, configured binaries, logs, and so on. This directory is referenced in documentation as CONFIG_HOME. The default location of the directory is USER_HOME\ENV_NAME\tibco\cfgmgmt\product_name. For example, on Windows, the default location is C:\Documents and Settings\username\Application Data\ENV_NAME\tibco\cfgmgmt\product_name.

code font Code font identifies commands, code examples, filenames, pathnames, and output displayed in a command window. For example:

Use MyCommand to start the foo process.

Page 12: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

xii | Typographical Conventions

bold code font Bold code font is used in the following ways:

• In procedures, to indicate what a user types. For example: Type admin.

• In large code samples, to indicate the parts of the sample that are of particular interest.

• In command syntax, to indicate the default parameter for a command. For example, if no parameter is specified, MyCommand is enabled: MyCommand [enable | disable]

italic font Italic font is used in the following ways:

• To indicate a document title. For example: See TIBCO ActiveMatrix BusinessWorks Concepts.

• To introduce new terms. For example: A portal page may contain several portlets. Portlets are mini-applications that run in a portal.

• To indicate a variable in a command or code syntax that you must replace. For example: MyCommand PathName

Key combinations Key name separated by a plus sign indicate keys pressed simultaneously. For example: Ctrl+C.

Key names separated by a comma and space indicate keys pressed one after the other. For example: Esc, Ctrl+Q.

The note icon indicates information that is of special interest or importance, for example, an additional action required only in certain circumstances.

The tip icon indicates an idea that could be useful, for example, a way to apply the information provided in the current section to achieve a specific result.

The warning icon indicates the potential for a damaging situation, for example, data loss or corruption if certain steps are taken or not taken.

Table 1 General Typographical Conventions (Cont’d)

Convention Use

Page 13: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

Preface | xiii

Table 2 Syntax Typographical Conventions

Convention Use

[ ] An optional item in a command or code syntax.

For example:

MyCommand [optional_parameter] required_parameter

| A logical OR that separates multiple items of which only one may be chosen.

For example, you can select only one of the following parameters:

MyCommand param1 | param2 | param3

{ } A logical group of items in a command. Other syntax notations may appear within each logical group.

For example, the following command requires two parameters, which can be either the pair param1 and param2, or the pair param3 and param4.

MyCommand {param1 param2} | {param3 param4}

In the next example, the command requires two parameters. The first parameter can be either param1 or param2 and the second can be either param3 or param4:

MyCommand {param1 | param2} {param3 | param4}

In the next example, the command can accept either two or three parameters. The first parameter must be param1. You can optionally include param2 as the second parameter. And the last parameter is either param3 or param4.

MyCommand param1 [param2] {param3 | param4}

Page 14: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

xiv | Connecting with TIBCO Resources

Connecting with TIBCO Resources

How to Join TIBCOmmunityTIBCOmmunity is an online destination for TIBCO customers, partners, and resident experts. It is a place to share and access the collective experience of the TIBCO community. TIBCOmmunity offers forums, blogs, and access to a variety of resources. To register, go to http://www.tibcommunity.com.

How to Access TIBCO DocumentationYou can access TIBCO documentation here:

http://docs.tibco.com

How to Contact TIBCO SupportFor comments or problems with this manual or the software it addresses, contact TIBCO Support as follows.

• For an overview of TIBCO Support, and information about getting started with TIBCO Support, visit this site:

http://www.tibco.com/services/support

• If you already have a valid maintenance or support contract, visit this site:

https://support.tibco.com

Entry to this site requires a username and password. If you do not have a username, you can request one.

Page 15: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

| 1

Chapter 1 Introduction to Examples

This chapter contains an overview of the examples and lists the prerequisites needed to run the examples.

Topics

• Examples Overview, page 2

• Prerequisites for Running the Examples, page 3

Page 16: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

2 | Chapter 1 Introduction to Examples

Examples Overview

The following examples demonstrate the integration between the adapter and TIBCO ActiveMatrix BusinessWorks. We have chosen common business scenarios to build an end-to-end enterprise wide integration and demonstrate the adapter capabilities. These business scenarios are:

• Requesting stop payment of the cheque by the drawer bank.

• Buying of shares over the SWIFT network.

• Ordering institutions sending messages directly to the financial institution of the beneficiary.

• Exchange of Query and Answer Statements for a particular Bank Statement received from SWIFT.

The following tables show the business scenarios, the corresponding SWIFT message types used to develop the respective business scenario, the repository file name in which the example is implemented and the type of transport used.

Table 3 Business scenarios used in the TIBCO AciveMatrix BusinessWorks Examples

Business Scenario Message Type

Example Configuration File

Type of Transport

Requesting stop payment of the cheque by the drawer bank

MT111

MT112

StopPaymentCheque

.dat

TIBCO Rendezvous (RV)

Buying of shares over the SWIFT network

MT502MT513MT514

BuyShares.zip TIBCO Rendezvous (RVCM)

Ordering institutions sending messages directly to the financial institution of the beneficiary

MT202 OrderFinInstitution.zip

JMS (Topic)

Exchange of Query and Answer Statements for a particular bank statement received from SWIFT

MT950MT995MT996

ExchangeQueryAnswer.zip

JMS Queue

Page 17: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

Prerequisites for Running the Examples | 3

Prerequisites for Running the Examples

There are three interfaces, CASmf, MQSA, and FTP that can be used to communicate with SWIFT Alliance Access (SAA). Prerequisites may be different for each mode.

• The adapter is to be tested with the CASmf mode:

— CASmf must be configured to run Lookback Testing.

• The adapter is to be tested with the MQSA mode:

— SAA server should be installed and configured.

— TIBCO ActiveMatrix Adapter for MQSeries 5.4.1 must be installed and configured for inserting and receiving messages from the MQSeries queue.

— The admqsSample.dat from TIBCO_ADSWIFT_HOME\examples directory contains the sample configuration required for TIBCO ActiveMatrix Adapter for MQSeries to communicate with TIBCO ActiveMatrix Adapter for SWIFT.

• The adapter is to be tested in the FTP mode:

— Attributes under the FTP association must be specified.

See TIBCO ActiveMatrix Adapter for SWIFT Installation and TIBCO ActiveMatrix Adapter for SWIFTNet - FIN User’s Guide for detailed information.

• TIBCO Enterprise for JMS is used as the transport type for the following examples:

— TIBCO ActiveMatrix BusinessWorks: Exchange of Query and Answer Statements

— TIBCO ActiveMatrix BusinessWorks: Sending a Message Directly to a Financial Institution

Start the JMS server before you run these examples.

• The executable files and the TRA files required to run the examples are in the location: TIBCO_ADSWIFT_HOME\bin. The files are:

adswiftSender.exe

adswiftReceiver.exe

adswiftSender.tra

adswiftReceiver.tra

The following executable file and the TRA file are also required, and they are in the location: TIBCO_ADSWIFT_HOME\examples. The files are:

Page 18: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

4 | Chapter 1 Introduction to Examples

Tester.exe

Tester.tra

Using TIBCO ActiveMatrix BusinessWorksIf you are using the adapter with TIBCO ActiveMatrix BusinessWorks, the following software must be installed before running the examples:

• TIBCO ActiveMatrix BusinessWorks™

• TIBCO ActiveMatrix® Adapter for SWIFTNet - FIN

• TIBCO Administrator™

• TIBCO Enterprise Message Service™ (if JMS transport is used)

• TIBCO Rendezvous®

• TIBCO Runtime Agent™

The TIBCO ActiveMatrix BusinessWorks examples use TIBCO Designer to create an Enterprise Archive File (EAR) and TIBCO Administrator Enterprise Edition to deploy the EAR file.

In TIBCO Administrator, make sure all software components needed by the adapter instance are installed on one or more machines that are part of a TIBCO administration domain and that the software is registered in the domain.

• Use the TIBCO Domain Utility to add a machine to a TIBCO Administration Domain.

• In TIBCO Administrator, use the Resource Management > Machines console to register software.

These topics are explained in the TIBCO Administrator documentation set.

Working with DAT Files in TIBCO DesignerYou cannot directly open a DAT file in TIBCO Designer and make modifications to the configurations. To do this, carry out the following steps:

Page 19: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

Prerequisites for Running the Examples | 5

1. Convert the DAT file to a multi-file project.

a. Open TIBCO Designer, then click the Administration tab.

b. Click the Convert DAT to Files button, the Convert DAT To File-Based Project dialog appears. Browse and select the DAT file you want to convert, then click the OK button, it returns back TIBCO Designer Welcome dialog.

2. Click the Open Existing Project button, then browse to the directory where the converted multi-file project is saved and select it.

3. Make configuration changes per your requirements.

4. Select Project > Export Full Project from the Menu. Browse and select the location of the directory you want to save the DAT file to. Ensure that the directory is different from the multi-file project. Enter the name of the project and click the OK button.

Page 20: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

6 | Chapter 1 Introduction to Examples

Examples LocationThe files for the examples along with the sample messages are in the following location:

For TIBCO ActiveMatrix BusinessWorks examples:

TIB_ADSWIFT_HOME\examples\BusinessWorks\Business Scenario

For TIBCO ActiveMatrix BusinessWorks SWIFT Plug-in examples:

TIB_ADSWIFT_HOME\examples\BWPlugin

Page 21: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

| 7

Chapter 2 TIBCO ActiveMatrix BusinessWorks: Requesting Stop Payment of a Cheque by the Drawer Bank

In this example, the drawer bank requests for the stop payment of a cheque using the FTP interface. This example uses TIBCO Rendezvous as the transport type.

Topics

• Example Description, page 8

• Setting Up the Example, page 9

• Testing the Example, page 10

• Expected Results, page 13

This example demonstrates the use of the FTP interface. You can also use the CASmf or MQSA interfaces if required.

Page 22: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

8 | Chapter 2 TIBCO ActiveMatrix BusinessWorks: Requesting Stop Payment of a Cheque by the Drawer Bank

Example Description

This example shows how the adapter's Publication and Subscription services can be used in a TIBCO ActiveMatrix BusinessWorks process. The example has two processes, StopPaymentCheque and StatusStopPayment.

StopPaymentCheque Process

The StopPaymentCheque process uses the adapter’s Subscription service. The events in this process are:

1. The tester publishes the sample message on a specified subject, which triggers the StopPaymentCheque process of TIBCO ActiveMatrix BusinessWorks.

2. TIBCO ActiveMatrix BusinessWorks receives the published message and publishes it on a specified subject on which the SWIFTNet-FINSender is listening.

3. SWIFTNet-FINSender receives the message published by TIBCO ActiveMatrix BusinessWorks and processes it. The message is placed in the remote/error directory of the FTP server, if it is in FTP mode. The message is sent to CASmf or TIBCO ActiveMatrix Adapter for MQSeries, if it is in CASmf mode or in MQSA mode.

StatusStopPayment Process

The StatusStopPayment process uses the adapter’s Publication service. The events in this process are:

1. SWIFTNet - FINReceiver picks the messages from the remote directory of the FTP server if it is in FTP mode, or receives the message from CASmf application if it is in CASmf mode. If in MQSA mode, SWIFTNet-FINReceiver receives the message from TIBCO ActiveMatrix Adapter for MQSeries. SWIFTNet-FINReceiver then publishes the messages on the TIBCO environment on a predefined subject, which triggers the StatusStopPayment process of TIBCO ActiveMatrix BusinessWorks.

2. TIBCO ActiveMatrix BusinessWorks receives the message and publishes it on the TIBCO environment on a specified subject for other applications.

Page 23: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

Setting Up the Example | 9

Setting Up the Example

Before starting the example, you need to complete the following steps to set up the example:

1. Create a directory to store the project: c:\tibco\projects.

2. Start TIBCO Designer, then click the New Empty Project button. The Save Project dialog appears.

3. In the Save Project dialog, click the Browse button and navigate to the project directory you created and specify a name for the project. Then click the OK button.

4. Select Project > Import Full Project from the Menu, then click the ZIP Archive tab. Click the Browse button, and navigate to the TIB_ADSWIF_HOME/examples/BusinessWorks/StopPaymentCheque directory, and then select the ZIP file you want to import. In this example, select StopPaymentCheque, and click the OK button.

5. In the Import-Options dialog, select the Replace Existing Global Variables With Those In Import and Overwrite On Name Conflict radio buttons, and then click the Apply button.

6. Select the SWIFTNet - FINSenderConfiguration and SWIFTNet - FINReceiverConfiguration items, and set the appropriate values for the FTP parameters in the Runtime Connection tab. Make sure that the values of the Remote Directory fields for the sender and the receiver are not the same. Select Project > Save from the Menu.

7. Export the multi-file project to a DAT file by selecting Project > Export Full Project from the Menu. Browse and select the location of the directory you want to save the DAT file to and save it as StopPaymentCheque.dat. Click the OK button.

8. Select the StopPaymentCheque item in the Project panel, then select Tools > Create Project EAR from the Menu. Specify the EAR file location in the File Location field in the Configuration tab, then click the Apply button.

9. Click the EAR icon in the Project panel, then click the Build Archive button in the Configuration tab. This creates an archive file.

10. Exit TIBCO Designer.

Page 24: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

10 | Chapter 2 TIBCO ActiveMatrix BusinessWorks: Requesting Stop Payment of a Cheque by the Drawer Bank

Testing the Example

Perform the following tasks to configure and test the example.

• Task A Deploying the Example in TIBCO Administrator, page 10

• Task B Running the Example, page 10

• Task C Testing For FTP Mode of Dispose, page 10

Task A Deploying the Example in TIBCO Administrator

1. Open TIBCO Administrator. Click the Installed Software link on the left panel. Check if TIBCO ActiveMatrix Adapter for SWIFT is registered. If the software is not registered, register by clicking the Add Custom Software tab. Refer to the TIBCO Administrator documentation for more details on adding custom software.

2. Expend the Application Management directory, then click the All Applications item. Click the New Application tab. Upload the EAR file created in the previous section, and click the OK button. Make sure the Quick Configure checkbox is checked. Click the Save button.

3. Click the Configuration link in the newly created application, then click the Deploy button in the Configuration tab. Click the OK button. The TRA files are created in TIB_ADSWIFT_HOME/bin/domain/DomainName.

4. Once the deployment is complete, click the Service Instances link under the application. The adapters are listed. Both the StopPaymentCheque and StatusStopPayment processes are started. The SWIFTNet - FINSenderConfiguration instance is also started.

Task B Running the Example

This section details the procedure, requesting for stop payment of a cheque using the FTP interface. Similarly, the example can be tested for the CASmf or MQSA interfaces.

Task C Testing For FTP Mode of Dispose

The SWIFTNet - FINSenderConfiguration and SWIFTNet - FINReceiverConfiguration instances are already running after deployment.

1. Open the Tester.tra file with the text editor from the location TIB_ADSWIFT_HOME\examples.

Page 25: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

Testing the Example | 11

2. Modify the Tester.tra file as follows:

a. Change the following property to 2013:

java.property.TIB_SWIFT_SPECIFICATION 2013

b. Modify the Tester.tra to point to StopPaymentCheque.dat and to publish MT111 from the locationTIB_ADSWIFT_HOME\examples\BusinessWorks\StopPaymentCheque.

See the red rectangle parts in Figure 1 for the detailed modification information.

Figure 1 Modifying the Tester TRA File

3. Start the Tester application from the command prompt.

On Windows:

TIB_ADSWIFT_HOME\examples\Tester.exe

On UNIX:

TIB_ADSWIFT_HOME/examples/Tester.exe

4. The message published by the Tester triggers the StopPaymentCheque process of TIBCO ActiveMatrix BusinessWorks. Figure 2 shows the StopPaymentCheque process.

Page 26: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

12 | Chapter 2 TIBCO ActiveMatrix BusinessWorks: Requesting Stop Payment of a Cheque by the Drawer Bank

Figure 2 StopPaymentCheque Process in TIBCO ActiveMatrix BusinessWorks

5. TIBCO ActiveMatrix BusinessWorks receives the message and publishes it on the TIBCO environment for SWIFTNet - FINSender on the subject name swift.sender.application.message.

6. The sender instance sends this message through FTP to the remote directory configured in the repository. Check the remote directory to find whether the message file has been transferred successfully.

7. Transfer the MT112 message using ftp from TIB_ADSWIFT_HOME\examples\BusinessWorks\StopPaymentCheque to the remote directory (configured for the Receiver instance) on the FTP server.

8. The receiver instance polls the remote directory on the FTP server and receives the messages.

9. After processing the message, the receiver instance publishes the message to the TIBCO environment on the subject name swift.receiver.application.message.

10. The message published by the receiver triggers the StatusStopPayment process of TIBCO ActiveMatrix BusinessWorks.

11. TIBCO ActiveMatrix BusinessWorks receives the message and publishes it on the TIBCO environment for other applications on the subject name swift.testReceiver.application.message.

Page 27: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

Expected Results | 13

Expected Results

The example results can be viewed in the respective text files where the message captured from tibrvlisten is stored.

The tibrvlisten command can be executed using the following command:

tibrvlisten "swift.testReceiver.application.message" -file

filepath\filename

Page 28: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

14 | Chapter 2 TIBCO ActiveMatrix BusinessWorks: Requesting Stop Payment of a Cheque by the Drawer Bank

Page 29: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

| 15

Chapter 3 TIBCO ActiveMatrix BusinessWorks: Buying Shares over the SWIFT Network

This example demonstrates buying shares over the SWIFT network.

Topics

• Example Description, page 16

• Setting up the Example, page 17

• Testing the Example, page 18

• Expected Results, page 19

This example demonstrates the use of the FTP interface. You can also use the CASmf or MQSA interfaces if required.

Page 30: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

16 | Chapter 3 TIBCO ActiveMatrix BusinessWorks: Buying Shares over the SWIFT Network

Example Description

This example shows how the adapter's Publication and Subscription services can be used in a TIBCO ActiveMatrix BusinessWorks process. The example has three processes, OrderBuyShares, TradeAllocationInstruction, and AdviceOfExecution.

OrderBuyShares and TradeAllocationInstruction Processes

The OrderBuyShares and TradeAllocationInstruction processes use the adapter’s Subscription service. The events in this process are:

1. The tester publishes the sample message on a specified subject, which triggers the OrderBuyShares or TradeAllocationInstruction process of TIBCO ActiveMatrix BusinessWorks.

2. TIBCO ActiveMatrix BusinessWorks receives the published message and publishes it on a specified subject on which the SWIFTNet-FINSender is listening.

3. SWIFTNet-FINSender receives the message published by TIBCO ActiveMatrix BusinessWorks and processes the message. It places the message in the remote/error directory of the FTP server, if it is in FTP mode. The message is sent to CASmf or TIBCO ActiveMatrix Adapter for MQSeries, if it is in CASmf mode or in MQSA mode.

The AdviceOfExecution Process

The AdviceOfExecution process uses the adapter’s Publication service. The events in this process are:

1. SWIFTNet-FINReceiver picks the messages from the remote directory of the FTP server if it is in FTP mode or receives the message from CASmf application if it is in CASmf mode. If in MQSA mode, SWIFTNet-FINReceiver receives the message from TIBCO ActiveMarix Adapter for MQSeries. SWIFTNet-FINReceiver then publishes the messages on the TIBCO environment on a predefined subject, which triggers the AdviceOfExecution process of TIBCO ActiveMatrix BusinessWorks.

2. TIBCO ActiveMatrix BusinessWorks receives the message and publishes it on the TIBCO environment on a specified subject for other applications.

Page 31: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

Setting up the Example | 17

Setting up the Example

Before starting the example, you need to complete the following steps to set up the example:

1. Create a directory to store the project: c:\tibco\projects

2. Start TIBCO Designer, then click the New Empty Project button. The Save Project dialog appears.

3. In the Save Project dialog, click the Browse button and navigate to the project directory you created and specify a name for the project. Then click the OK button.

4. Select Project > Import Full Project from the Menu, and then click the ZIP Archive tab. Click the Browse button, and navigate to TIB_ADSWIF_HOME/examples/BusinessWorks/BuyShares directory, and then select the ZIP file you want to import. In this examples, select BuyShares. Click the OK button. The Import-Options dialog appears.

5. In the Import-Options dialog, select the Replace Existing Global Variables With Those In Import and Overwrite On Name Conflict radio buttons. Then click the Apply button.

6. Select Project > Save from the Menu, then exit TIBCO Designer.

7. Export the multi-file project to a DAT file by selecting Project > Export Full Project from the Menu. Browse and select the location of the directory you want to save the DAT file to and save it as BuyShares.dat. Click the OK button.

Page 32: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

18 | Chapter 3 TIBCO ActiveMatrix BusinessWorks: Buying Shares over the SWIFT Network

Testing the Example

In TIBCO Designer:

1. Click the OrderBuyShares item in the Project panel.

2. Click the Tester panel, then click the Start Testing Viewed Process button. The Process Selection dialog appears.

3. In the Process Selection dialog, the OrderBuyShares(current) checkbox is checked by default. Click the Load Selected button. The process is now in the Test mode.

In the text editor:

4. Open the Tester.tra file with the text editor from the location TIB_ADSWIFT_HOME\examples.

5. Modify the Tester.tra file as follows:

a. Change the following property to 2013:

java.property.TIB_SWIFT_SPECIFICATION 2013

b. Modify the Tester.tra to point to BuyShares.dat and to publish MT502 from the locationTIB_ADSWIFT_HOME\examples\BusinessWorks\BuyShares.

You can see the red rectangle parts in Figure 1 for the relevant modification information.

6. Start the Tester instance from the location TIB_ADSWIFT_HOME\examples in the command prompt to publish MT502 which triggers the OrderBuyShares process.

7. When the process executes, you will find the black arrows that point to each activity have turned to green.

8. Click the Stop Testing icon to return to the Design mode.

The above steps describe the testing for the OrderBuyShares process. Follow the same steps to run the TradeAllocationInstruction and AdviceOfExecution processes.

For the TradeAllocationInstruction process, the tester.tra must be pointed to TradeTester.dat present at the location TIB_ADSWIFT_HOME\examples, and modified to publish the message MT514 from the same location.

For the AdviceOfExecution process, refer to StatusStopPayment Process on page 8 for details.

Page 33: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

Expected Results | 19

Expected Results

The example results can be viewed in the respective text, which has been FTP’d to the FTP directory.

A portion of the MT514 message obtained from the Trade Allocation Instruction process of TIBCO ActiveMatrix BusinessWorks is given next:

{1:F01TIBCNL20AXXX0218012705}{2:O5142200030929LRLRXXXX4A0300003995460309300011U}{3:{108:MT514 005 OF 007}}{4::16R:GENL:20C::SEME//01239:23G:CANC/COPY:98A::PREP//19991231:22F::TRTR//FUND:99B::ALLO//123:99B::TOAL//123:16R:LINK:13A::LINK//518:20C::BASK//x:16S:LINK:16R:LINK:13A::LINK//518:20C::INDX//x:16S:LINK:16R:LINK:13A::LINK//518:20C::LIST//x:16S:LINK:16R:LINK:13A::LINK//518:20C::MAST//x:16S:LINK:16R:LINK:13A::LINK//518:20C::PREV//x:16S:LINK:16R:LINK:13A::LINK//518:20C::PROG//x:16S:LINK:16R:LINK:13A::LINK//518:20C::RELA//x:16S:LINK:16S:GENL:16R:CONFDET:98A::TRAD//19991231:98A::SETT//19990101:90A::DEAL//PRCT/1,34:99A::DAAC//N123:94B::TRAD//VARI/30x:19A::SEBL//NUSD1,34:22H::BUSE//CROF

Page 34: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

20 | Chapter 3 TIBCO ActiveMatrix BusinessWorks: Buying Shares over the SWIFT Network

:22F::PRIC//AVOV:22F::PROC//OPEP:22F::RPOR//EXCH:22F::PRIR//0001:22F::SETG//GENS:22F::TTCO//BCRO:22F::TTCO//BCRO:22F::COST//FLAT:22H::PAYM//FREE:22F::CATB//FLAT:22F::TRCN//SOLI:11A::FXIB//USD:16R:CONFPRTY:95P::INVE//TESTUSVT:95S::ALTE//CORP/US/x:97A::SAFE//x:97A::CASH//x:98A::PROC//19991231:20C::PROC//16x:70E::DECL//35X(9 X 35x):70C::PACO//35x(3 X 35x):70D::PART//35x(5 X 35x):22F::TRCA//PRAG:16S:CONFPRTY:36B::ALLO//AMOR/1,34:36B::TQBT//AMOR/1,34:35B:ISIN 123456ABCDEF(4 X 35x):16R:FIA:22F::MICO/A2C4E6G8/A2C4:22F::FORM/A2C4E6G8/A2C4:22F::PFRE/A2C4E6G8/A2C4:22F::PREF/A2C4E6G8/A2C4:22F::PAYS/A2C4E6G8/A2C4:22F::PADI/A2C4E6G8/A2C4:12A::CLAS/A2C4E6G8/A2C4:12B::OPST/A2C4E6G8/A2C4:12B::OPTI/A2C4E6G8/A2C4:11A::DENO//USD:98A::COUP//19991231:98A::EXPI//19991231:98A::FRNR//19991231:98A::MATU//19991231:98A::ISSU//19991231:98A::CALD//19991231:98A::CONV//19991231:98A::PUTT//19991231:98A::DDTE//19991231:92A::PRFC//N1,3456789012345:92A::CUFC//N1,3456789012345:92A::NWFC//N1,3456789012345:92A::INTR//N1,3456789012345:92A::NXRT//N1,3456789012345:13A::COUP//A2C

Page 35: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

Expected Results | 21

:13A::POOL//A2C:13A::LOTS//A2C:13A::VERN//A2C:17B::CONV//Y:17B::FRNF//Y:17B::COVE//Y:17B::CALL//Y:17B::PUTT//Y:90A::INDC//PRCT/1,3456789012345:90A::EXER//PRCT/1,3456789012345:36B::MINO//AMOR/1,3456789012345:36B::MIEX//AMOR/1,3456789012345:36B::MILT//AMOR/1,3456789012345:70E::FIAN//x:16S:FIA:13B::CERT//30x:13B::CERT//30x:70E::TPRO//35X(9 X 35x):16S:CONFDET:16R:SETDET:22F::SETR//PAIR:22F::STCO/A2C4E6G8/A2C4:22F::STCO//PART:22F::REST/A2C4E6G8/A2C4:22F::STCO//PHYS:22F::STCO/A2C4E6G8/PHYS:11A::FXIB//USD:16R:SETPRTY:95P::REAG//TESTUSVT:95S::ALTE//ARNU/US/30x:97A::SAFE//35x:98A::PROC//19991231:20C::PROC//x:70D::REGI//35x(5 X 35x):70C::PACO//35x(3 X 35x):70D::PART//35x(5 X 35x):16S:SETPRTY:16R:SETPRTY:95P::BUYR//TESTUSVT:97B::SAFE//FUNG/35x:98C::PROC//19991231232359:16S:SETPRTY:16R:SETPRTY:95P::RECU//TESTUSVT:97A::SAFE//35x:98A::PROC//19991231:16S:SETPRTY:16R:SETPRTY:95P::REI1//TESTUSVT:16S:SETPRTY:16R:SETPRTY:95P::REI2//TESTUSVT:16S:SETPRTY

Page 36: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

22 | Chapter 3 TIBCO ActiveMatrix BusinessWorks: Buying Shares over the SWIFT Network

:16R:SETPRTY:95P::REI3//TESTUSVT:16S:SETPRTY:16R:SETPRTY:95P::REI4//TESTUSVT:16S:SETPRTY:16R:SETPRTY:95P::REI5//TESTUSVT:16S:SETPRTY:16R:SETPRTY:95P::REI6//TESTUSVT:16S:SETPRTY:16R:SETPRTY:95P::REI7//TESTUSVT:16S:SETPRTY:16R:SETPRTY:95P::REI8//TESTUSVT:16S:SETPRTY:16R:SETPRTY:95P::REI9//TESTUSVT:16S:SETPRTY:16R:SETPRTY:95P::DEAG//TESTUSVT:16S:SETPRTY:16R:SETPRTY:95P::SELL//TESTUSVT:16S:SETPRTY:16R:SETPRTY:95P::DECU//TESTUSVT:16S:SETPRTY:16R:SETPRTY:95P::DEI1//TESTUSVT:16S:SETPRTY:16R:SETPRTY:95P::DEI2//TESTUSVT:16S:SETPRTY:16R:SETPRTY:95P::DEI3//TESTUSVT:16S:SETPRTY:16R:SETPRTY:95P::DEI4//TESTUSVT:16S:SETPRTY:16R:SETPRTY:95P::DEI5//TESTUSVT:16S:SETPRTY:16R:SETPRTY:95P::DEI6//TESTUSVT:16S:SETPRTY:16R:SETPRTY:95P::DEI7//TESTUSVT:16S:SETPRTY:16R:SETPRTY:95P::DEI8//TESTUSVT:16S:SETPRTY:16R:SETPRTY:95P::DEI9//TESTUSVT:16S:SETPRTY

Page 37: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

Expected Results | 23

:16R:SETPRTY:95C::PSET//US:16S:SETPRTY:16R:CSHPRTY:95P::ACCW//TESTUSVT:95S::ALTE//ARNU/US/30x:97A::CASH//35x:97A::CHAR//35x:97A::COMM//35x:97A::TAXE//35x:70C::PACO//35x:70D::PART//35x:16S:CSHPRTY:16R:CSHPRTY:95P::BENM//TESTUSVT:97A::CASH//35x:97A::CHAR//35x:97A::COMM//35x:97A::TAXE//35x:16S:CSHPRTY:16R:CSHPRTY:95P::PAYE//TESTUSVT:97A::CASH//35x:97A::CHAR//35x:97A::COMM//35x:97A::TAXE//35x:16S:CSHPRTY:16R:AMT:19A::ACRU//USD1,34:19A::RESU//NUSD1,34:19A::OCMT//NUSD1,34:98A::VALU//19991231:92B::EXCH//USD/EUR/1,34:16S:AMT:16R:AMT:19A::CHAR//USD1,34:19A::OCMT//NUSD1,34:98C::VALU//19991231232359:16S:AMT:16R:AMT:19A::COUN//USD1,34:16S:AMT:16R:AMT:19A::DEAL//USD1,34:16S:AMT:16R:AMT:19A::EXEC//USD1,34:16S:AMT:16R:AMT:19A::ISDI//USD1,34:16S:AMT:16R:AMT:19A::LEVY//USD1,34:16S:AMT:16R:AMT:19A::LOCL//USD1,34:16S:AMT

Page 38: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

24 | Chapter 3 TIBCO ActiveMatrix BusinessWorks: Buying Shares over the SWIFT Network

:16R:AMT:19A::LOCO//USD1,34:16S:AMT:16R:AMT:19A::MACO//USD1,34:16S:AMT:16R:AMT:19A::MARG//USD1,34:16S:AMT:16R:AMT:19A::OTHR//USD1,34:16S:AMT:16R:AMT:19A::POST//USD1,34:16S:AMT:16R:AMT:19A::REGF//USD1,34:16S:AMT:16R:AMT:19A::SETT//USD1,34:16S:AMT:16R:AMT:19A::SHIP//USD1,34:16S:AMT:16R:AMT:19A::SPCN//USD1,34:16S:AMT:16R:AMT:19A::STAM//USD1,34:16S:AMT:16R:AMT:19A::STEX//USD1,34:16S:AMT:16R:AMT:19A::TRAN//USD1,34:16S:AMT:16R:AMT:19A::TRAX//USD1,34:16S:AMT:16R:AMT:19A::VATA//USD1,34:16S:AMT:16R:AMT:19A::WITH//USD1,34:16S:AMT:16S:SETDET:16R:OTHRPRTY:95P::EXCH//TESTUSVT:95S::ALTE//ARNU/US/30x:97A::SAFE//35x:97A::CASH//35x:70C::PACO//35x(3 X 35x):70D::PART//35x(5 X 35x):20C::PROC//x:16S:OTHRPRTY

Page 39: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

Expected Results | 25

:16R:OTHRPRTY:95P::MEOR//TESTUSVT:97B::SAFE//FUNG/35x:97A::CASH//35x:16S:OTHRPRTY:16R:OTHRPRTY:95P::MERE//TESTUSVT:97A::SAFE//35x:97A::CASH//35x:16S:OTHRPRTY:16R:OTHRPRTY:95P::TRRE//TESTUSVT:16S:OTHRPRTY:16R:REPO:98A::TERM//20030531:22F::RERT//VARI:22F::MICO//A006:20C::SECO//16x:92C::VASU//24x:92A::REPO//N1,34:92A::RSPR//N1,34:99B::CADE//123:19A::FORF//NUSD1,34:19A::REPA//NUSD1,34:19A::REPP//NUSD1,34:19A::ACRU//NUSD1,34:19A::DEAL//NUSD1,34:70C::REPO//4 X 35x:16S:REPO-}{5:{MAC:510D4DC2}{CHK:75C38F0A2835}{TNG:}}

Page 40: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

26 | Chapter 3 TIBCO ActiveMatrix BusinessWorks: Buying Shares over the SWIFT Network

Page 41: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

| 27

Chapter 4 TIBCO ActiveMatrix BusinessWorks: Sending a Message Directly to a Financial Institution

This example demonstrates how an ordering institution sends a message directly to the financial institution of the beneficiary.

Topics

• Example Description, page 28

• Setting Up the Example, page 29

• Testing the Example, page 30

• Expected Results, page 31

This example demonstrates the use of the CASmf interface. You can also use the FTP or MQSA interfaces if required.

Page 42: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

28 | Chapter 4 TIBCO ActiveMatrix BusinessWorks: Sending a Message Directly to a Financial Institution

Example Description

This example shows how the adapter's Publication and Subscription services can be used in a TIBCO ActiveMatrix BusinessWorks process. The example has two processes, OrderingInstitution and FinancialInstitution.

The OrderingInstitution process

The OrderingInstitution process uses the adapter’s Subscription service. The events in this process are:

1. The tester publishes the sample message on a specified subject, which triggers the OrderingInstitution process of TIBCO ActiveMatrix BusinessWorks.

2. TIBCO ActiveMatrix BusinessWorks receives the published message and publishes it on a specified subject on which the SWIFTNet-FINSender is listening.

3. SWIFTNet - FINSender receives the message published by TIBCO ActiveMatrix BusinessWorks and processes the message. It places the message in the remote/error directory of the FTP server, if it is in FTP mode. The message is sent to CASmf or TIBCO ActiveMatrix Adapter for MQSeries, if it is in CASmf mode or in MQSA mode.

The FinancialInstitution process uses the adapter’s Publication service. The events in this process are:

1. SWIFTNet - FINReceiver picks the messages from the remote directory of the FTP server if it is in FTP mode or receives the message from CASmf application if it is in CASmf mode. If in MQSA mode, SWIFTNet-FINReceiver receives the message from TIBCO ActiveMatrix Adapter for MQSeries. SWIFTNet-FINReceiver then publishes the messages on the TIBCO environment on a predefined subject, which triggers the FinancialInstitution process of TIBCO ActiveMatrix BusinessWorks.

2. TIBCO ActiveMatrix BusinessWorks receives the message and publishes it on the TIBCO environment on a specified subject for other applications.

Page 43: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

Setting Up the Example | 29

Setting Up the Example

Before starting the example, you need to complete the following steps to set up the example:

1. Create a directory to store the project: c:\tibco\projects

2. Start TIBCO Designer, then click the New Empty Project button. The Save Project dialog appears.

3. In the Save Project dialog, click the Browse button and navigate to the project directory you created and specify a name for the project. Then click the OK button.

4. Select Project > Import Full Project from the Menu, and then click the ZIP Archive tab. Click the Browse button, and navigate to TIB_ADSWIF_HOME/examples/BusinessWorks/OrderFinInstitution directory, and then select the ZIP file you want to import. In this examples, select OrderFinInstitution. Click the OK button. The Import-Options dialog appears.

5. In the Import-Options dialog, select the Replace Existing Global Variables With Those In Import and Overwrite On Name Conflict radio buttons, and then click the Apply button.

6. Select Project > Save from the Menu, then exit TIBCO Designer.

7. Export the multi-file project to a DAT file by selecting Project > Export Full Project from the Menu. Browse and select the location of the directory you want to save the DAT file to and save it as OrderFinInstitution.dat. Click the OK button.

Page 44: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

30 | Chapter 4 TIBCO ActiveMatrix BusinessWorks: Sending a Message Directly to a Financial Institution

Testing the Example

In TIBCO Designer:

1. Click the OrderingInstitution item in the Project panel.

2. Click the Tester panel, then click the Start Testing Viewed Process button. The Process Selection dialog appears.

3. In the Process Selection dialog that appears, the OrderingInstitution(current) checkbox is checked by default. Click the Load Selected button. The process is now in the Test mode.

In the text editor:

4. Open the Tester.tra file with the text editor from the location TIB_ADSWIFT_HOME\examples.

5. Modify the Tester.tra file as follows:

a. Change the following property to 2013:

java.property.TIB_SWIFT_SPECIFICATION 2013

b. Modify the Tester.tra to point to OrderFinInstitution.dat and to publish MT202 from the locationTIB_ADSWIFT_HOME\examples\BusinessWorks\OrderFinInstitution.

You can see the red rectangle parts in Figure 1 for the relevant modification information.

6. Start the Tester instance from the location TIB_ADSWIFT_HOME\examples in the command prompt to publish MT202 which triggers the OrderingInstitution process.

7. When the process executes, you will find the black arrows that point to each activity have turned to green.

8. Click the Stop Testing icon to return to the Design mode.

The above steps describe the testing for the OrderingInstitution process. Follow the same steps to run the FinancialInstitution process.

Page 45: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

Expected Results | 31

Expected Results

The example results can be viewed in the respective text files, where the message captured from tibrvlisten is stored.

The MT202 message obtained from the OrderingInstitution process of TIBCO ActiveMatrix BusinessWorks is given next:

<?xml version="1.0" encoding="UTF-8"?>

<ns:Message__202__GeneralFinancialInstitutionTransfer xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:ae="http://www.tibco.com/xmlns/ae2xsd/2003/05" xmlns:ns="http://www.tibco.com/xmlns/ae2xsd/2003/05/ae/SWIFTAdapter/SWIFTLibrary" xsi:type="ns:Message__202__GeneralFinancialInstitutionTransfer"> <Reference> <item>0_0</item> </Reference> <Session>0</Session> <Sequence>0</Sequence> <MessageType>202</MessageType> <BasicHeader> <ApplicationIdentifier>F</ApplicationIdentifier> <ServiceIdentifier>01</ServiceIdentifier> <LTAddress>TIBCNL20AXXX</LTAddress> <SessionNumber>0214</SessionNumber> <SequenceNumber>010160</SequenceNumber> </BasicHeader> <ApplicationHeader> <ApplicationOutputHeader> <InputOutputIdentifier>O</InputOutputIdentifier> <MessageType>202</MessageType> <InputTime>2125</InputTime> <MessageInputReference>030910LRLRXXXX4A030000389947</MessageInputReference> <OutputDate>030910</OutputDate> <OutputTime>2325</OutputTime> <MessagePriority>N</MessagePriority> </ApplicationOutputHeader> </ApplicationHeader> <UserHeader> <_108__MessageUserReference>MT202 010 OF 037</_108__MessageUserReference> </UserHeader> <Text> <M__20__TransactionReferenceNumber> <Reference>00298</Reference> </M__20__TransactionReferenceNumber> <M__21__RelatedReference> <Reference>123456/DEV</Reference> </M__21__RelatedReference> <O__13C__TimeIndication>

Page 46: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

32 | Chapter 4 TIBCO ActiveMatrix BusinessWorks: Sending a Message Directly to a Financial Institution

<item> <Code>A234567Z</Code> <TimeIndication>1359</TimeIndication> <Sign>+</Sign> <TimeOffset>0100</TimeOffset> </item> </O__13C__TimeIndication> <M__32A__ValueDateCurrencyCodeAmount> <Date>000103</Date> <Currency>MAD</Currency> <Amount>345000,</Amount> </M__32A__ValueDateCurrencyCodeAmount> <M__58AD__BeneficiaryInstitution> <_58A> <BICBEI>TESTNOVT</BICBEI> </_58A> </M__58AD__BeneficiaryInstitution> </Text> <Trailer> <MAC__MessageAuthenticationCode>5CEE676F</MAC__MessageAuthenticationCode> <CHK__Checksum>5823952588E3</CHK__Checksum> <TNG__Training/> </Trailer></ns:Message__202__GeneralFinancialInstitutionTransfer>

Page 47: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

| 33

Chapter 5 TIBCO ActiveMatrix BusinessWorks: Exchange of Query and Answer Statements

This example demonstrates how the Query and Answer Statements are exchanged for a particular bank statement received from the SWIFT network.

Topics

• Example Description, page 34

• Setting Up the Example, page 35

• Testing the Example, page 36

• Expected Results, page 37

This example demonstrates the use of the FTP interface. You can also use the CASmf or MQSA interfaces if required.

Page 48: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

34 | Chapter 5 TIBCO ActiveMatrix BusinessWorks: Exchange of Query and Answer Statements

Example Description

This example shows how the adapter's Publication and Subscription services can be used in a TIBCO ActiveMatrix BusinessWorks process. The example has three processes, Query, Statement, and Answer.

The Query Process

The Query process uses the adapter’s Subscription service. The events in this process are:

1. The tester publishes the sample message on a specified subject, which triggers the Query process of TIBCO ActiveMatrix BusinessWorks.

2. TIBCO ActiveMatrix BusinessWorks receives the published message and publishes it on a specified subject on which the SWIFTNet-FINSender is listening.

3. SWIFTNet-FINSender receives the message published by TIBCO ActiveMatrix BusinessWorks and processes the message. It places the message in the remote/error directory of the FTP server, if it is in FTP mode. The message is sent to CASmf or TIBCO ActiveMatrix Adapter for MQSeries, if it is in CASmf mode or in MQSA mode.

The Statement and Answer processes use the adapter’s Publication service. The events in this process are:

1. SWIFTNet-FINReceiver picks the messages from the remote directory of the FTP server if it is in FTP mode or receives the message from CASmf application if it is in CASmf mode. If in MQSA mode, SWIFTNet-FINReceiver receives the message from TIBCO ActiveMatrix Adapter for MQSeries. SWIFTNet-FINReceiver then publishes the messages on the TIBCO environment on a predefined subject, which triggers the Statement and Answer processes of TIBCO ActiveMatrixBusinessWorks.

2. TIBCO ActiveMatrix BusinessWorks receives the message and publishes it on the TIBCO environment on a specified subject for other applications.

Page 49: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

Setting Up the Example | 35

Setting Up the Example

Before starting the example, you need to complete the following steps to set up the example:

1. To store the project, create a directory located in the c:\tibco\projects directory.

2. Start TIBCO Designer, then click the New Empty Project button. The Save Project dialog appears.

3. In the Save Project dialog, click the Browse button and navigate to the project directory you created and specify a name for the project. Then click the OK button.

4. Select Project > Import Full Project from the Menu, and then click the ZIP Archive tab. Click the Browse button, and navigate to TIB_ADSWIF_HOME/examples/BusinessWorks/ExchangeQueryAnswer directory, and then select the ZIP file you want to import. In this examples, select ExchangeQueryAnswer. Click the OK button. The Import-Options dialog appears.

5. In the Import-Options dialog, select the Replace Existing Global Variables With Those In Import and Overwrite On Name Conflict radio buttons. Then click the Apply button.

6. Select Project > Save from the Menu, then exit TIBCO Designer.

7. Export the multi-file project to a DAT file by selecting Project > Export Full Project from the Menu. Browse and select the location of the directory you want to save the DAT file to and save it as ExchangeQueryAnswer.dat. Click the OK button.

Page 50: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

36 | Chapter 5 TIBCO ActiveMatrix BusinessWorks: Exchange of Query and Answer Statements

Testing the Example

In TIBCO Designer:

1. Click the Query item in the Project panel.

2. Click the Tester panel, then click the Start Testing Viewed Process button. The Process Selection dialog appears.

3. In the Process Selection dialog, the Query(current) checkbox is checked by default. Click the Load Selected button. The process is now in the Test mode.

In the text editor:

4. Open the Tester.tra file with the text editor from the location TIB_ADSWIFT_HOME\examples.

5. Modify the Tester.tra file as follows:

a. Change the following property to 2013:

java.property.TIB_SWIFT_SPECIFICATION 2013

b. Modify the Tester.tra to point to ExchangeQueryAnswer.dat and to publish MT995 from the locationTIB_ADSWIFT_HOME\examples\BusinessWorks\ExchangeQueryAnswer.

You can see the red rectangle parts in Figure 1 for the relevant modification information.

6. Start the Tester instance from the location TIB_ADSWIFT_HOME\examples in the command prompt to publish MT995 which triggers the Query process.

7. When the process executes, you will find the black arrows that point to each activity have turned to green.

8. Click the Stop Testing icon to return to the Design mode.

The above steps describe the testing for the Query process. Follow the same steps to run the Statement and Answer processes. To trigger the Statement and the Answer processes, place MT950 and MT996 messages in the remote directory and start the SWIFT receiver instance from the command prompt.

Page 51: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

Expected Results | 37

Expected Results

The example results can be viewed in the respective text files where the message captured from tibrvlisten is stored.

The MT996 message obtained from the Answer process of TIBCO ActiveMatrix BusinessWorks is given next.

<?xml version="1.0" encoding="UTF-8"?>

<ns:Message__996__Answers xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:ae="http://www.tibco.com/xmlns/ae2xsd/2003/05" xmlns:ns="http://www.tibco.com/xmlns/ae2xsd/2003/05/ae/SWIFTAdapter/SWIFTLibrary" xsi:type="ns:Message__996__Answers"> <Reference> <item>0_0</item> </Reference> <Session>0</Session> <Sequence>0</Sequence> <MessageType>996</MessageType> <BasicHeader> <ApplicationIdentifier>F</ApplicationIdentifier> <ServiceIdentifier>01</ServiceIdentifier> <LTAddress>TIBCNL20AXXX</LTAddress> <SessionNumber>0192</SessionNumber> <SequenceNumber>006587</SequenceNumber> </BasicHeader> <ApplicationHeader> <ApplicationOutputHeader> <InputOutputIdentifier>O</InputOutputIdentifier> <MessageType>996</MessageType> <InputTime>2320</InputTime> <MessageInputReference>021003LRLRXXXX4A020000319087</MessageInputReference> <OutputDate>021004</OutputDate> <OutputTime>0122</OutputTime> <MessagePriority>N</MessagePriority> </ApplicationOutputHeader> </ApplicationHeader> <UserHeader> <_108__MessageUserReference>MT996 001 OF 016</_108__MessageUserReference> </UserHeader> <Text> <M__20__TransactionReferenceNumber> <Reference>00976</Reference> </M__20__TransactionReferenceNumber> <M__21__RelatedReference> <Reference>123456/DEV</Reference> </M__21__RelatedReference> <M__76__Answers> <Narrative>VALUE DATE SHOULD BE 930107</Narrative>

Page 52: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

38 | Chapter 5 TIBCO ActiveMatrix BusinessWorks: Exchange of Query and Answer Statements

</M__76__Answers> </Text> <Trailer> <CHK__Checksum>F5FF84349D93</CHK__Checksum> <TNG__Training/> </Trailer></ns:Message__996__Answers>

Page 53: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

| 39

Chapter 6 TIBCO ActiveMatrix BusinessWorks SWIFT Plug-in: Router and Parser Activities

This example demonstrates the basic usage of the SWIFT Router and Parser activities for TIBCO ActiveMatrix BusinessWorks.

Topics

• Example Description, page 40

• Setting Up the Example, page 42

• Testing the Example, page 43

• Expected Results, page 45

Page 54: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

40 | Chapter 6 TIBCO ActiveMatrix BusinessWorks SWIFT Plug-in: Router and Parser Activities

Example Description

This example takes a file that contains a multi-message FIN string as the input, splits it into individual messages, and then routes them to the appropriate parsers. MT102 and MT103 messages are parsed while other messages are simply logged.

As shown in Figure 3, the process flow of this example is as the following:

Figure 3 TIBCO ActiveMatrix BusinessWorks SWIFT Plug-in: Router and Parser Activities

1. The Timer activity triggers the process when it is run.

2. The Read_Incoming_MTs activity reads the $root\IN\10x-messages.fin file and passes the multi-message FIN string in the file to the SWIFT Router activity.

3. The SWIFT Router activity splits the multi-message FIN string into individual messages and passes each message to the Dump FIN Msg To Disk activity in the MT Processing group.

4. For each message in the file, the following activities take place in the MT Processing group:

a. The message is written from the Dump FIN Msg To Disk activity to the $root\OUT\ directory as received-mt#-timestamp.fin.

b. The message is then sent to the Parser activities depending upon the message type. An MT 102 message is sent to the Parse-MT 102 activity, an

Page 55: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

Example Description | 41

MT 103 message is sent to the Process MT103 activity, and any other message is sent to the Log And Move On activity.

c. The Parse-MT 102 and Parse MT103 activities parse the incoming MT 102 and MT 103 FIN messages to a structured format.

d. The Process-MT102 and Process MT103 activities writes the structured message to the $root\OUT\ directory as processed-mt#-timestamp.txt. This structured message can then easily be manipulated, merged, mapped, and etc. using any other TIBCO ActiveMatrixBusinessWorks activity.

e. The Log And Move On activity logs any message that is not of the MT102 or MT103 type.

Page 56: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

42 | Chapter 6 TIBCO ActiveMatrix BusinessWorks SWIFT Plug-in: Router and Parser Activities

Setting Up the Example

Before starting the example, you need to complete the following steps to set up the example:

1. Create a directory to store the project: c:\tibco\projects.

2. Start TIBCO Designer, then click the New Empty Project button. The Save Project dialog appears.

3. In the Save Project dialog, click the Browse button and navigate to the project directory you created and specify a name for the project. Then click the OK button.

4. Select Project > Import Full Project from the Menu, and then click the ZIP Archive tab. Click the Browse button, and navigate to TIB_ADSWIF_HOME/examples/BWPlugin directory, and then select the ZIP file you want to import. In this examples, select BW-activity-MT102-MT103-routing-and-parsing. Click the OK button. The Import-Options dialog appears.

5. In the Import-Options dialog, select the Replace Existing Global Variables With Those In Import and Overwrite On Name Conflict radio buttons, and then click the Apply button.

6. Select Project > Save from the Menu.

In addition to the regular project files, the root directory (C:\tibco\projects\example1) will now contain the following directories:

— IN: This directory contains a multi-message FIN string in a file called 10x-messages.fin.

— OUT: This directory will contain the output of the example after it is run.

7. Click the Global Variables panel. Select SWIFTExamples > root, then click the Open Advanced Editor button at top of the left corner in this panel. Change the project directory path specified earlier. For example, C:\tibco\projects\example1. Click the OK button.

8. Select SWIFTNet - FIN Schema Loader item, in the Configuration tab, make sure the Message 102 and 103 have been selected. If not, you need to check the checkboxes of Message 102 and 103 from the Message Types list.

9. Select Project > Save from the Menu.

Page 57: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

Testing the Example | 43

Testing the Example

In TIBCO Designer:

1. Click the Project panel, and select the Route and Parse process.

2. Click the Tester panel, then click the Start Testing Viewed Process button . In the process selection dialog that appears, the Route and Parse(current) checkbox is checked by default. Click the Load Selected button. The process is now in the Test mode.

3. When the process executes, you will find the black arrows that point to each activity have turned to green.

The messages from the $root\IN\10x-messages.fin file are split into individual messages and routed to the appropriate parsers. MT102 and MT103 messages are parsed while other messages are simply logged.

4. Click the Stop Testing icon to return to the Design mode.

To see how the information from the FIN messages has been extracted and assigned to variables:

a. In the Tester panel, select any job. Then select a parser activity for that job (for example: Parse-MT103).

b. Click the Input Data tab.

Page 58: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

44 | Chapter 6 TIBCO ActiveMatrix BusinessWorks SWIFT Plug-in: Router and Parser Activities

Figure 4 Extracted Information from the FIN Messages

5. Explore the contents of the $root\OUT directory to ensure that it contains the expected results.

6. Create a EAR file by selecting Tools > Create Project EAR from the Menu if you want to deploy the example in the Administrator mode.

Page 59: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

Expected Results | 45

Expected Results

The $root\OUT directory must contain the following files. Notice that all the messages that were received are saved to a disk as received-mt#-timestamp.fin. For the messages that are parsed (MT102 and MT103), an additional file, processed-mt#-timestamp.txt, is saved to the disk. This TXT file contains some example fields extracted from the parsed message.

processed-mt102-20053128183101954.txtprocessed-mt102-20053128183105704.txtprocessed-mt103-20053128183103829.txtprocessed-mt103-20053128183106720.txtreceived-mt102-20053128183101548.finreceived-mt102-20053128183105298.finreceived-mt102STP-20053128183102579.finreceived-mt103-20053128183103407.finreceived-mt103-20053128183106313.finreceived-mt104-20053128183104470.fin

Page 60: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

46 | Chapter 6 TIBCO ActiveMatrix BusinessWorks SWIFT Plug-in: Router and Parser Activities

Page 61: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

| 47

Chapter 7 TIBCO ActiveMatrix BusinessWorks SWIFT Plug-in: Renderer Activity

This example demonstrates the basic usage of the SWIFT Renderer activity for TIBCO ActiveMatrix BusinessWorks.

Topics

• Example Description, page 40

• Setting Up the Example, page 42

• Testing the Example, page 43

• Expected Results, page 45

Page 62: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

48 | Chapter 7 TIBCO ActiveMatrix BusinessWorks SWIFT Plug-in: Renderer Activity

Example Description

This example takes account summary files as the input, parses the data from the files, passes the data to the Renderer, and produces MT535 "statements of holdings" FIN messages.

As shown in Figure 5, the process flow of this example is as the following:

Figure 5 TIBCO ActiveMatrix BusinessWorks SWIFT Plug-in: Renderer Activity

1. The Poll For Account Summaries activity looks for account summary files in the $root\holdings directory.

An account summary file is a text file and each line in the file contains four values: Account Number, ISIN, Quantity, and Quantity Type. For example, an account summary file contains:

0014010|US88632Q1031|10004,0|UNIT0014010|US3838831051|02000,0|UNIT0014010|NL0000009470|82000,0|UNIT0014010|ES0130670112|00100,0|UNIT0014010|FR0000120073|04587,0|UNIT0014010|US7170811035|00153,0|UNIT0032020|BE0003796134|00511,0|UNIT0032030|BE0003796134|45000,0|UNIT0045600|UX383XX31052|04344,0|UNIT

2. The Parse Data activity parses the data from the account summary files into a structured format and passes it to the Render SWIFT MT535 activity.

3. The Render SWIFT MT535 activity produces an MT535 "statement of holdings" FIN message.

4. The Write MT535 activity writes the FIN message to the $root directory as mt535-acct-account number.txt.

Page 63: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

Setting Up the Example | 49

Setting Up the Example

Before starting the example, you need to complete the following steps to set up the example:

1. Create a directory to store the project: c:\tibco\projects.

2. Start TIBCO Designer, then click the New Empty Project button. The Save Project dialog appears.

3. In the Save Project dialog, click the Browse button and navigate to the project directory you created and specify a name for the project. Then click the OK button.

4. Select Project > Import Full Project from the Menu, and then click the ZIP Archive tab. Click the Browse button, and navigate to the TIB_ADSWIF_HOME/examples/BWPlugin directory, and then select the ZIP file you want to import. In this examples, select BW-activity-MT535-rendering. Click the OK button. The Import-Options dialog appears.

5. In the Import-Options dialog, select the Replace Existing Global Variables With Those In Import and Overwrite On Name Conflict radio buttons, and then click the Apply button. The account summary files are located in the $root\holdings directory.

6. Click the Global Variables panel. Select SWIFTExamples > root, then click the Open Advanced Editor button at top of the left corner in this panel. Change the project directory path specified earlier. For example, C:\tibco\projects\example2. Click the OK button.

7. Select Project > Save from the Menu.

Page 64: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

50 | Chapter 7 TIBCO ActiveMatrix BusinessWorks SWIFT Plug-in: Renderer Activity

Testing the Example

In TIBCO Designer:

1. Click the Project panel, and select the Statement Generation process.

2. Click the Tester panel, then click the Start Testing Viewed Process button . In the process selection dialog that appears, the Statement Generation(current) checkbox is checked by default. Click the Load Selected button. The process is now in the Test mode.

3. When the process executes, you will find the black arrows that point to each activity have turned to green.

4. Click the Stop Testing icon to return to the Design mode.

5. Explore the contents of the $root directory to ensure that it contains the expected results.

Page 65: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

Expected Results | 51

Expected Results

The $root directory of the project must contain two new text files - mt535-acct-0032030.txt and mt535-acct-0053440.txt.

The mt535-acct-0032030.txt file contains:

{1:F01TIBCNL20AXXX0999012345}{2:O5351638030929LRLRXXXX4A0300003997420503011638N}{3:{108:MT535}}{4:

:16R:GENL:28E:00001/ONLY:20C::SEME//01295:23G:NEWM:98A::STAT//20050301:22F::STTY//CUST:97A::SAFE//0014011:17B::ACTI//Y:17B::CONS//N:16S:GENL:16R:SUBSAFE:16R:FIN:35B:ISIN US88632Q1031:93B::AGGR//UNIT/10004,0:16S:FIN:16R:FIN:35B:ISIN US3838831051:93B::AGGR//UNIT/02000,0:16S:FIN:16R:FIN:35B:ISIN NL0000009470:93B::AGGR//UNIT/82000,0:16S:FIN:16R:FIN:35B:ISIN ES0130670112:93B::AGGR//UNIT/00100,0:16S:FIN:16R:FIN:35B:ISIN FR0000120073:93B::AGGR//UNIT/04587,0:16S:FIN:16R:FIN:35B:ISIN US7170811035:93B::AGGR//UNIT/00153,0:16S:FIN:16R:FIN:35B:ISIN BE0003796134:93B::AGGR//UNIT/00511,0:16S:FIN:16R:FIN:35B:ISIN BE0003796134:93B::AGGR//UNIT/45000,0:16S:FIN:16R:FIN:35B:ISIN UX383XX31052

Page 66: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

52 | Chapter 7 TIBCO ActiveMatrix BusinessWorks SWIFT Plug-in: Renderer Activity

:93B::AGGR//UNIT/04344,0:16S:FIN:16S:SUBSAFE-}

Page 67: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

| 53

Chapter 8 TIBCO ActiveMatrix BusinessWorks SWIFT Plug-in: BICPlusIBAN Generator and Validator Activities

This example demonstrates the basic usage of the SWIFT BICPlusIBAN Generator and Validator activities for TIBCO ActiveMatrix BusinessWorks.

Topics

• Example Description, page 54

• Setting Up the Example, page 56

• Testing the Example, page 59

• Expected Results, page 60

Page 68: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

54 | Chapter 8 TIBCO ActiveMatrix BusinessWorks SWIFT Plug-in: BICPlusIBAN Generator and Validator Activities

Example Description

This example shows how to generate and validate the IBAN (International Bank Account Number) by using the BICPlusIBAN generator and validator in a TIBCO ActiveMatrix BusinessWorks process. The example has two processes, BICPlusIBAN Generation and BICPlusIBAN Validation.

BICPlusIBAN Generation process allows you generate the IBAN through the country code and the BBAN (Basic Bank Account Number). See Figure 6. During this process, two steps are operated at the backstage:

1. Validate BBAN

2. Generate Check Digit

Figure 6 SWIFT BICPlusIBAN Generation

The BICPlusIBAN Validation process allows you to validate the IBAN through the IBAN, the BIC (Bank Identifier Code), and the Branch Code. As shown in Figure 7, the process flow of this process is as the following:

Page 69: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

Example Description | 55

Figure 7 SWIFT BICPlusIBAN Validation

1. When the process starts, the Read File activity reads the $root\IN\MT102.txt file and passes it to the SWIFTNet-FIN Parser activity.

2. The SWIFT-FIN Parser activity validates the incoming MT102 message. If the message is correct, then it will be passed to the SWIFTNet BICPlusIBAN Validator activity.

3. The SWIFTNet BICPlusIBAN Validator activity validates the IBAN, BIC, and Branch Code in the message. If the information are correct, the whole record of the information about the financial institutions and their IBAN-related data are output.

Page 70: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

56 | Chapter 8 TIBCO ActiveMatrix BusinessWorks SWIFT Plug-in: BICPlusIBAN Generator and Validator Activities

Setting Up the Example

Before starting the example, you must open and customize the sample projects.

To open the example, follow these steps:

1. Extract the BICPlusIBAN-validation-and-generation sample ZIP file to TIB_ADSWIF_HOME/examples/BWPlugin/BW-activity-BICPlusIBAN- validation-and-generation

2. Start TIBCO Designer, then click the Open Existing Project button. The Open Project dialog appears.

3. In the Open Project dialog, click the Browse button and navigate to TIB_ADSWIF_HOME/examples/BWPlugin/BW-activity-BICPlusIBAN- validation-and-generation directory, then click the OK button.

4. Select Project > Save from the Menu.

To customize the example, follow these steps:

1. In the Project panel, click the BICPlusIBAN Generation process.

2. Click the SWIFTNet BICPlusIBAN Generator icon in the Design panel, then in the Configuration tab, set the value of the BICPlusIBAN Directory to be same as the one you download the BICPlusIBAN packages.

3. Click the Input tab, then type the values in the Country Code field and BBAN field.

Before processing the BICPlusIBAN Generator and Validator activities, you need to set the heap size to 1024 M in case the memory outbound error occurs.

When you specify the BICPlusIBAN directory, pay attention to the following:

— BICPlusIBAN directory is a mandatory field with an appropriate value.

— The BICPlusIBAN directory you provide must have the written permission.

— Within one project, the value of the BICPlusIBAN directory in BICPlusIBAN generator must be consistent with the one in BICPlusIBAN validator.

— When you are working with two different projects and setting the same value for the BICPlusIBAN directory. You must finish processing the first project, then start to process the second project.

— You can also use the Global Variable to set the BICPlusIBAN directory.

Page 71: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

Setting Up the Example | 57

4. Click the Global Variables panel, make sure the project directory path specified earlier. For example, TIB_ADSWIF_HOME/examples/BWPlugin/BW-activity-BICPlusIBAN- validation-and-generation. See Figure 8.

5. Click the Apply button, then select Project > Save from the Menu.

6. Follow the previous step 1, 2, and 4 to customize the SWIFTNet BICPlusIBAN Validator.

Figure 8 Configuring the SWIFT BICPlusIBAN Generator

Page 72: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

58 | Chapter 8 TIBCO ActiveMatrix BusinessWorks SWIFT Plug-in: BICPlusIBAN Generator and Validator Activities

Figure 9 Configuring the SWIFT BICPlusIBAN Validator

Page 73: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

Testing the Example | 59

Testing the Example

In TIBCO Designer:

1. Click the Project panel, and select the BICPlusIBAN Generation/BICPlusIBAN Validation process.

2. Click the Tester panel, then click the Start Testing Viewed Process button . In the process selection dialog that appears, check the BICPlusIBAN

Generation(current)/BICPlusIBAN Validation(current) checkbox, then click the Load Selected button. The process is now in the Test mode.

3. When the process executes, you will find the black arrows that point to each activity have turned to green.

4. Click the Stop Testing icon to return to the Design mode.

Explore the contents of the $root directory to ensure that it contains the expected results.

Page 74: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

60 | Chapter 8 TIBCO ActiveMatrix BusinessWorks SWIFT Plug-in: BICPlusIBAN Generator and Validator Activities

Expected Results

To view the result of the SWIFT BICPlusIBAN generation, follow these steps:

1. Click the SWIFT BICPlusIBAN Generator icon, then click the Output tab in the Configuration panel.

2. Expand the SWIFTBICPlusIBANGeneratorOutput item, the generated IBAN is displayed in the IBAN field. See the red rectangle in Figure 10.

Figure 10 Output of the SWIFT BICPlusIBAN Generation

To view the result of the SWIFT BICPlusIBAN validation, follow these steps:

1. Click the SWIFT BICPlusIBAN Validator icon, then click the Output tab in the Configuration panel.

2. Expand the BICPlusIBANRecord item, the whole information about the financial institutions and their IBAN-related data are displayed. See Figure 11.

Page 75: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

Expected Results | 61

Figure 11 Output of the SWIFT BICPlusIBAN Validation

Page 76: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

62 | Chapter 8 TIBCO ActiveMatrix BusinessWorks SWIFT Plug-in: BICPlusIBAN Generator and Validator Activities

Page 77: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

| 63

Chapter 9 TIBCO ActiveMatrix BusinessWorks SWIFT Plug-In: Exchange of Messages Using SOAP Protocol

This example demonstrates the exchange of messages by using SOAP Protocol.

Topics

• Example Description, page 64

• Setting Up the Example, page 66

• Testing the Example, page 67

• Expected Results, page 68

Page 78: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

64 | Chapter 9 TIBCO ActiveMatrix BusinessWorks SWIFT Plug-In: Exchange of Messages Using SOAP Protocol

Example Description

Messages are transferred over the SOAP connection has to use the XML format, which implements the local authentication at the message level. The SOAP communication channel supports session management and duplicate prevention, and can guarantee one time delivery.

The communication is always initiated by the back office. Therefore, only a SOAP client is required in the back office. SWIFT Alliance Access (SAA) acts as the SOAP server. Before proceeding, you should be familiar with the SWIFT Alliance Access.

As shown in the Figure 3, the process flow of this example is as the following:

Figure 12 Messages Exchange through SOAP Protocol

1. When the process starts, the Read File activity reads the $root\IN\MT103.RJE file and passes it to the SWIFTNet - FIN Parser activity.

Page 79: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

Example Description | 65

2. The SWIFTNet - FIN Parser activity validates the incoming MT103 message. If the message is correct, then the SOAP Open activity opens the SOAP connectivity.

3. The SOAP Put activity sends the message to the SAA message queue, then the SOAP Close activity closes the SOAP connectivity.

Page 80: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

66 | Chapter 9 TIBCO ActiveMatrix BusinessWorks SWIFT Plug-In: Exchange of Messages Using SOAP Protocol

Setting Up the Example

Before starting the example, you must open and customize the sample project.

To open the example:

1. Extract the SOAP sample ZIP file to TIB_ADSWIF_HOME/examples/SOAP-FileAct

2. Start TIBCO Designer, then click the Open Existing Project button. The Open Project dialog appears.

3. In the Open Project dialog, click the Browse button and navigate to TIB_ADSWIF_HOME/examples/SOAP-FileAct directory, then click the OK button.

4. Select Project > Save from the Menu.

To customize the example:

1. In the Project panel, select the SOAP for MT103(FileAct) process. Expand the Certs directory, then copy your own Identity_ssl file and saa_Access files and replace the default one.

2. Download the soapha file and SAA_XML_v2_0_2 file from the SAA server.

3. Click the Global Variables panel, expand the FAGroup item, select the MPName item, and click the Open Advanced Editor button . Change the value to be the one that you configured SOAP in SAA, then click the OK button. Keep other items in the FAGroup item as the default SWIFT standard, then save the project.

4. Expand the SWIFT item, make sure the project directory path specified earlier. For example, TIB_ADSWIF_HOME/examples/SOAP-FileAct.

5. Select the SOAP Open activity in the Design panel, then click the Transport Details tab. Enter the correct values for the Endpoint URL field.

6. Drag the scroll bar to the bottom of the Transport Details tab, then click the Configure SSL... button, and specify the Trusted Certificates directory field, then click the OK button.

7. Follow the previous 4 steps to customize the SOAP Put activity and the SOAP Close activity.

For all configuration related to SWIFT Alliance Access (SAA), see Alliance Access 7.0.40 System Management Guide and other SAA documentation set for details.

Page 81: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

Testing the Example | 67

Testing the Example

In TIBCO Designer:

1. Click the Project panel, and select the SOAP for MT103 (FileAct) process.

2. Click the Tester panel, then click the Start Testing Viewed Process button . In the process selection dialog that appears, the SOAP for MT103 (FileAct)(current) checkbox is checked by default. Click the Load Selected button. The process is now in the Test mode.

3. When the process executes, you will find the black arrows that point to each activity have turned to green.

4. Click the Stop Testing icon to return to the Design mode.

Explore the contents of the $root directory to ensure that it contains the expected results.

Page 82: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

68 | Chapter 9 TIBCO ActiveMatrix BusinessWorks SWIFT Plug-In: Exchange of Messages Using SOAP Protocol

Expected Results

The example results can be viewed in the SWIFT Alliance Access (SAA) work station where the message is stored in the message file.

Page 83: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

| 69

Index

A

AdviceOfExecution 16answer 34

B

BICPlusIBAN generation 54BICPlusIBAN validation 54BuyShares 17

C

CONFIG_HOME xiconventions used in this manual xivcustomer support xiv

E

ENV_NAM xi

F

FinancialInstitution 28

L

location 6

O

OrderBuyShares 16OrderFinInstitution 29OrderingInstitution 28overview of examples 2

P

prerequisites for running the examples 3

Q

query 34

S

SOAP 64Statement 34StatusStopPayment 8StopPaymentCheque 8support, contacting xiv

T

technical support xivtester.exe 11tester.tra 10TIB_ADSWIFT_HOME xiTIBCO ActiveMatrix BusinessWorks

Requesting Stop Payment of a Cheque by the

Page 84: TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples · TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples x |Related Documentation Related Documentation This section lists

TIBCO ActiveMatrix Adapter for SWIFTNet - FIN Examples

70 | Index

Drawer Bank 7TIBCO ActiveMatrix BusinessWorks SWIFT Plug-in

BICPlusIBAN Generator and Validator Activities 53TIBCO_HOME xitibrvlisten 31TradeAllocationInstruction 16typographical conventions xi

U

using TIBCO ActiveMatrix BusinessWorks 4using TIBCO ActiveMatrix BusinessWorks SWIFT

Plug-inexchange of messages using SOAP protocol 63renderer activity 47router and parser activities 39

W

working with DAT files in TIBCO designer 4


Recommended