Tivoli Directory Integrator, Version 7.1.1

Scripting in TDI

IBM® Tivoli® Directory Integrator provides its users with a highly-flexible engine that can be customized both from the user interface controls of the Configuration Editor, as well as through scripting of custom logic. While the user interface controls provide a means of controlling the data flow at a higher level, scripting provides you with the ability to control almost any aspect of the data flow at any level, including overriding standard Tivoli Directory Integrator processing. Special functions are available in the system object to reiterate on an AssemblyLine entry, skip a Connector and start new AssemblyLines. The scripting language used for implementing this custom logic is JavaScript.

Ready-to-use, Tivoli Directory Integrator provides the tools to quickly snap together the framework of an integration solution. However, for all but the most trivial migration jobs, you will need to customize and extend the built-in behavior of the product by writing JavaScript.

Tivoli Directory Integrator is pure Java. Whenever you issue a command to Directory Integrator, work with components and objects, or manipulate data in your flow, you are working with Java objects. IBM Tivoli Directory Integrator v7.1.1 uses IBM Java version 1.6.

Your customization on the other hand is done in JavaScript, and this marriage of two ostensibly similar, yet fundamentally different, programming languages warrants closer examination.

Experience with JavaScript will be very helpful. The examples provided may add to your experience. However, this manual does not teach JavaScript itself , merely its application in TDI. You will need to secure your JavaScript reference materials elsewhere.

There are a number of commercially available reference guides to JavaScript, as well as documentation, tutorials and examples on the net. Note however that much of the JavaScript content out on the Web is related to beautifying and automating HTML content. You need only concern yourself with the core language itself, as it is described at the following link: http://devedge-temp.mozilla.org/library/manuals/2000/javascript/1.5/guide/index.html

There is also a handy link on this site for downloading the reference in HTML format for installation locally. An excellent handbook on JavaScript is The Definitive JavaScript Guide, 4th Edition by David Flanagan (O'Reilly).

You will also want the Javadocs for Java as well, since all TDI objects, as well as the data values inside your solution, are in the form of Java objects. These documents are located online at this URL: http://docs.oracle.com/javase/1.6.0/docs/api/index.html

The J2SE documentation itself can be found here: http://docs.oracle.com/javase/1.6.0/docs/index.html

Scripting is necessary when you need to add custom processing to your AssemblyLine. Examples of where scripting can be helpful include the following tasks:
Attribute manipulation or computation
You need to calculate the value of an output attribute based on one or more input attributes.
Data filtering
You want to process only entries that match a particular set of criteria.
Data consistency or validity checking
You need to report or correct invalid data values.
Flow control
You want to override the update operation of the Connector you are using.
You want to run some initializing procedures before your AssemblyLine starts.
Each of these cases mentioned, and many others not mentioned, usually require scripting.


Go to the examples/scripting subdirectory of your IBM Tivoli Directory Integrator installation.

[ Terms of use | Feedback ]
(C) Copyright IBM Corporation, 2003, 2012. All Rights Reserved.
IBM Tivoli Directory Integrator 7.1.1