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


Chapter 5 TIBCO ActiveMatrix BusinessWorks: Demonstrating Custom Function Callout : 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.
The name of the factory class needs to be specified in the adapter property file. The property adkenan.KenanCustomCallOutFactoryName should be uncommented and the name of Custom Factory class should be provided. For example, adkenan.KenanCustomCallOutFactoryName KenanCustomFactory.
3.
Open a new console session on the UNIX machine where the adapter is installed and the Kenan/FX middleware is running.
4.
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.
3.
Click procInvokeCustFunc 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 other one (associated with error) will have the Exception message being sent by the adapter, in case of error. For providing 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 custom function. Double-click the Render XML task. Expand the CustomRequest node followed by the Header node till you reach the CustomFunctionName node. For the factory class in this example, the valid values of CustomFunctionName are KenanCustom and KenanCustomAcct. The render XML task is displayed as shown next:
7.
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