Developing Portlets and Integration Web Services: Crawlers and Search Services

Deploying Custom Search Services

After coding your crawler as explained on the previous pages, you must deploy your code and configure the necessary objects in the portal.

Deploying Search Service Code

The deployment process is different for Java and .NET. The deployment process is different for Java and .NET. This page summarizes the deployment process for search services. For detailed information on deployment, see Deploying Web Services.

Java

Follow the instructions below to deploy Java crawlers.

  1. Compile the class that implements the EDK interface and copy the entire package structure to the appropriate location in your Web application (usually the \WEB-INF\classes directory).

  2. Update the web.xml file in the WEB-INF directory by adding the class to the appropriate *Impl keys. For example, for a crawler, add your class to SearchImpl as shown below.

...
<env-entry>
<env-entry-name>SearchImpl</env-entry-name>
<env-entry-value>com.plumtree.remote.search.helloworld.Search</env-entry-value>
<env-entry-type>java.lang.String</env-entry-type>
</env-entry>
...

Note:The *Impl key in the web.xml file must reference the fully-qualified name of the class. If the service uses SCI, you must also enter the fully-qualified name of the appropriate implementation of the IAdminEditor interface.

  1. Start your application server. (In most cases, you must restart your application server after copying a file.)

  2. Test the directory by opening the following page in a Web browser: http://<hostname:port>/edk/services/<servicetype>ProviderSoapBinding (e.g.,
    http://localhost:8080/edk/SearchSoapBinding. The browser should display the following message: "Hi there, this is an AXIS service! Perhaps there will be a form for invoking the service here..."

  3. Configure the new service in the portal:

    1. Open the portal in a browser and navigate to the Administration folder where you want the new service to be stored.

    2. Click Create Object... and choose the appropriate Web Service type from the menu.

    3. On the Main Page of the Web Service Editor, enter the service provider URL from Step 4. For SCI pages, enter the Service Configuration page URL(s) on the Advanced URLs page of the Web Service Editor. (URLs are relative to the Remote Server.)

.NET

Add a line to the deployment file (web.config) that specifies the fully qualified name of the class used to implement the search service (see Creating Custom Search Services). For search service, you must enter values for these parameters, as shown in the code that follows:

...
<appSettings>
<add key="SearchAssembly" value="CompanyStoreSWS"/>
<add key="SearchImpl" value="Plumtree.CompanyStore.SWS.CompanyStoreSWS"/>
...

In addition, you must deploy SCI if it is used by your search service.

Configuring Search Services in the Portal

To register a search service in the portal, you must create the following administrative objects:

For more details on portal objects, see the Portal Administrator's Guide and the portal online help.

Settings and Preferences

As noted earlier, User Preferences and User Information can be used to authenticate with the back-end system or limit access to specific users. The User Preferences that should be sent to the crawler or DocFetch servlet must be configured on the Preferences page in the Search Web Service editor. List the unique names of all User Preferences (User settings) that should be sent.

The User Information settings that should be sent to DocFetch must be configured on the User Information page in the Search Web Service editor. Choose all User Information settings that should be sent to the search service. Standard settings are displayed in the top pane; add any additional User Information settings by typing them in the textbox or clicking Add Existing User Info.

If there are administrative settings to be configured that apply to all instances of the search service, add a Service Configuration page (see Advanced URLs below).

Advanced Settings

The following settings are configured on the Advanced Settings page of the Search Web Service editor.

Advanced URLs

If there are administrative settings to be configured that apply to all instances of the search service (e.g., path and credentials to access a remote server), add a Service Configuration page. The Service Configuration page URL entered on the Advanced URLs page of the Search Web Service editor will be included as a page in the associated Federated Search editor.