3 <opensrf version='0.0.1'>
7 There is one <host> entry for each server on the network. Settings for the
8 'default' host are used for every setting that isn't overridden within a given
11 To specify which applications a host is serving, list those applications
12 within that host's config section. If the defaults are acceptible, then
13 that's all that needs to be added/changed.
15 Any valid XML may be added to the <default> block and server components will have
24 <!-- opensrf log files go in this directory -->
25 <log>/path/to/log</log>
27 <!-- opensrf unix domaind socket files go here -->
28 <sock>/path/to/sock</sock>
30 <!-- opensrf pids go here -->
31 <pid>/path/to/pid</pid>
33 <!-- global config directory -->
34 <conf>/path/to/conf</conf>
38 <!-- prefork, simple. prefork is suggested -->
39 <server_type>prefork</server_type>
41 <!-- Default doesn't host any apps -->
47 <!-- memcached server ip:port -->
48 <server>127.0.0.1:10101</server>
50 <!-- maximun time that anything may stay in the cache -->
51 <max_cache_time>86400</max_cache_time>
55 <!-- These are the defaults for every served app. Each server should
56 duplicate the node layout for any nodes that need changing.
57 Any settings that are overridden in the server specific section
58 will be used as the config values for that server. Any settings that are
59 not overridden will fall back on the defaults
60 Note that overriding 'stateless' will break things -->
66 <!-- How many seconds to wait between server
67 requests before timing out a stateful server session. -->
68 <keepalive>1</keepalive>
70 <!-- if 1, then we support stateless sessions (no connect required), if
72 <stateless>1</stateless>
74 <!-- Tells the servers which language this implementation is coded in
75 In this case non "perl" servers will not be able to load the module -->
76 <language>perl</language>
78 <!-- Module the implements this application -->
79 <implementation>OpenSRF::Application::Persist</implementation>
81 <!-- max stateful requests before a session automatically disconnects a client -->
82 <max_requests>97</max_requests>
84 <!-- settings for the backend application drones. These are probably sane defaults -->
87 <!-- unix socket file -->
88 <unix_sock>opensrf.persist_unix.sock</unix_sock>
91 <unix_pid>opensrf.persist_unix.pid</unix_pid>
93 <!-- max requests per process backend before a child is recycled -->
94 <max_requests>1000</max_requests>
96 <!-- log file for this application -->
97 <unix_log>opensrf.persist_unix.log</unix_log>
99 <!-- Number of children to pre-fork -->
100 <min_children>5</min_children>
102 <!-- maximun number of children to fork -->
103 <max_children>25</max_children>
105 <!-- minimun number of spare forked children -->
106 <min_spare_children>2</min_spare_children>
108 <!-- max number of spare forked children -->
109 <max_spare_children>5</max_spare_children>
113 <!-- Any additional setting for a particular application go in the app_settings node -->
116 <!-- sqlite database file -->
117 <dbfile>/path/to/dbfile/persist.db</dbfile>
123 <keepalive>3</keepalive>
124 <stateless>1</stateless>
125 <language>perl</language>
126 <implementation>OpenSRF::Application::Demo::Math</implementation>
127 <max_requests>97</max_requests>
129 <unix_sock>opensrf.math_unix.sock</unix_sock>
130 <unix_pid>opensrf.math_unix.pid</unix_pid>
131 <max_requests>1000</max_requests>
132 <unix_log>opensrf.math_unix.log</unix_log>
133 <min_children>5</min_children>
134 <max_children>15</max_children>
135 <min_spare_children>2</min_spare_children>
136 <max_spare_children>5</max_spare_children>
141 <keepalive>3</keepalive>
142 <stateless>1</stateless>
143 <language>perl</language>
144 <implementation>OpenSRF::Application::Demo::MathDB</implementation>
145 <max_requests>99</max_requests>
147 <max_requests>1000</max_requests>
148 <unix_log>opensrf.dbmath_unix.log</unix_log>
149 <unix_sock>opensrf.dbmath_unix.sock</unix_sock>
150 <unix_pid>opensrf.dbmath_unix.pid</unix_pid>
151 <min_children>5</min_children>
152 <max_children>15</max_children>
153 <min_spare_children>2</min_spare_children> <max_spare_children>5</max_spare_children>
158 <keepalive>1</keepalive>
159 <stateless>0</stateless>
160 <language>perl</language>
161 <implementation>OpenSRF::Application::Settings</implementation>
162 <max_requests>17</max_requests>
164 <unix_sock>opensrf.settings_unix.sock</unix_sock>
165 <unix_pid>opoensrf.settings_unix.pid</unix_pid>
166 <max_requests>1000</max_requests>
167 <unix_log>opensrf.settings_unix.log</unix_log>
168 <min_children>5</min_children>
169 <max_children>15</max_children>
170 <min_spare_children>3</min_spare_children>
171 <max_spare_children>5</max_spare_children>
181 <myhost.mydomain.org>
183 must match the fully qualified domain name of the host
184 on Linux, this is usually the output of "hostname -f"
188 <!-- List all of the apps this server will be running -->
190 <appname>opensrf.persist</appname>
191 <appname>opensrf.settings</appname>
192 <appname>opensrf.math</appname>
193 <appname>opensrf.dbmath</appname>
196 <apps> <!-- Example of an app-specific setting override -->
199 <dbfile>/different/path/to/dbfile/persist.db</dbfile>
204 </myhost.mydomain.org>