README revision bb8874d71cdd8e5288297b9727703437c6dfcfed
bb8874d71cdd8e5288297b9727703437c6dfcfedmatthew_swiftThis folder contains source code for an example "Hello World" style
bb8874d71cdd8e5288297b9727703437c6dfcfedmatthew_swiftplugin. It features a plugin which has a configurable message (the
bb8874d71cdd8e5288297b9727703437c6dfcfedmatthew_swiftdefault being "Hello World") which is displayed as a notice message
bb8874d71cdd8e5288297b9727703437c6dfcfedmatthew_swiftwhen an OpenDS instance is started.
bb8874d71cdd8e5288297b9727703437c6dfcfedmatthew_swift
bb8874d71cdd8e5288297b9727703437c6dfcfedmatthew_swiftIn order to build and use this example plugin, perform the following
bb8874d71cdd8e5288297b9727703437c6dfcfedmatthew_swiftsteps (presumably you are already at step 4):
bb8874d71cdd8e5288297b9727703437c6dfcfedmatthew_swift
bb8874d71cdd8e5288297b9727703437c6dfcfedmatthew_swift 1. In the top-level source folder for OpenDS, first build and
bb8874d71cdd8e5288297b9727703437c6dfcfedmatthew_swift package OpenDS:
bb8874d71cdd8e5288297b9727703437c6dfcfedmatthew_swift
bb8874d71cdd8e5288297b9727703437c6dfcfedmatthew_swift ./build.sh
bb8874d71cdd8e5288297b9727703437c6dfcfedmatthew_swift
bb8874d71cdd8e5288297b9727703437c6dfcfedmatthew_swift 2. Next go into the packages folder:
bb8874d71cdd8e5288297b9727703437c6dfcfedmatthew_swift
bb8874d71cdd8e5288297b9727703437c6dfcfedmatthew_swift cd build/package/OpenDS-0.1
bb8874d71cdd8e5288297b9727703437c6dfcfedmatthew_swift
bb8874d71cdd8e5288297b9727703437c6dfcfedmatthew_swift 3. Then unzip the example-plugin.zip (in place):
bb8874d71cdd8e5288297b9727703437c6dfcfedmatthew_swift
bb8874d71cdd8e5288297b9727703437c6dfcfedmatthew_swift unzip example-plugin.zip
bb8874d71cdd8e5288297b9727703437c6dfcfedmatthew_swift
bb8874d71cdd8e5288297b9727703437c6dfcfedmatthew_swift 4. Go into the example-plugin source folder:
bb8874d71cdd8e5288297b9727703437c6dfcfedmatthew_swift
bb8874d71cdd8e5288297b9727703437c6dfcfedmatthew_swift cd example-plugin
bb8874d71cdd8e5288297b9727703437c6dfcfedmatthew_swift
bb8874d71cdd8e5288297b9727703437c6dfcfedmatthew_swift 5. And build the plugin (this requires Ant in your path):
bb8874d71cdd8e5288297b9727703437c6dfcfedmatthew_swift
bb8874d71cdd8e5288297b9727703437c6dfcfedmatthew_swift ant install
bb8874d71cdd8e5288297b9727703437c6dfcfedmatthew_swift
bb8874d71cdd8e5288297b9727703437c6dfcfedmatthew_swift 6. This will copy the following files into the parent OpenDS
bb8874d71cdd8e5288297b9727703437c6dfcfedmatthew_swift installation:
bb8874d71cdd8e5288297b9727703437c6dfcfedmatthew_swift
bb8874d71cdd8e5288297b9727703437c6dfcfedmatthew_swift lib/extensions/example-plugin.jar
bb8874d71cdd8e5288297b9727703437c6dfcfedmatthew_swift config/example-plugin.ldif
bb8874d71cdd8e5288297b9727703437c6dfcfedmatthew_swift config/schema/99-example-plugin.ldif
bb8874d71cdd8e5288297b9727703437c6dfcfedmatthew_swift
bb8874d71cdd8e5288297b9727703437c6dfcfedmatthew_swift 7. Add the plugin's config to the server configuration. The
bb8874d71cdd8e5288297b9727703437c6dfcfedmatthew_swift following instruction assumes usage of the Unix 'cat'
bb8874d71cdd8e5288297b9727703437c6dfcfedmatthew_swift command, but obviously ldapadd can be used:
bb8874d71cdd8e5288297b9727703437c6dfcfedmatthew_swift
bb8874d71cdd8e5288297b9727703437c6dfcfedmatthew_swift cd ../config
bb8874d71cdd8e5288297b9727703437c6dfcfedmatthew_swift cat example-plugin.ldif >> config.ldif
bb8874d71cdd8e5288297b9727703437c6dfcfedmatthew_swift
bb8874d71cdd8e5288297b9727703437c6dfcfedmatthew_swift 8. Start the server and look for the "hello world" notice in the start
bb8874d71cdd8e5288297b9727703437c6dfcfedmatthew_swift up log:
bb8874d71cdd8e5288297b9727703437c6dfcfedmatthew_swift
bb8874d71cdd8e5288297b9727703437c6dfcfedmatthew_swift cd ..
bb8874d71cdd8e5288297b9727703437c6dfcfedmatthew_swift ./bin/start-ds