1 <!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook V4.1//EN"
2 "http://www.oasis-open.org/docbook/xml/4.1/docbookx.dtd" [
3 <!ENTITY copyright SYSTEM "copyright.xml">
4 <!ENTITY % idcommon SYSTEM "common/common.ent">
7 <refentry id="ref-virt_db">
9 <refentrytitle>virt_db</refentrytitle>
10 <manvolnum>3mp</manvolnum>
11 <refmiscinfo>Metaproxy Module</refmiscinfo>
15 <refname>virt_db</refname>
16 <refpurpose>Metaproxy Virtual Databases Module</refpurpose>
19 <refsect1><title>DESCRIPTION</title>
21 This filter allows one Z39.50 database to be me mapped to
22 another target; or even multiple targets.
25 The configuration of virt_db consists of zero or more
26 <literal><virtual></literal> elements each describing the
27 Z39.50 virtual database recognized.
28 The name of the database is the text content of the
29 <literal><database></literal> element which should be
30 first element inside the virtual section.
33 For Metaproxy 1.0.20 and later, the database is treated as a glob pattern.
34 This allows operators * (any number of any character) and
35 ? (any single character). The virtual sections are inspected in
36 the order given. The first matching virtual database is used.
39 Following that is one or more <literal><target></literal>
40 elements with the identifier of each target that the virtual database
41 maps to. If a database is given for a target (following a slash), that
42 database name is used as Z39.50 database for this target. If the
43 database is omitted for the target, the original (virtual) database
44 is used as Z39.50 database.
47 If multiple targets are given that has special meaning depending on the
48 filter following virt_db. If the following filter is load_balance, then
49 the load_balance filter will load balance between the targets given
50 (assuming they serve same content). If the following filter is multi,
51 then results will be merged from all targets instead.
54 The z3950_filter, on the other hand, does not support multiple targets.
57 For <literal><virtual></literal> a route may be given as
58 an attribute. This will make Metaproxy route traffic to the route
59 given. Note that virtual databases may not be combined if all
60 databases do not result in the same routing.
64 <refsect1><title>EXAMPLES</title>
66 Consider this virt_db configuration:
68 <filter type="virt_db">
70 <database>db1</database>
71 <target>localhost:9999/Default</target>
74 <database>db2</database>
75 <target>indexdata.com/gils</target>
78 <database>combined</database>
79 <target>indexdata.com/gils</target>
80 <target>localhost:9999/Default</target>
82 <virtual route="special">
83 <database>db3</database>
84 <target>indexdata.com/special</target>
87 <database>*</database><!-- default -->
88 <target>localhost:9999</target><-- database not altered -->
93 This will offer 4 databases, <literal>db1</literal>,
94 <literal>db2</literal>, <literal>combined</literal> and
95 <literal>db3</literal>. If a Z39.50 specifies <literal>db1</literal>
96 and <literal>db2</literal> that will have same effect as specifying
97 the single database <literal>combined</literal>.
100 Since <literal>db3</literal> routes differently from the other databases,
101 this database may not be combined with the others.
105 <refsect1><title>SEE ALSO</title>
108 <refentrytitle>metaproxy</refentrytitle>
109 <manvolnum>1</manvolnum>
114 <refentrytitle>multi</refentrytitle>
115 <manvolnum>3mp</manvolnum>
118 <refentrytitle>load_balance</refentrytitle>
119 <manvolnum>3mp</manvolnum>
127 <!-- Keep this comment at the end of the file
132 sgml-minimize-attributes:nil
133 sgml-always-quote-attributes:t
136 sgml-parent-document:nil
137 sgml-local-catalogs: nil
138 sgml-namecase-general:t