4.11. Linked Attributes Plug-in Attributes

Many times, entries have inherent relationships to each other (such as managers and employees, document entries and their authors, or special groups and group members). While attributes exist that reflect these relationships, these attributes have to be added and updated on each entry manually. That can lead to a whimsically inconsistent set of directory data, where these entry relationships are unclear, outdated, or missing.
The Linked Attributes Plug-in allows one attribute, set in one entry, to update another attribute in another entry automatically. The first attribute has a DN value, which points to the entry to update; the second entry attribute also has a DN value which is a back-pointer to the first entry. The link attribute which is set by users and the dynamically-updated "managed" attribute in the affected entries are both defined by administrators in the Linked Attributes Plug-in instance.
Conceptually, this is similar to the way that the MemberOf Plug-in uses the member attribute in group entries to set memberOf attribute in user entries. Only with the Linked Attributes Plug-in, all of the link/managed attributes are user-defined and there can be multiple instances of the plug-in, each reflecting different link-managed relationships.
There are a couple of caveats for linking attributes:
  • Both the link attribute and the managed attribute must have DNs as values. The DN in the link attribute points to the entry to add the managed attribute to. The managed attribute contains the linked entry DN as its value.
  • The managed attribute must be multi-valued. Otherwise, if multiple link attributes point to the same managed entry, the managed attribute value would not be updated accurately.

4.11.1. linkScope

This restricts the scope of the plug-in, so it operates only in a specific subtree or suffix. If no scope is given, then the plug-in will update any part of the directory tree.
Parameter Description
Entry DN cn=plugin_instance,cn=Linked Attributes,cn=plugins,cn=config
Valid Range Any DN
Default Value None
Syntax DN
Example linkScope: ou=People,dc=example,dc=com

4.11.2. linkType

This sets the user-managed attribute. This attribute is modified and maintained by users, and then when this attribute value changes, the linked attribute is automatically updated in the targeted entries.
Parameter Description
Entry DN cn=plugin_instance,cn=Linked Attributes,cn=plugins,cn=config
Valid Range Any Directory Server attribute
Default Value None
Syntax DirectoryString
Example linkType: directReport

4.11.3. managedType

This sets the managed, or plug-in maintained, attribute. This attribute is managed dynamically by the Linked Attributes Plug-in instance. Whenever a change is made to the managed attribute, then the plug-in updates all of the linked attributes on the targeted entries.
Parameter Description
Entry DN cn=plugin_instance,cn=Linked Attributes,cn=plugins,cn=config
Valid Range Any Directory Server attribute
Default Value None
Syntax DN
Example managedType: manager