sru: Providing SRU Access to Bib Class Collections

Overview and Contents

sru is the CGI program that produces XML responses to SRU requests as dictated by the SRU protocol. Setting up sru will allow federated search engines/clients to search your Bib Class collections. To learn about the SRU protocol go to http://www.loc.gov/standards/sru/

Contents:

Setup Default Parameters

The SRU protocol needs a default Bib Class collection to search, along with some other default values. During installation you will be prompted for the values of these default parameters, but you can also change them any time in /$DLXSROOT/cgi/s/sru/sru.cfg. Here is a list of the parameters that need to be set up for your particular institution:

Also, you will need to add the Bib Class collections to the AUTH system for sru, so that this cgi tool can have access to them.

Sample Requests

This implementation of sru just implements the explain operation and the searchRetrieve operation. The explain operation identifies the repository. There are two ways to make an explain request-- one is to not pass any parameters and the other is to pass an explain request. The following two links from UM's implementation demonstrate this:

The other operation is searchRetrieve. This operation is used to request the number of hits for a particular search ( query ), and then retrieve the results from the search. The particular collection to search can be passed in the x-collid parameter. If no x-collid parameter is passed, then the configured default collection is searched. The SRU protocol allows very robust query requests, but it is not mandatory that all these query requests be SRU compliant. For now, we have chosen to implement only level 0 of the SRU CQL language (term-only searches). The following examples from UM show how the searchRetrieve operation can be used to request hits for a particular search, and then retrieve the first 4 records returned by the search: