5 <opensrf version="0.0.3">
8 There is one <host> entry for each server on the network. Settings for the
9 'default' host are used for every setting that isn't overridden within a given
12 To specify which applications a host is serving, list those applications
13 within that host's config section. If the defaults are acceptible, then
14 that's all that needs to be added/changed.
16 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>LOCALSTATEDIR/log</log>
27 <!-- opensrf unix domaind socket files go here -->
28 <sock>LOCALSTATEDIR/lock</sock>
30 <!-- opensrf pids go here -->
31 <pid>LOCALSTATEDIR/run</pid>
33 <!-- global config directory -->
34 <conf>SYSCONFDIR</conf>
37 <!-- prefork, simple. prefork is suggested -->
38 <server_type>prefork</server_type>
40 <!-- Default doesn't host any apps -->
46 <!-- memcached server ip:port -->
47 <server>127.0.0.1:11211</server>
51 <!-- maximum time that anything may stay in the cache -->
52 <max_cache_time>86400</max_cache_time>
58 These are the defaults for every served app. Each server should
59 duplicate the node layout for any nodes that need changing.
60 Any settings that are overridden in the server specific section
61 will be used as the config values for that server. Any settings that are
62 not overridden will fall back on the defaults
63 Note that overriding 'stateless' will break things
70 How many seconds to wait between server
71 requests before timing out a stateful server session.
73 <keepalive>1</keepalive>
76 if 1, then we support stateless sessions (no connect required),
79 <stateless>1</stateless>
82 Tells the servers which language this implementation is coded in
83 In this case non "perl" servers will not be able to load the module
85 <language>perl</language>
87 <!-- Module the implements this application -->
88 <implementation>OpenSRF::Application::Persist</implementation>
90 <!-- max stateful requests before a session automatically disconnects a client -->
91 <max_requests>97</max_requests>
93 <!-- settings for the backend application drones. These are probably sane defaults -->
96 <!-- unix socket file -->
97 <unix_sock>opensrf.persist_unix.sock</unix_sock>
100 <unix_pid>opensrf.persist_unix.pid</unix_pid>
102 <!-- max requests per process backend before a child is recycled -->
103 <max_requests>1000</max_requests>
105 <!-- log file for this application -->
106 <unix_log>opensrf.persist_unix.log</unix_log>
108 <!-- Number of children to pre-fork -->
109 <min_children>5</min_children>
111 <!-- maximun number of children to fork -->
112 <max_children>25</max_children>
114 <!-- minimun number of spare forked children -->
115 <min_spare_children>2</min_spare_children>
117 <!-- max number of spare forked children -->
118 <max_spare_children>5</max_spare_children>
122 <!-- Any additional setting for a particular application go in the app_settings node -->
125 <!-- sqlite database file -->
126 <dbfile>LOCALSTATEDIR/persist.db</dbfile>
132 <keepalive>3</keepalive>
133 <stateless>1</stateless>
134 <language>c</language>
135 <implementation>osrf_math.so</implementation>
136 <max_requests>97</max_requests>
138 <unix_sock>opensrf.math_unix.sock</unix_sock>
139 <unix_pid>opensrf.math_unix.pid</unix_pid>
140 <max_requests>1000</max_requests>
141 <unix_log>opensrf.math_unix.log</unix_log>
142 <min_children>5</min_children>
143 <max_children>15</max_children>
144 <min_spare_children>2</min_spare_children>
145 <max_spare_children>5</max_spare_children>
150 <keepalive>3</keepalive>
151 <stateless>1</stateless>
152 <language>c</language>
153 <implementation>osrf_dbmath.so</implementation>
154 <max_requests>99</max_requests>
156 <max_requests>1000</max_requests>
157 <unix_log>opensrf.dbmath_unix.log</unix_log>
158 <unix_sock>opensrf.dbmath_unix.sock</unix_sock>
159 <unix_pid>opensrf.dbmath_unix.pid</unix_pid>
160 <min_children>5</min_children>
161 <max_children>15</max_children>
162 <min_spare_children>2</min_spare_children>
163 <max_spare_children>5</max_spare_children>
168 <keepalive>1</keepalive>
169 <stateless>1</stateless>
170 <language>perl</language>
171 <implementation>OpenSRF::Application::Settings</implementation>
172 <max_requests>17</max_requests>
174 <unix_sock>opensrf.settings_unix.sock</unix_sock>
175 <unix_pid>opensrf.settings_unix.pid</unix_pid>
176 <max_requests>1000</max_requests>
177 <unix_log>opensrf.settings_unix.log</unix_log>
178 <min_children>5</min_children>
179 <max_children>15</max_children>
180 <min_spare_children>3</min_spare_children>
181 <max_spare_children>5</max_spare_children>
191 Should match the fully qualified domain name of the host.
193 On Linux, the output of the following command is authoritative:
194 $ perl -MNet::Domain -e 'print Net::Domain::hostfqdn();'
196 To use 'localhost' instead, run osrf_ctl.sh with the -l flag
198 <!-- List all of the apps this server will be running -->
200 <appname>opensrf.persist</appname>
201 <appname>opensrf.settings</appname>
202 <appname>opensrf.math</appname>
203 <appname>opensrf.dbmath</appname>
208 <!-- Example of an app-specific setting override -->
211 <dbfile>LOCALSTATEDIR/persist-override.db</dbfile>