Copyright © TIBCO Software Inc. All Rights Reserved
Copyright © TIBCO Software Inc. All Rights Reserved


Chapter 4 TIBCO ActiveMatrix BusinessWorks: Working with the OrderedAccountCreate API Call : Running the Example

Running the Example
Perform the following tasks to run the example.
 
Task A Starting the Adapter
1.
Edit the adkenan.tra file. This is located in $TIBCO_HOME/adapter/adkenan/<version_num>/bin. Specify the repourl as the location where the local repository was saved in the previous section (Refer Task J, Converting the repository into .dat format). Specify the configurl as /tibco/private/adapter/KenanAdapterConfiguration.
2.
Open a new console session on the UNIX machine where the adapter is installed and the Kenan/FX middleware is running.
3.
Move to $TIBCO_HOME/adapter/adkenan/<version_num>/bin and type adkenan. This brings up the adapter and displays the message Successfully initialized the adapter.
Task B Running the TIBCO ActiveMatrix BusinessWorksProcess
1.
Start TIBCO Designer.
Click Programs > TIBCO > TIBCO Designer <version_num>> Designer <version_num>.
2.
In the initial dialog box, click Open Existing Project. Browse and select the location where the project was saved in Task A, Importing the project in the section , Set up the OrderedAccountCreate Example.
3.
Click procCreateOrderedAccount in the Process folder. The BusinessWorks process is displayed as shown next:
4.
Check the value or the RvDaemon global variable to see whether it reflects the same parameter of the repository which is being used by the adapter to run.
5.
Provide a valid location for the output file in both the Write File activities titled Success and Error. The file associated with success will have the reply XML message sent by Kenan/BP to the request sent by the adapter and the error will have the Exception message sent by the adapter, in case of an error. To provide a valid location for the output file, double -click the corresponding Write File icon, select the Input tab and edit the filename parameter.
6.
Provide a valid value for the AccountInternalId field in the Mapper task. Double-click the mapper icon, select the Input tab, expand the OrderedAccountCreate node and then the Account node till you see the AccountInternalId field (inside the Key node). Ensure that the AccountInternalId specified here is not present in the application records (Check the CMF table for the same). The adapter will try to create an account with the same Internal ID. You may also specify various other parameters (like AccountExternalId, First name, Company name) of the account to be created. You may do so by editing the parameters under the Account node. The configuration is displayed as shown next:
 
Edit the date fields CreateDt, LockDt in the order, as applicable. The format for the date fields is tib:create-dateTime(<year>,<month>,<day>,<hr>,min>,<sec>). For example, 10th January, 2004 12:33:24 would be written as tib:create-dateTime(2004,01,10,12,33,24). This format is then converted by the custom Java code function to a date format acceptable to Kenan middleware. For more information about the data converter, refer to TIBCO ActiveMatrix Adapter for Kenan/BP Configuration and Deployment.
7.
Provide a valid value for the Order. Double-click the mapper icon, select the Input tab, expand the OrderedAccountCreate node, and then order node till you see the OrderId field (inside the Key node). Ensure that the order is already present in the ORD_ORDER table and is not locked. The Mapper task is displayed as shown next:
 
8.
Set the VerboseResponse flag (under the OrderedAccountCreate node) as true. This will show all the business entities created in the process.
9.
Trigger the TIBCO ActiveMatrix BusinessWorksprocess. Select the Tester tab in the project panel and press F9. In the next dialog box, click Load & Start Current.

Copyright © TIBCO Software Inc. All Rights Reserved
Copyright © TIBCO Software Inc. All Rights Reserved