Create a lookup connector 

Create a lookup connector to fetch data for a single user, including all the attributes necessary for mapping that user in your directory.

About this task

The lookup assembly line is used in the populate_from_dns_file script to populate users one by one. In addition, using the default mapping for secretary ($secretary_uid) and manager ($manager_uid), the script uses the assembly line to look up the manager and secretary uid values. If you can extract the manager and secretary uid values from the work entry without an additional lookup, it is advisable to do so; having to perform one or two additional directory lookups per user in a directory containing thousands of users can be very costly.

After developing your lookup connector, the next step is to export it. You must then restart the Tivoli Directory Integrator configuration editor to make the adapter file visible to the Profiles TDI solution. To test the adapter, configure the Profiles TDI solution to use your adapter for data lookup. You can then test the adapter using the TEST_source_repository_lookup script provided by the TDI solution.


Create a source repository lookup connector by completing the following steps:

  1. Develop your lookup assembly line.

  2. Export your lookup solution by completing the following steps:

      Note: You can package the lookup connector together with the iterator assembly line, which is best practice although not a required step.

      1. Shift-click the assembly lines that comprise your lookup solution in the IBM Tivoli Directory Integrator Config Editor.

      2. Right-click a member of the selected assembly line group and select Publish.

      3. In the Publish window, enter a name for your solution in the Package ID field. For example, myLookupAdapter.

      4. Optional: Enter additional information, such as a version number or a help URL for future administrators.

      5. Assuming you followed the development environment set-up guide outlined in the topic, Setting up your development environment, select the packages directory located in your IBM Connections TDI solution from the File Path drop-down menu, and then click Finish.

          Note: If you are using Tivoli Directory Integrator 7.0 Fix Pack 5, when you export your connector, any references to .properties file resources are removed. If the only .properties file you are referencing is the Profile properties file,, run the command fixup_tdi_adapters.bat (Microsoft™ Windows™) or (AIX or Linux™) located in the root of the TDI solution directory. Running this command re-adds the reference to the profiles property store to your adapter.xml file. If you are referencing your own .properties file, you need to open the adapter.xml file and manually edit the <Stores> section of the XML file. Fix Pack 6 is expected to resolve this issue.

  3. To make the adapter file visible to the Profiles TDI solution, restart the Tivoli Directory Integrator Config Editor.

      If the Tivoli Directory Integrator server is not recycled during testing, it might not detect the existence of the new adapter.xml file. Recycling the Config Editor stops and starts the embedded Tivoli Directory Integrator server.

  4. Configure the Profiles TDI solution to use your adapter for data lookup by completing the following steps:

    1. Open the file in a text editor.

    2. Copy the following line, removing the comment notation:


    3. Substitute {name-of-your-adapter.xml} with the package ID entered in step 2c.

    4. Substitute {name-of-your-ITERATOR-al} with the name of your lookup assembly line.

        The line should now look similar to the following:


    5. Save your changes and then close the file.

  5. Test your lookup adapter using the TEST_source_repository_lookup script in the Profiles TDI solution. To use this script:

    1. Configure the assembly line as described in the steps above.

    2. Write the distinguished names of a number of users in a file called collect.dns and place this file at the root of the Profiles TDI solution directory. Each distinguished name should be separated by a carriage return.

    3. Run the following command.

      • AIX or Linux:


      • Microsoft Windows:

          runAl.bat TEST_source_repository_lookup

        This command iterates over the collect.dns file and attempts to look up each user that you specified in turn. The resulting data returned by your adapter is dumped into the ibmdi.log file located in the {TDISOLN}/logs/ibmdi.log directory. You can examine this file to confirm that it is returning all of the expected values correctly.

    4. Repeat the steps above as needed until you are satisfied with the output of your adapter.

Parent topic

Use a custom source repository connector

Related tasks

Setting up your development environment
Create an iterator connector