Added pz:sort setting
[pazpar2-moved-to-github.git] / doc / pazpar2_conf.xml
1 <?xml version="1.0" standalone="no"?>
2 <!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook V4.1//EN"
3  "http://www.oasis-open.org/docbook/xml/4.1/docbookx.dtd"
4 [
5      <!ENTITY % local SYSTEM "local.ent">
6      %local;
7      <!ENTITY % entities SYSTEM "entities.ent">
8      %entities;
9      <!ENTITY % idcommon SYSTEM "common/common.ent">
10      %idcommon;
11 ]>
12 <refentry id="pazpar2_conf">
13  <refentryinfo>
14   <productname>Pazpar2</productname>
15   <productnumber>&version;</productnumber>
16  </refentryinfo>
17  <refmeta>
18   <refentrytitle>Pazpar2 conf</refentrytitle>
19   <manvolnum>5</manvolnum>
20  </refmeta>
21  
22  <refnamediv>
23   <refname>pazpar2_conf</refname>
24   <refpurpose>Pazpar2 Configuration</refpurpose>
25  </refnamediv>
26  
27  <refsynopsisdiv>
28   <cmdsynopsis>
29    <command>pazpar2.conf</command>
30   </cmdsynopsis>
31  </refsynopsisdiv>
32  
33  <refsect1><title>DESCRIPTION</title>
34   <para>
35    The Pazpar2 configuration file, together with any referenced XSLT files,
36    govern Pazpar2's behavior as a client, and control the normalization and
37    extraction of data elements from incoming result records, for the
38    purposes of merging, sorting, facet analysis, and display.
39   </para>
40   
41   <para>
42    The file is specified using the option -f on the Pazpar2 command line.
43    There is not presently a way to reload the configuration file without
44    restarting Pazpar2, although this will most likely be added some time
45    in the future.
46   </para>
47  </refsect1>
48  
49  <refsect1><title>FORMAT</title>
50   <para>
51    The configuration file is XML-structured. It must be valid XML. All
52    elements specific to Pazpar2 should belong to the namespace
53    <literal>http://www.indexdata.com/pazpar2/1.0</literal> 
54    (this is assumed in the
55    following examples). The root element is named <literal>pazpar2</literal>.
56    Under the  root element are a number of elements which group categories of
57    information. The categories are described below.
58   </para>
59   
60   <refsect2 id="config-server"><title>server</title>
61    <para>
62     This section governs overall behavior of the server. The data
63     elements are described below. From Pazpar2 version 1.2 this is
64     a repeatable element.
65    </para>
66    <variablelist> <!-- level 1 -->
67     <varlistentry>
68      <term>listen</term>
69      <listitem>
70       <para>
71        Configures the webservice -- this controls how you can connect
72        to Pazpar2 from your browser or server-side code. The
73        attributes 'host' and 'port' control the binding of the
74        server. The 'host' attribute can be used to bind the server to
75        a secondary IP address of your system, enabling you to run
76        Pazpar2 on port 80 alongside a conventional web server. You
77        can override this setting on the command line using the option -h.
78       </para>
79      </listitem>
80     </varlistentry>
81     
82     <varlistentry>
83      <term>proxy</term>
84      <listitem>
85       <para>
86        If this item is given, Pazpar2 will forward all incoming HTTP
87        requests that do not contain the filename 'search.pz2' to the
88        host and port specified using the 'host' and 'port'
89        attributes. The 'myurl' attribute is required, and should provide
90        the base URL of the server. Generally, the HTTP URL for the host
91        specified in the 'listen' parameter. This functionality is
92        crucial if you wish to use
93        Pazpar2 in conjunction with browser-based code (JS, Flash,
94        applets, etc.) which operates in a security sandbox. Such code
95        can only connect to the same server from which the enclosing
96        HTML page originated. Pazpar2s proxy functionality enables you
97        to host all of the main pages (plus images, CSS, etc) of your
98        application on a conventional webserver, while efficiently
99        processing webservice requests for metasearch status, results,
100        etc.
101       </para>
102      </listitem>
103     </varlistentry>
104     
105     <varlistentry>
106      <term>relevance</term>
107      <listitem>
108       <para>
109        Specifies ICU tokenization and transformation rules
110        for tokens that are used in Pazpar2's relevance ranking.  The 'id'
111        attribute is currently not used, and the 'locale'
112        attribute must be set to one of the locale strings
113        defined in ICU. The child elements listed below can be
114        in any order, except the 'index' element which logically
115        belongs to the end of the list. The stated tokenization,
116        transformation and charmapping instructions are performed
117        in order from top to bottom. 
118       </para>
119       <variablelist> <!-- Level 2 -->
120        <varlistentry><term>casemap</term>
121         <listitem>
122          <para>
123           The attribute 'rule' defines the direction of the
124           per-character casemapping, allowed values are "l"
125           (lower), "u" (upper), "t" (title).  
126          </para>
127         </listitem>
128        </varlistentry>
129        <varlistentry><term>transform</term>
130         <listitem>
131          <para>
132           Normalization and transformation of tokens follows
133           the rules defined in the 'rule' attribute. For
134           possible values we refer to the extensive ICU
135           documentation found at the 
136           <ulink url="&url.icu.transform;">ICU
137            transformation</ulink> home page. Set filtering
138           principles are explained at the 
139           <ulink url="&url.icu.unicode.set;">ICU set and
140            filtering</ulink> page.
141          </para>
142         </listitem>
143        </varlistentry>
144        <varlistentry><term>tokenize</term>
145         <listitem>
146          <para>
147           Tokenization is the only rule in the ICU chain
148           which splits one token into multiple tokens. The
149           'rule' attribute may have the following values:
150           "s" (sentence), "l" (line-break), "w" (word), and
151           "c" (character), the later probably not being
152           very useful in a pruning Pazpar2 installation. 
153          </para>
154         </listitem>
155        </varlistentry>
156       </variablelist>
157      </listitem>
158     </varlistentry>
159
160     <varlistentry>
161      <term>sort</term>
162      <listitem>
163       <para>
164        Specifies ICU tokenization and transformation rules
165        for tokens that are used in Pazpar2's sorting. The contents
166        is similar to that of <literal>relevance</literal>.
167       </para>
168      </listitem>
169     </varlistentry>
170     
171     <varlistentry>
172      <term>mergekey</term>
173      <listitem>
174       <para>
175        Specifies ICU tokenization and transformation rules
176        for tokens that are used in Pazpar2's mergekey. The contents
177        is similar to that of <literal>relevance</literal>.
178       </para>
179      </listitem>
180     </varlistentry>
181     
182     <varlistentry>
183      <term>service</term>
184      <listitem>
185       <para>
186        This nested element controls the behavior of Pazpar2 with
187        respect to your data model. In Pazpar2, incoming records are
188        normalized, using XSLT, into an internal representation.
189        The 'service' section controls the further processing and
190        extraction of data from the internal representation, primarily
191        through the 'metadata' sub-element.
192       </para>
193       <para>
194        Pazpar2 version 1.2 and later allows multiple service elements.
195        Multiple services must be given a unique ID by specifying
196        attribute <literal>id</literal>.
197        A single service may be unnamed (service ID omitted). The
198        service ID is referred to in the
199        <link linkend="command-init"><literal>init</literal></link> webservice
200        command's <literal>service</literal> parameter.
201       </para>
202
203       <variablelist> <!-- Level 2 -->
204        <varlistentry><term>metadata</term>
205         <listitem>
206          <para>
207           One of these elements is required for every data element in
208           the internal representation of the record (see
209           <xref linkend="data_model"/>. It governs
210           subsequent processing as pertains to sorting, relevance
211           ranking, merging, and display of data elements. It supports
212           the following attributes:
213          </para>
214          
215          <variablelist> <!-- level 3 -->
216           <varlistentry><term>name</term>
217            <listitem>
218             <para>
219              This is the name of the data element. It is matched
220              against the 'type' attribute of the
221              'metadata' element 
222              in the normalized record. A warning is produced if
223              metadata elements with an unknown name are
224              found in the 
225              normalized record. This name is also used to
226              represent 
227              data elements in the records returned by the
228              webservice API, and to name sort lists and browse
229              facets.
230             </para>
231            </listitem>
232           </varlistentry>
233           
234           <varlistentry><term>type</term>
235            <listitem>
236             <para>
237              The type of data element. This value governs any
238              normalization or special processing that might take
239              place on an element. Possible values are 'generic'
240              (basic string), 'year' (a range is computed if
241              multiple years are found in the record). Note: This
242              list is likely to increase in the future.
243             </para>
244            </listitem>
245           </varlistentry>
246           
247           <varlistentry><term>brief</term>
248            <listitem>
249             <para>
250              If this is set to 'yes', then the data element is
251              includes in brief records in the webservice API. Note
252              that this only makes sense for metadata elements that
253              are merged (see below). The default value is 'no'.
254             </para>
255            </listitem>
256           </varlistentry>
257           
258           <varlistentry><term>sortkey</term>
259            <listitem>
260             <para>
261              Specifies that this data element is to be used for
262              sorting. The possible values are 'numeric' (numeric
263              value), 'skiparticle' (string; skip common, leading
264              articles), and 'no' (no sorting). The default value is
265              'no'.
266             </para>
267            </listitem>
268           </varlistentry>
269           
270           <varlistentry><term>rank</term>
271            <listitem>
272             <para>
273              Specifies that this element is to be used to
274              help rank 
275              records against the user's query (when ranking is
276              requested). The value is an integer, used as a
277              multiplier against the basic TF*IDF score. A value of
278              1 is the base, higher values give additional
279              weight to 
280              elements of this type. The default is '0', which
281              excludes this element from the rank calculation.
282             </para>
283            </listitem>
284           </varlistentry>
285           
286           <varlistentry><term>termlist</term>
287            <listitem>
288             <para>
289              Specifies that this element is to be used as a
290              termlist, or browse facet. Values are tabulated from
291              incoming records, and a highscore of values (with
292              their associated frequency) is made available to the
293              client through the webservice API. 
294              The possible values
295              are 'yes' and 'no' (default).
296             </para>
297            </listitem>
298           </varlistentry>
299           
300           <varlistentry><term>merge</term>
301            <listitem>
302             <para>
303              This governs whether, and how elements are extracted
304              from individual records and merged into cluster
305              records. The possible values are: 'unique' (include
306              all unique elements), 'longest' (include only the
307              longest element (strlen), 'range' (calculate a range
308              of values across all matching records), 'all' (include
309              all elements), or 'no' (don't merge; this is the
310                           default);
311             </para>
312            </listitem>
313           </varlistentry>
314
315           <varlistentry><term>mergekey</term>
316            <listitem>
317             <para>
318              If set to <literal>yes</literal>, the value of this
319              metadata element is appended to the resulting mergekey.
320              By default metadata is not part of a mergekey.
321             </para>
322            </listitem>
323           </varlistentry>
324
325
326           <varlistentry><term>setting</term>
327            <listitem>
328             <para>
329               This attribute allows you to make use of static database
330               settings in the processing of records. Three possible values
331               are allowed. 'no' is the default and doesn't do anything.
332               'postproc' copies the value of a setting with the same name
333               into the output of the normalization stylesheet(s). 'parameter'
334               makes the value of a setting with the same name available 
335               as a parameter to the normalization stylesheet, so you
336               can further process the value inside of the stylesheet, or use
337               the value to decide how to deal with other data values.
338             </para>
339             <para>
340             </para>
341               The purpose of using settings in this way can either be to
342               control the behavior of normalization stylesheet in a database-
343               dependent way, or to easily make database-dependent values
344               available to display-logic in your user interface, without having
345               to implement complicated interactions between the user interface
346               and your configuration system.
347            </listitem>
348           </varlistentry>
349          </variablelist> <!-- attributes to metadata -->
350          
351         </listitem>
352        </varlistentry>
353       </variablelist>     <!-- Data elements in service directive -->
354      </listitem>
355     </varlistentry>
356    </variablelist>           <!-- Data elements in server directive -->
357   </refsect2>
358
359  </refsect1>
360  
361  <refsect1><title>EXAMPLE</title>
362   <para>Below is a working example configuration:
363   <screen><![CDATA[
364 <?xml version="1.0" encoding="UTF-8"?>
365 <pazpar2 xmlns="http://www.indexdata.com/pazpar2/1.0">
366
367 <server>
368   <listen port="9004"/>
369   <proxy host="us1.indexdata.com" myurl="us1.indexdata.com"/>
370
371   <!-- optional ICU ranking configuration example -->
372   <!--
373   <icu_chain id="el:word" locale="el">
374     <normalize rule="[:Control:] Any-Remove"/>
375     <tokenize rule="l"/>
376     <normalize rule="[[:WhiteSpace:][:Punctuation:]] Remove"/>
377     <casemap rule="l"/>
378     <index/>
379   </icu_chain>
380   -->
381
382   <service>
383     <metadata name="title" brief="yes" sortkey="skiparticle" merge="longest" rank="6"/>
384     <metadata name="isbn" merge="unique"/>
385     <metadata name="date" brief="yes" sortkey="numeric" type="year" merge="range"
386             termlist="yes"/>
387     <metadata name="author" brief="yes" termlist="yes" merge="longest" rank="2"/>
388     <metadata name="subject" merge="unique" termlist="yes" rank="3"/>
389     <metadata name="url" merge="unique"/>
390   </service>
391 </server>
392
393 </pazpar2>
394 ]]></screen>
395   </para>
396  </refsect1> 
397
398  <refsect1 id="config-include"><title>INCLUDE FACILITY</title>
399   <para>
400    The XML configuration may be partitioned into multiple files by using
401    the <literal>include</literal> element which takes a single attribute,
402    <literal>src</literal>. The of the <literal>src</literal> attribute is
403    regular Shell like glob-pattern. For example,
404    <screen><![CDATA[
405     <include src="/etc/pazpar2/conf.d/*.xml"/>
406     ]]></screen>
407   </para>
408   <para>
409    The include facility requires Pazpar2 version 1.2.
410   </para>
411  </refsect1>
412
413  <refsect1 id="target_settings"><title>TARGET SETTINGS</title>
414   <para>
415    Pazpar2 features a cunning scheme by which you can associate various
416    kinds of attributes, or settings with search targets. This can be done
417    through XML files which are read at startup; each file can associate
418    one or more settings with one or more targets. The file format is generic
419    in nature, designed to support a wide range of application requirements. The
420    settings can be purely technical things, like, how to perform a title
421    search against a given target, or it can associate arbitrary name=value
422    pairs with groups of targets -- for instance, if you would like to
423    place all commercial full-text bases in one group for selection
424    purposes, or you would like to control what targets are accessible
425    to users by default. Per-database settings values can even be used
426    to drive sorting, facet/termlist generation, or end-user interface display
427    logic.
428   </para>
429   
430   <para>
431    During startup, Pazpar2 will recursively read a specified directory
432    (can be identified in the pazpar2.cfg file or on the command line), and
433    process any settings files found therein.
434   </para>
435   
436   <para>
437    Clients of the Pazpar2 webservice interface can selectively override
438    settings for individual targets within the scope of one session. This
439    can be used in conjunction with an external authentication system to
440    determine which resources are to be accessible to which users. Pazpar2
441    itself has no notion of end-users, and so can be used in conjunction
442    with any type of authentication system. Similarly, the authentication
443    tokens submitted to access-controlled search targets can similarly be
444    overridden, to allow use of Pazpar2 in a consortial or multi-library
445    environment, where different end-users may need to be represented to
446    some search targets in different ways. This, again, can be managed
447    using an external database or other lookup mechanism. Setting overrides
448    can be performed either using the
449    <link linkend="command-init">init</link> or the 
450    <link linkend="command-settings">settings</link> webservice
451    command.
452   </para>
453   
454   <para>
455    In fact, every setting that applies to a database (except pz:id, which
456    can only be used for filtering targets to use for a search) can be overridden
457    on a per-session basis. This allows the client to override specific CCL fields
458    for searching, etc., to meet the needs of a session or user.
459   </para>
460   
461   <para>
462    Finally, as an extreme case of this, the webservice client can
463    introduce entirely new targets, on the fly, as part of the
464    <link linkend="command-init">init</link> or
465    <link linkend="command-settings">settings</link> command.
466    This is useful if you desire to manage information
467    about your search targets in a separate application such as a database.
468    You do not need any static settings file whatsoever to run Pazpar2 -- as
469    long as the webservice client is prepared to supply the necessary
470    information at the beginning of every session.
471   </para>
472   
473   <note>
474    <para>
475     The following discussion of practical issues related to session and settings
476     management are cast in terms of a user interface based on Ajax/Javascript
477     technology. It would apply equally well to many other kinds of browser-based logic.
478    </para>
479   </note>
480   
481   <para>
482    Typically, a Javascript client is not allowed to  directly alter the parameters
483    of a session. There are two reasons for this. One has to do with access
484    to information; typically, information about a user will be stored in a
485    system on the server side, or it will be accessible in some way from the server.
486    However, since the Javascript client cannot be entirely trusted (some hostile
487    agent might in fact 'pretend' to be a regular ws client), it is more robust
488    to control session settings from scripting that you run as part of your
489    webserver. Typically, this can be handled during the session initialization,
490    as follows:
491   </para>
492   
493   <para>
494    Step 1: The Javascript client loads, and asks the webserver for a new Pazpar2
495    session ID. This can be done using a Javascript call, for instance. Note that
496    it is possible to submit Ajax HTTPXmlRequest calls either to Pazpar2 or to the
497    webserver that Pazpar2 is proxying for. See (XXX Insert link to Pazpar2 protocol).
498     </para>
499   
500   <para>
501    Step 2: Code on the webserver authenticates the user, by database lookup,
502    LDAP access, NCIP, etc. Determines which resources the user has access to,
503    and any user-specific parameters that are to be applied during this session.
504   </para>
505   
506   <para>
507    Step 3: The webserver initializes a new Pazpar2 settings, and sets user-specific
508    parameters as necessary, using the init webservice command. A new session ID is
509    returned.
510   </para>
511   
512   <para>
513    Step 4: The webserver returns this session ID to the Javascript client, which then
514    uses the session ID to submit searches, show results, etc.
515   </para>
516   
517   <para>
518    Step 5: When the Javascript client ceases to use the session, Pazpar2 destroys
519    any session-specific information.
520   </para>
521
522   <refsect2><title>SETTINGS FILE FORMAT</title>
523    <para>
524     Each file contains a root element named &lt;settings&gt;. It may
525     contain one or more &lt;set&gt; elements. The settings and set
526     elements may contain the following attributes. Attributes in the set node
527     overrides those in the setting root element. Each set node must
528     specify (directly, or inherited from the parent node) at least a
529     target, name, and value.
530    </para>
531    
532    <variablelist> 
533     <varlistentry>
534      <term>target</term>
535      <listitem>
536       <para>
537        This specifies the search target to which this setting should be
538        applied. Targets are identified by their Z39.50 URL, generally
539        including the host, port, and database name, (e.g.
540        <literal>bagel.indexdata.com:210/marc</literal>).
541        Two wildcard forms are accepted:
542        * (asterisk) matches all known targets;
543        <literal>bagel.indexdata.com:210/*</literal> matches all
544        known databases on the given host.
545       </para>
546       <para>
547        A precedence system determines what happens if there are
548        overlapping values for the same setting name for the same
549        target. A setting for a specific target name overrides a
550        setting which specifies target using a wildcard. This makes it
551        easy to set defaults for all targets, and then override them
552        for specific targets or hosts. If there are
553        multiple overlapping settings with the same name and target
554        value, the 'precedence' attribute determines what happens.
555       </para>
556      </listitem>
557     </varlistentry>
558     <varlistentry>
559      <term>name</term>
560      <listitem>
561       <para>
562        The name of the setting. This can be anything you like.
563        However, Pazpar2 reserves a number of setting names for
564        specific purposes, all starting with 'pz:', and it is a good
565        idea to avoid that prefix if you make up your own setting
566        names. See below for a list of reserved variables.
567       </para>
568      </listitem>
569     </varlistentry>
570     <varlistentry>
571      <term>value</term>
572      <listitem>
573       <para>
574        The value of the setting. Generally, this can be anything you
575        want -- however, some of the reserved settings may expect
576        specific kinds of values.
577       </para>
578      </listitem>
579     </varlistentry>
580     <varlistentry>
581      <term>precedence</term>
582      <listitem>
583       <para>
584        This should be an integer. If not provided, the default value
585        is 0. If two (or more) settings have the same content for
586        target and name, the precedence value determines the outcome.
587        If both settings have the same precedence value, they are both
588        applied to the target(s). If one has a higher value, then the
589        value of that setting is applied, and the other one is ignored.
590       </para>
591      </listitem>
592     </varlistentry>
593    </variablelist>
594    
595    <para>
596     By setting defaults for target, name, or value in the root
597     settings node, you can use the settings files in many different
598     ways. For instance, you can use a single file to set defaults for
599     many different settings, like search fields, retrieval syntaxes,
600     etc. You can have one file per server, which groups settings for
601     that server or target. You could also have one file which associates
602     a number of targets with a given setting, for instance, to associate
603     many databases with a given category or class that makes sense
604     within your application.
605    </para>
606    
607    <para>
608     The following examples illustrate uses of the settings system to
609     associate settings with targets to meet different requirements.
610    </para>
611    
612    <para>
613     The example below associates a set of default values that can be
614     used across many targets. Note the wildcard for targets.
615     This associates the given settings with all targets for which no
616     other information is provided.
617     <screen><![CDATA[
618 <settings target="*">
619
620   <!-- This file introduces default settings for pazpar2 -->
621
622   <!-- mapping for unqualified search -->
623   <set name="pz:cclmap:term" value="u=1016 t=l,r s=al"/>
624
625   <!-- field-specific mappings -->
626   <set name="pz:cclmap:ti" value="u=4 s=al"/>
627   <set name="pz:cclmap:su" value="u=21 s=al"/>
628   <set name="pz:cclmap:isbn" value="u=7"/>
629   <set name="pz:cclmap:issn" value="u=8"/>
630   <set name="pz:cclmap:date" value="u=30 r=r"/>
631
632   <!-- Retrieval settings -->
633
634   <set name="pz:requestsyntax" value="marc21"/>
635   <set name="pz:elements" value="F"/>
636
637   <!-- Query encoding -->
638   <set name="pz:queryencoding" value="iso-8859-1"/>
639
640   <!-- Result normalization settings -->
641
642   <set name="pz:nativesyntax" value="iso2709"/>
643   <set name="pz:xslt" value="../etc/marc21.xsl"/>
644
645 </settings>
646
647         ]]></screen>
648    </para>
649    
650    <para>
651     The next example shows certain settings overridden for one target,
652     one which returns XML records containing DublinCore elements, and
653     which furthermore requires a username/password.
654     <screen><![CDATA[
655 <settings target="funkytarget.com:210/db1">
656   <set name="pz:requestsyntax" value="xml"/>
657   <set name="pz:nativesyntax" value="xml"/>
658   <set name="pz:xslt" value="../etc/dublincore.xsl"/>
659
660   <set name="pz:authentication" value="myuser/password"/>
661 </settings>
662         ]]></screen>
663    </para>
664    
665    <para>
666     The following example associates a specific name/value combination
667     with a number of targets. The targets below are access-restricted,
668     and can only be used by users with special credentials.
669     <screen><![CDATA[
670 <settings name="pz:allow" value="0">
671   <set target="funkytarget.com:210/*"/>
672   <set target="commercial.com:2100/expensiveDb"/>
673 </settings>
674         ]]></screen>
675    </para>
676    
677   </refsect2>
678   
679   <refsect2><title>RESERVED SETTING NAMES</title>
680    <para>
681     The following setting names are reserved by Pazpar2 to control the
682     behavior of the client function.
683    </para>
684    
685    <variablelist>
686     <varlistentry>
687      <term>pz:cclmap:xxx</term>
688      <listitem>
689       <para>
690        This establishes a CCL field definition or other setting, for
691        the purpose of mapping end-user queries. XXX is the field or
692        setting name, and the value of the setting provides parameters
693        (e.g. parameters to send to the server, etc.). Please consult
694        the YAZ manual for a full overview of the many capabilities of
695        the powerful and flexible CCL parser.
696       </para>
697       <para>
698        Note that it is easy to establish a set of default parameters,
699        and then override them individually for a given target.
700       </para>
701      </listitem>
702     </varlistentry>
703     <varlistentry>
704      <term>pz:requestsyntax</term>
705      <listitem>
706       <para>
707        This specifies the record syntax to use when requesting
708        records from a given server. The value can be a symbolic name like
709        marc21 or xml, or it can be a Z39.50-style dot-separated OID.
710       </para>
711      </listitem>
712     </varlistentry>
713     <varlistentry>
714      <term>pz:elements</term>
715      <listitem>
716       <para>
717        The element set name to be used when retrieving records from a
718        server.
719       </para>
720      </listitem>
721     </varlistentry>
722     <varlistentry>
723      <term>pz:piggyback</term>
724      <listitem>
725       <para>
726        Piggybacking enables the server to retrieve records from the
727        server as part of the search response in Z39.50. Almost all
728        servers support this (or fail it gracefully), but a few
729        servers will produce undesirable results.
730        Set to '1' to enable piggybacking, '0' to disable it. Default
731        is 1 (piggybacking enabled).
732       </para>
733      </listitem>
734     </varlistentry>
735     <varlistentry>
736      <term>pz:nativesyntax</term>
737      <listitem>
738       <para>
739        The representation (syntax) of the retrieval records. Currently
740        recognized values are iso2709 and xml.
741       </para>
742       <para>
743        For iso2709, can also specify a native character set, e.g. "iso2709;latin-1".
744        If no character set is provided, MARC-8 is assumed.
745       </para>
746       <para>
747         If pz:nativesyntax is not specified, pazpar2 will attempt to determine
748         the value based on the response from the server.
749       </para>
750      </listitem>
751     </varlistentry>
752
753     <varlistentry>
754      <term>pz:queryencoding</term>
755      <listitem>
756       <para>
757         The encoding of the search terms that a target accepts. Most
758         targets do not honor UTF-8 in which case this needs to be specified.
759         Each term in a query will be converted if this setting is given.
760       </para>
761      </listitem>
762     </varlistentry>
763
764     <varlistentry>
765      <term>pz:xslt</term>
766      <listitem>
767       <para>
768        Provides the path of an XSLT stylesheet which will be used to
769        map incoming records to the internal representation.
770       </para>
771      </listitem>
772     </varlistentry>
773     <varlistentry>
774      <term>pz:authentication</term>
775      <listitem>
776       <para>
777        Sets an authentication string for a given server. See the section on
778        authorization and authentication for discussion.
779       </para>
780      </listitem>
781     </varlistentry>
782     <varlistentry>
783      <term>pz:allow</term>
784      <listitem>
785       <para>
786        Allows or denies access to the resources it is applied to. Possible
787        values are '0' and '1'. The default is '1' (allow access to this resource).
788        See the manual section on authorization and authentication for discussion
789        about how to use this setting.
790       </para>
791      </listitem>
792     </varlistentry>
793     <varlistentry>
794      <term>pz:maxrecs</term>
795      <listitem>
796       <para>
797        Controls the maximum number of records to be retrieved from a
798        server. The default is 100.
799       </para>
800      </listitem>
801     </varlistentry>
802     <varlistentry>
803      <term>pz:id</term>
804      <listitem>
805       <para>
806        This setting can't be 'set' -- it contains the ID (normally
807        ZURL) for a given target, and is useful for filtering --
808        specifically when you want to select one or more specific
809        targets in the search command.
810       </para>
811      </listitem>
812     </varlistentry>
813     <varlistentry>
814      <term>pz:zproxy</term>
815      <listitem>
816       <para>
817        The 'pz:zproxy' setting has the value syntax 
818        'host.internet.adress:port', it is used to tunnel Z39.50
819        requests through the named Z39.50 proxy.
820       </para>
821      </listitem>
822     </varlistentry>
823
824     <varlistentry>
825      <term>pz:apdulog</term>
826      <listitem>
827       <para>
828        If the 'pz:apdulog' setting is defined and has other value than 0,
829        then Z39.50 APDUs are written to the log.
830       </para>
831      </listitem>
832     </varlistentry>
833
834     <varlistentry>
835       <term>pz:sru</term>
836       <listitem>
837         <para>
838           This setting enables SRU/SRW support. It has three possible settings.
839           'get', enables SRU access through GET requests. 'post' enables SRU/POST
840           support, less commonly supported, but useful if very large requests are
841           to be submitted. 'srw' enables the SRW variation of the protocol.
842         </para>
843       </listitem>
844     </varlistentry>
845
846     <varlistentry>
847       <term>pz:sru_version</term>
848       <listitem>
849         <para>
850           This allows SRU version to be specified. If unset Pazpar2
851           will the default of YAZ (currently 1.2). Should be set
852           to 1.1 or 1.2.
853         </para>
854       </listitem>
855     </varlistentry>
856
857     <varlistentry>
858       <term>pz:pqf_prefix</term>
859       <listitem>
860         <para>
861           Allows you to specify an arbitrary PQF query language substring. The provided
862           string is prefixed the user's query after it has been normalized to PQF
863           internally in pazpar2. This allows you to attach complex 'filters' to
864           queries for a gien target, sometimes necessary to select sub-catalogs
865           in union catalog systems, etc.
866         </para>
867       </listitem>
868     </varlistentry>
869
870     <varlistentry>
871       <term>pz:sort</term>
872       <listitem>
873         <para>
874           Specifies sort criteria to be applied to the result set. Only works for targets
875           which support the sort service.
876         </para>
877       </listitem>
878     </varlistentry>
879    </variablelist>
880   </refsect2>
881
882  </refsect1>
883  <refsect1><title>SEE ALSO</title>
884   <para>
885    <citerefentry>
886     <refentrytitle>pazpar2</refentrytitle>
887     <manvolnum>8</manvolnum>
888    </citerefentry>
889    <citerefentry>
890     <refentrytitle>yaz-icu</refentrytitle>
891     <manvolnum>1</manvolnum>
892    </citerefentry>
893    <citerefentry>
894     <refentrytitle>pazpar2_protocol</refentrytitle>
895     <manvolnum>7</manvolnum>
896    </citerefentry>
897   </para>
898  </refsect1>
899 </refentry>
900 <!-- Keep this comment at the end of the file
901 Local variables:
902 mode: sgml
903 sgml-omittag:t
904 sgml-shorttag:t
905 sgml-minimize-attributes:nil
906 sgml-always-quote-attributes:t
907 sgml-indent-step:1
908 sgml-indent-data:t
909 sgml-parent-document:nil
910 sgml-local-catalogs: nil
911 sgml-namecase-general:t
912 End:
913 -->