How The Server Updates The Index - Netscape DIRECTORY SERVER 6.02 - PLUG-IN Manual

Table of Contents

Advertisement

Indexing Based on Matching Rules
The server gets the OID returned in the
associates this OID with the rest of the attribute indexing information (such as the
attribute type and the type of index) for future reference.
When adding, modifying, or deleting the values of an attribute, the server will
check this information to determine if the attribute is indexed. See "How the Server
Updates the Index" on page 130 for information on how attributes are indexed.

How the Server Updates the Index

When a value is added, modified, or removed from an attribute in an entry (or
when the RDN of an entry is changed), the server does the following if that
attribute has an index that uses matching rules:
In a new
1.
parameters:
Next, the server calls the indexer factory function (specified in the
2.
SLAPI_PLUGIN_MR_INDEXER_CREATE_FN
the indexer object.
The server generates the index keys for the values to be added or deleted:
3.
The server inserts or deletes the keys and values in the index for that attribute.
4.
The server calls the indexer destructor function (specified in the
5.
SLAPI_PLUGIN_MR_DESTROY_FN
When the server is done, it frees any parameter blocks that were allocated during
this process.
130
Netscape Directory Server Plug-In Programmer's Guide • May 2002
parameter block, the server sets the following
Slapi_PBlock
Sets the OID in the
SLAPI_PLUGIN_MR_OID
Sets the attribute type (of the value being added, modified, or removed) in
the
SLAPI_PLUGIN_MR_TYPE
The server first verifies that the
specifies an indexer function and the
specifies the official OID of the matching rule.
If these are both set, the server sets the
parameter to the array of
modified values that need to be indexed and calls the indexer function.
Next, the server gets the value of the
which is an array of
berval
to the values.
SLAPI_PLUGIN_MR_OID
parameter.
parameter.
parameter) for the plug-in to create
SLAPI_PLUGIN_MR_INDEX_FN
SLAPI_PLUGIN_MR_OID
SLAPI_PLUGIN_MR_VALUES
structures containing the new or
berval
SLAPI_PLUGIN_MR_KEYS
structures containing the keys corresponding
parameter) to free the indexer object.
parameter and
parameter
parameter
parameter,

Advertisement

Table of Contents
loading

This manual is also suitable for:

Directory server 6.02

Table of Contents