Select Adapter from the task selection bar. The Adapter navigation tree appears.

Customizing Oracle Virtual Directory 18-5 virtual directory to have a chance to further process the request through other plug-ins, you would call the chain.nextAdd method. Most plug-in methods have corresponding chain.nextXXX methods. If you do not want to allow further processing of the request by plug-ins, you can omit the chain.nextXXX call.

18.3.3 Plug-In Implementation Points

Before you can build a custom plug-in, you must decide whether to implement the com.octetstring.vde.chain.Plugin interface or extend the com.octetstring.vde.chain.BasePlugin class. The BasePlugin class is a convenience that allows a plug-in developer to only implement the methods for operations to be handled by the plug-in. The example plug-in in this chapter extends the BasePlugin class to simplify the implementation. The sections in this topic describe the Oracle Virtual Directory plug-in implementation points, including: ■ Configuration, Startup, and Shutdown Plug-In Implementation Points ■ Availability Plug-In Implementation Point ■ Operation Plug-In Implementation Point

18.3.3.1 Configuration, Startup, and Shutdown Plug-In Implementation Points

Configuration is the first plug-in implementation point. Plug-ins are configured using a set of simple name and value pairs provided by the Oracle Virtual Directory configuration system. The pairs are provided to the plug-in developer through the params argument to the init method of the plug-in. The example plug-in in this chapter includes the following configuration options: ■ countAttribute: An attribute to be attached to all user entries that store the bad password count. ■ addOnCreate: Boolean value set to true if the plug-in adds this attribute when a user is created. ■ objectClassForAdd: The object classes that represent users to which the attribute is added. ■ ignoreOnModify: Boolean value, set to true if modify requests on the countAttribute should be ignored. The configuration options listed above are picked-up at the life cycle methods, which is the second implementation point. The init method is called on the initialization of the plug-in at server startup and the destroy method is called when the plug-in is being shutdown. Example 18–1 shows an example init method: Example 18–1 Example init Method Passes initialization information to the Plug-in param initParams Hashmap of keyvalue pairs specified in initial config param name The name specified in the config for this Plug-in Note: The adapter type is irrelevant to the plug-ins, as plug-ins can be added to any type of adapter.