Cheshire3 Configuration: ZeeRex

Introduction

ZeeRex is a schema for service description and is required for SRW but it can also be used to describe Z39.50, OAI and other information retrieval protocols. As such, a ZeeRex description is required for each database. The full ZeeRex documentation is available at http://explain.z3950.org/ along with samples, schemas and so forth. It is also being considered as the standard service description schema in the NISO Metasearch Initiative, so knowing about it won't hurt you any.

In order to map from a CQL query, we need to know the correlation between CQL index name and Cheshire3's index object. Defaults for the SRW handler for the database are also drawn from this file, such as the default number of records to return and the default record schema. Mappings between requested schema and a transformer object are also possible. This is handled by a ProtocolMap.

Examples

<subConfig type="protocolMap" id="l5rProtocolMap">
  <objectType>protocolMap.CQLProtocolMap</objectType>
  <paths>
    <object type="zeerexPath">srw_zeerex.xml</path>
  </paths>
</subConfig>

<explain id="org.o-r-g.srw-card" authoritative="true"
  xmlns="http://explain.z3950.org/dtd/2.0/"
  xmlns:c3="http://www.cheshire3.org/schemas/explain/">
  <serverInfo protocol="srw/u" version="1.1" transport="http">
     <host>srw.cheshire3.org</host>
     <port>8080</port>
     <database numRecs="3492" lastUpdate="2002-11-26 23:30:00">srw/l5r</database>
  </serverInfo>
  [...]
  <indexInfo>
     <set identifier="http://srw.cheshire3.org/contextSets/ccg/1.0/" name="ccg"/>
     <set identifier="http://srw.cheshire3.org/contextSets/ccg/l5r/1.0/" name="ccg_l5r"/>
     <set identifier="info:srw/cql-context-set/1/dc-v1.1" name="dc"/>

     <index c3:index="l5r-idx-1">
        <title>Card Name</title>
        <map><name set="dc">title</name></map>
        <configInfo>
          <supports type="relation" c3:index="l5r-idx-1">exact</supports>
          <supports type="relation" c3:index="l5r-idx-15">any</supports>
          <supports type="relationModifier" c3:index="l5r-idx-15">word</supports>
          <supports type="relationModifier" c3:index="l5r-idx-1">string</supports>
          <supports type="relationModifier" c3:index="l5r-idx-16">stem</supports>
        </configInfo>
     </index>
  </indexInfo>
  <schemaInfo>
     <schema identifier="info:srw/schema/1/dc-v1.1"
             location="http://www.loc.gov/zing/srw/dc.xsd"
             sort="false" retrieve="true" name="dc"
             c3:transformer="l5rDublinCoreTxr">
        <title>Dublin Core</title>
     </schema>
  </schemaInfo>
</explain>  

<zrx:database>

The contents of the field MUST match up with the what has been configured for Apache. If you configured with mapping /srw/ to the srwApacheHandler code, then the first part of the database MUST be srw/. Obviously the rest of the information in serverInfo should be correct as well, but without the database field being correct, it won't load.

c3:index

This attribute may be present on an index element, or a supports element within configInfo within an index. It maps that particular index, or the use of the index with a relation or relationModifier, to the Index object with the given id. RelationModifiers and relations will override the index as appropriate.

c3:transformer

Similar to c3:index, this can be present on a schema element and maps that schema to the transformer used to process the internal schema into the requested one. If the schema is the one used internally, then the attribute should not be present.

Paths