The Server SDK provides a set of APIs that allow Java developers to extend the server-side capabilities of the Data Governance Server, as well as the Directory Server.
For detailed information, including an API reference and example extensions, please see the Server SDK documentation.
Data Governance Server extensions
The Data Governance Server provides numerous extension points through the Server SDK. The following table lists some of the available extension types.
|Access Token Validator||Allows the Data Governance Server to accept access tokens issued by a third-party authentication server.|
|Policy Information Provider||Provides custom information to the Data Governance Server’s XACML policy engine, which may then be factored into policy decisions.|
|Store Adapter||Provides a native interface from the Data Governance Server to a backend data store, such as a relational database or a web service. This allows a user store to include non-LDAP data stores.|
|Alert Handler||Generates alert notifications to server administrators based on custom conditions.|
|HTTP Servlet Extension||Used to create servlets that extend the server’s HTTP services.|
|Monitor Provider||Reports custom state information in the server’s monitor backend. This is often used in conjunction with another custom extension to report the extension’s status.|
Obtaining the Server SDK
The official Server SDK package, which contains binaries, documentation, and examples, is available through your sales or support representative.
For ease of development, the Server SDK library is also published to Maven Central with every server release. You can use the following Maven coordinates in your POM.
<dependency> <groupId>com.unboundid</groupId> <artifactId>server-sdk</artifactId> <version>184.108.40.206</version> </dependency>
Creating and building a Server SDK extension
Server SDK extensions must be packaged into a zip archive with a specific directory structure, called an extension bundle. To ensure that your project correctly generates an extension bundle, we recommend that you create your project using the Server SDK Maven archetype.
To create a new Server SDK extension project, use the following Maven command, substituting your own
$ mvn archetype:generate -DarchetypeGroupId=com.unboundid \ -DarchetypeArtifactId=server-sdk-archetype \ -DarchetypeVersion=1.0.14 \ -DgroupId=com.example -DartifactId=my-extension \ -DinteractiveMode=false
The new project will contain an example extension, which you should customize or replace. You will also need to customize the generated
pom.xml to add any dependencies required by your project. The Maven project can be easily loaded in popular Java IDEs, such as IntelliJ IDEA or Eclipse.
When you are ready to build an extension bundle, run
mvn package. The extension bundle will be created as a zip in the
Installing a Server SDK extension
A Server SDK extension bundle is installed using the
manage-extension tool, which validates the structure of the extension bundle, unpacks it to the server’s
extensions directory, and restarts the server so that the extension classes are loaded and available.
$ PingDataGovernance/bin/manage-extension --install /path/to/com.example.my-extension.zip
After an extension bundle is installed, a little further configuration is generally required. This will vary from extension to extension.
Updating a Server SDK extension
manage-extension tool is also used when you need to install an updated version of an extension bundle to the server.
$ PingDataGovernance/bin/manage-extension --update /path/to/com.example.my-extension.zip