You can create a plug-in for a custom repository type to
authenticate, search, and provide result sets for repository servers.
For example, you might want to use a custom repository type to extend
IBM® Content
Navigator for your client
application to use repositories that do not store documents. The custom
repository type enables repository-specific authentication and other
actions for your repository server.
Before you begin
Decide whether to use the custom repository type feature or
use CMIS to support the connection between
IBM Content
Navigator and your custom repository.
- The custom repository type feature is a proprietary interface
that uses the IBM Content
Navigator JSON
API. It was initially intended to support communication between internal
Enterprise Content Management products and IBM Content
Navigator.
- CMIS is an
open standards interface. It is recommended that you use an open standards
interface rather than a proprietary interface. If you decide to use CMIS, more help is available
in the OpenCMIS Server Development Guide.
About this task
If you decide to use the custom repository type proprietary
interface instead of using CMIS,
follow the steps that are provided in this task.
Procedure
To define a repository type:
- Create an internal identifier for the repository. The identifier is used for the return value for the PluginRepositoryType.getId
method and the PluginRepositoryConnection.getType method.
- Create a name for the repository. The
name is displayed in the user interface.
- Extend the PluginRepositoryType class
to describe the repository type:
- Implement the getId method to return
the internal identifier that you created in step 1.
- Implement the getName method to return
the name that you created in step 2.
- Implement the login method to handle
any repository-specific logic for desktop login. The login
action is separate from all other actions so that it can be started
from the desktop login when the repository is the authenticating repository.
- Implement the performAction to handle
an action for the repository. The action is passed as a
request parameter. The return parameter is a JSON response that is
built by the logic in this method. You can use com.ibm.ecm.json classes
to make this task easier.
- Extend the PluginRepositoryConnection class
to describe the repository connection:
- Implement the getName method to return
the internal identifier that you created in step 1.
- Implement the getUserId method to
return the user identifier that was entered at login.
- Implement the getUserName method
to return the long name of the user for the banner.
- Create subclasses that extend the classes
in the Java script files PluginRepositoryGeneralConfigurationPane.js and PluginRepositoryConfigurationParametersPane.js to
create a general configuration pane, and a configuration parameters
pane for configuring your custom repository.
Sample plug-in files for a custom repository type
The
following files in the sample plug-in define a repository type for
a repository server that does not store documents.
Table 1. Sample files that define a plug-in repository
typeFile |
Description |
SamplePluginRepositoryType.java |
This file extends the PluginRepositoryType.java class
to create a repository type for a repository server that does not
store documents. |
What to do next
After you add the plug-in, you can select the repository
type name from the menu for
Create repository in
the
IBM Content
Navigator administration
tool. When you configure your repository, select the custom repository
type for the plug-in and enter values in the general configuration
pane and the configuration parameters pane that you created in step
5.