[Opensrf-commits] r986 - trunk/examples

svn at svn.open-ils.org svn at svn.open-ils.org
Fri Jun 29 11:40:06 EDT 2007


Author: miker
Date: 2007-06-29 11:36:58 -0400 (Fri, 29 Jun 2007)
New Revision: 986

Removed:
   trunk/examples/bootstrap.conf.example
Modified:
   trunk/examples/opensrf.xml.example
   trunk/examples/opensrf_core.xml.example
   trunk/examples/srfsh.xml.example
Log:
cleaning up XML indentation via xmllint; removing bootstrap.conf, which is no longer needed (yay Dan!)

Deleted: trunk/examples/bootstrap.conf.example
===================================================================
--- trunk/examples/bootstrap.conf.example	2007-06-29 14:07:01 UTC (rev 985)
+++ trunk/examples/bootstrap.conf.example	2007-06-29 15:36:58 UTC (rev 986)
@@ -1,44 +0,0 @@
-# ----------------------------------------------------------
-# bootstrap config file
-# ----------------------------------------------------------
-[bootstrap]
-
-# location of the opensrf.xml config file
-settings_config	= /path/to/opensrf.xml
-
-# log files directory
-log_dir				= /path/to/log
-
-## Log file is either a file name or syslog:<facility> 
-#logfile				= osrfysys.log
-logfile				= syslog:local0
-
-# defines the syslog facility for the activity log
-#actlog				= activity.log
-actlog				= syslog:local1
-
-# log level
-debug					= ERROR
-#debug				= INFO
-#debug				= DEBUG
-#debug				= INTERNAL
-
-# the jabber login of the router (changing this will likely cause problems)
-router_name			= router
-
-# all jabber domains we want our app to connect to
-list:domains		= router1.domain.com, router2.domain.com
-
-# jabber login
-username				= jabber_username
-
-# jabber password
-passwd				= jabber_password
-
-# if port is non-numeric (e.g. /tmp/mysock.sock) then we will attempt to
-# connect to the specified string as a unix socket file 
-# This works with Chop Chop jabber only (opensrf custom jabber server)
-port					= 5222
-
-# --------------------------------------
-

Modified: trunk/examples/opensrf.xml.example
===================================================================
--- trunk/examples/opensrf.xml.example	2007-06-29 14:07:01 UTC (rev 985)
+++ trunk/examples/opensrf.xml.example	2007-06-29 15:36:58 UTC (rev 986)
@@ -1,208 +1,207 @@
-<?xml version='1.0'?>
+<?xml version="1.0"?>
+<opensrf version="0.0.1">
+<!-- 
 
-<opensrf version='0.0.1'>
+	There is one <host> entry for each server on the network.  Settings for the
+	'default' host are used for every setting that isn't overridden within a given 
+	host's config.  
 
-		<!-- 
+	To specify which applications a host is serving, list those applications
+	within that host's config section.  If the defaults are acceptible, then
+	that's all that needs to be added/changed.
 
-		There is one <host> entry for each server on the network.  Settings for the
-		'default' host are used for every setting that isn't overridden within a given 
-		host's config.  
+	Any valid XML may be added to the <default> block and server components will have 
+	acces to it.
 
-		To specify which applications a host is serving, list those applications
-		within that host's config section.  If the defaults are acceptible, then
-		that's all that needs to be added/changed.
+-->
 
-		Any valid XML may be added to the <default> block and server components will have 
-		acces to it.
+  <default>
+    <dirs>
 
-		-->
+      <!-- opensrf log files go in this directory -->
+      <log>/path/to/log</log>
 
-	<default>
-	
-		<dirs>
+      <!-- opensrf unix domaind socket files go here -->
+      <sock>/path/to/sock</sock>
 
-			<!-- opensrf log files go in this directory -->
-			<log>/path/to/log</log>
+      <!-- opensrf pids go here -->
+      <pid>/path/to/pid</pid>
 
-			<!-- opensrf unix domaind socket files go here -->
-			<sock>/path/to/sock</sock>
+      <!-- global config directory -->
+      <conf>/path/to/conf</conf>
+    </dirs>
 
-			<!-- opensrf pids go here -->
-			<pid>/path/to/pid</pid>
+    <!-- prefork, simple. prefork is suggested -->
+    <server_type>prefork</server_type>
 
-			<!-- global config directory -->
-			<conf>/path/to/conf</conf>
+    <!-- Default doesn't host any apps -->
+    <activeapps/>
+    <cache>
+      <global>
+        <servers>
 
-		</dirs>
+          <!-- memcached server ip:port -->
+          <server>127.0.0.1:10101</server>
 
-		<!-- prefork, simple. prefork is suggested -->
-		<server_type>prefork</server_type>
+        </servers>
 
-		<!-- Default doesn't host any apps -->
-		<activeapps/> 
+        <!-- maximun time that anything may stay in the cache -->
+        <max_cache_time>86400</max_cache_time>
 
-		<cache>
-			<global>
-				<servers>
-					<!-- memcached server ip:port -->
-					<server>127.0.0.1:10101</server>
-				</servers>
-				<!-- maximun time that anything may stay in the cache -->
-				<max_cache_time>86400</max_cache_time>
-			</global>
-		</cache>
+      </global>
+    </cache>
 
-		<!-- These are the defaults for every served app.  Each server should 
-			duplicate the node layout for any nodes that need changing.
-			Any settings that are overridden in the server specific section 
-			will be used as the config values for that server.  Any settings that are
-			not overridden will fall back on the defaults
-			Note that overriding 'stateless' will break things -->
+<!-- These are the defaults for every served app.  Each server should 
+	duplicate the node layout for any nodes that need changing.
+	Any settings that are overridden in the server specific section 
+	will be used as the config values for that server.  Any settings that are
+	not overridden will fall back on the defaults
+	Note that overriding 'stateless' will break things -->
 
-		<apps>
+    <apps>
+      <opensrf.persist>
 
-			<opensrf.persist>
+        <!-- How many seconds to wait between server 
+	requests before timing out a stateful server session. -->
+        <keepalive>1</keepalive>
 
-				<!-- How many seconds to wait between server 
-					requests before timing out a stateful server session. -->
-				<keepalive>1</keepalive>
+        <!-- if 1, then we support stateless sessions (no connect required),
+	if 0 then we don't -->
+        <stateless>1</stateless>
 
-				<!-- if 1, then we support stateless sessions (no connect required), if
-						0 then we don't -->
-				<stateless>1</stateless>
+        <!-- Tells the servers which language this implementation is coded in 
+	In this case non "perl" servers will not be able to load the module -->
+        <language>perl</language>
 
-				<!-- Tells the servers which language this implementation is coded in 
-					In this case non "perl" servers will not be able to load the module -->
-				<language>perl</language>
+        <!-- Module the implements this application -->
+        <implementation>OpenSRF::Application::Persist</implementation>
 
-				<!-- Module the implements this application -->
-				<implementation>OpenSRF::Application::Persist</implementation>
+        <!-- max stateful requests before a session automatically disconnects a client -->
+        <max_requests>97</max_requests>
 
-				<!-- max stateful requests before a session automatically disconnects a client -->
-				<max_requests>97</max_requests>
+        <!-- settings for the backend application drones.  These are probably sane defaults -->
+        <unix_config>
 
-				<!-- settings for the backend application drones.  These are probably sane defaults -->
+          <!-- unix socket file -->
+          <unix_sock>opensrf.persist_unix.sock</unix_sock>
 
-				<unix_config>
-					<!-- unix socket file -->
-					<unix_sock>opensrf.persist_unix.sock</unix_sock>
+          <!-- pid file -->
+          <unix_pid>opensrf.persist_unix.pid</unix_pid>
 
-					<!-- pid file -->
-					<unix_pid>opensrf.persist_unix.pid</unix_pid>
+          <!-- max requests per process backend before a child is recycled -->
+          <max_requests>1000</max_requests>
 
-					<!-- max requests per process backend before a child is recycled -->
-					<max_requests>1000</max_requests>
+          <!-- log file for this application -->
+          <unix_log>opensrf.persist_unix.log</unix_log>
 
-					<!-- log file for this application -->
-					<unix_log>opensrf.persist_unix.log</unix_log>
+          <!-- Number of children to pre-fork -->
+          <min_children>5</min_children>
 
-					<!-- Number of children to pre-fork -->
-					<min_children>5</min_children>
+          <!-- maximun number of children to fork -->
+          <max_children>25</max_children>
 
-					<!-- maximun number of children to fork -->
-					<max_children>25</max_children>
+          <!-- minimun number of spare forked children -->
+          <min_spare_children>2</min_spare_children>
 
-					<!-- minimun number of spare forked children -->
-					<min_spare_children>2</min_spare_children>
+          <!-- max number of spare forked children -->
+          <max_spare_children>5</max_spare_children>
 
-					<!-- max number of spare forked children -->
-					<max_spare_children>5</max_spare_children>
+        </unix_config>
 
-				</unix_config>
+        <!-- Any additional setting for a particular application go in the app_settings node -->
+        <app_settings>
 
-				<!-- Any additional setting for a particular application go in the app_settings node -->
-				<app_settings>
+          <!-- sqlite database file -->
+          <dbfile>/path/to/dbfile/persist.db</dbfile>
 
-					<!-- sqlite database file -->
-					<dbfile>/path/to/dbfile/persist.db</dbfile>
-				</app_settings>
+        </app_settings>
+      </opensrf.persist>
 
-			</opensrf.persist>
+      <opensrf.math>
+        <keepalive>3</keepalive>
+        <stateless>1</stateless>
+        <language>perl</language>
+        <implementation>OpenSRF::Application::Demo::Math</implementation>
+        <max_requests>97</max_requests>
+        <unix_config>
+          <unix_sock>opensrf.math_unix.sock</unix_sock>
+          <unix_pid>opensrf.math_unix.pid</unix_pid>
+          <max_requests>1000</max_requests>
+          <unix_log>opensrf.math_unix.log</unix_log>
+          <min_children>5</min_children>
+          <max_children>15</max_children>
+          <min_spare_children>2</min_spare_children>
+          <max_spare_children>5</max_spare_children>
+        </unix_config>
+      </opensrf.math>
 
-			<opensrf.math>
-				<keepalive>3</keepalive>
-				<stateless>1</stateless>
-				<language>perl</language>
-				<implementation>OpenSRF::Application::Demo::Math</implementation>
-				<max_requests>97</max_requests>
-				<unix_config>
-					<unix_sock>opensrf.math_unix.sock</unix_sock>
-					<unix_pid>opensrf.math_unix.pid</unix_pid>
-					<max_requests>1000</max_requests>
-					<unix_log>opensrf.math_unix.log</unix_log>
-					<min_children>5</min_children>
-					<max_children>15</max_children>
-					<min_spare_children>2</min_spare_children>
-					<max_spare_children>5</max_spare_children>
-				</unix_config>
-			</opensrf.math>
-			
-			<opensrf.dbmath> 
-				<keepalive>3</keepalive>
-				<stateless>1</stateless>
-				<language>perl</language>
-				<implementation>OpenSRF::Application::Demo::MathDB</implementation>
-				<max_requests>99</max_requests>
-				<unix_config>
-					<max_requests>1000</max_requests>
-					<unix_log>opensrf.dbmath_unix.log</unix_log>
-					<unix_sock>opensrf.dbmath_unix.sock</unix_sock>
-					<unix_pid>opensrf.dbmath_unix.pid</unix_pid>
-					<min_children>5</min_children>
-					<max_children>15</max_children>
-					<min_spare_children>2</min_spare_children> <max_spare_children>5</max_spare_children>
-				</unix_config>
-			</opensrf.dbmath>
+      <opensrf.dbmath>
+        <keepalive>3</keepalive>
+        <stateless>1</stateless>
+        <language>perl</language>
+        <implementation>OpenSRF::Application::Demo::MathDB</implementation>
+        <max_requests>99</max_requests>
+        <unix_config>
+          <max_requests>1000</max_requests>
+          <unix_log>opensrf.dbmath_unix.log</unix_log>
+          <unix_sock>opensrf.dbmath_unix.sock</unix_sock>
+          <unix_pid>opensrf.dbmath_unix.pid</unix_pid>
+          <min_children>5</min_children>
+          <max_children>15</max_children>
+          <min_spare_children>2</min_spare_children>
+          <max_spare_children>5</max_spare_children>
+        </unix_config>
+      </opensrf.dbmath>
 
-			<opensrf.settings>
-				<keepalive>1</keepalive>
-				<stateless>0</stateless>
-				<language>perl</language>
-				<implementation>OpenSRF::Application::Settings</implementation>
-				<max_requests>17</max_requests>
-				<unix_config>
-					<unix_sock>opensrf.settings_unix.sock</unix_sock>
-					<unix_pid>opoensrf.settings_unix.pid</unix_pid>
-					<max_requests>1000</max_requests>
-					<unix_log>opensrf.settings_unix.log</unix_log>
-					<min_children>5</min_children>
-					<max_children>15</max_children>
-					<min_spare_children>3</min_spare_children>
-					<max_spare_children>5</max_spare_children>
-				</unix_config>
-			</opensrf.settings>
+      <opensrf.settings>
+        <keepalive>1</keepalive>
+        <stateless>0</stateless>
+        <language>perl</language>
+        <implementation>OpenSRF::Application::Settings</implementation>
+        <max_requests>17</max_requests>
+        <unix_config>
+          <unix_sock>opensrf.settings_unix.sock</unix_sock>
+          <unix_pid>opoensrf.settings_unix.pid</unix_pid>
+          <max_requests>1000</max_requests>
+          <unix_log>opensrf.settings_unix.log</unix_log>
+          <min_children>5</min_children>
+          <max_children>15</max_children>
+          <min_spare_children>3</min_spare_children>
+          <max_spare_children>5</max_spare_children>
+        </unix_config>
+      </opensrf.settings>
+    </apps>
+  </default>
 
-		</apps>
+  <hosts>
 
-	</default>
+    <myhost.mydomain.org>
+<!-- ^-=-
+	Must match the fully qualified domain name of the host 
+	on Linux, this is usually the output of "hostname -f"
+-->
 
-	<hosts>
+<!-- List all of the apps this server will be running -->
+      <activeapps>
+        <appname>opensrf.persist</appname>
+        <appname>opensrf.settings</appname>
+        <appname>opensrf.math</appname>
+        <appname>opensrf.dbmath</appname>
+      </activeapps>
 
-		<myhost.mydomain.org>
-			<!-- ^-=-
-				must match the fully qualified domain name of the host 
-				on Linux, this is usually the output of "hostname -f"
-			-->
+      <apps>
 
+<!-- Example of an app-specific setting override -->
+        <opensrf.persist>
+          <app_settings>
+            <dbfile>/different/path/to/dbfile/persist.db</dbfile>
+          </app_settings>
+        </opensrf.persist>
 
-			<!-- List all of the apps this server will be running -->
-			<activeapps>
-				<appname>opensrf.persist</appname> 
-				<appname>opensrf.settings</appname> 
-				<appname>opensrf.math</appname> 
-				<appname>opensrf.dbmath</appname> 
-			</activeapps>
+      </apps>
 
-			<apps> <!-- Example of an app-specific setting override -->
-				<opensrf.persist>
-					<app_settings>
-						<dbfile>/different/path/to/dbfile/persist.db</dbfile>
-					</app_settings>
-				</opensrf.persist>
-			</apps>
+    </myhost.mydomain.org>
 
-		</myhost.mydomain.org> 
+  </hosts>
 
-	</hosts>
-
 </opensrf>

Modified: trunk/examples/opensrf_core.xml.example
===================================================================
--- trunk/examples/opensrf_core.xml.example	2007-06-29 14:07:01 UTC (rev 985)
+++ trunk/examples/opensrf_core.xml.example	2007-06-29 15:36:58 UTC (rev 986)
@@ -1,143 +1,141 @@
-<?xml version='1.0'?>
-
+<?xml version="1.0"?>
 <config>
 
-  <opensrf> <!-- bootstrap config for OpenSRF apps -->
+  <!-- bootstrap config for OpenSRF apps -->
+  <opensrf>
 
-		<!--  the routers's name on the network -->
-		<!-- do not change this -->
-      <router_name>router</router_name>
-		
-      <routers> 
-			<!-- 
-				list of router domains we should register with. 
-				We must at least have our default jabber domain in here
-			-->
-         <router>localhost</router>
-      </routers>
+    <!-- The OpenSRF Routers's name on the network -->
+    <!-- You should never need to change thischange this -->
+    <router_name>router</router_name>
 
-      <domains>
-      <!-- Our jabber domain, currently only one domain is supported -->
-         <domain>localhost</domain>
-      </domains>
+    <routers>
 
-      <username>client</username>
-      <passwd>mypass</passwd>
-      <port>5222</port>
+      <!-- List of router domains we should register with. 
+        We must at least have our default jabber domain in here -->
+      <router>localhost</router>
 
-		<!-- log to a local file -->
-      <logfile>/openils/var/log/osrfsys.log</logfile>
+    </routers>
+    <domains>
 
-		<!-- 
-			Log to syslog. You can use this same layout for 
-			defining the logging of all services in this file 
-		-->
+      <!-- Our jabber domain, currently only one domain is supported -->
+      <domain>localhost</domain>
 
-		<!--
-		<logfile>syslog</logfile>
-		<syslog>local2</syslog>
-		<actlog>local1</actlog>
-		-->
+    </domains>
+    <username>client</username>
+    <passwd>mypass</passwd>
+    <port>5222</port>
 
-		<!-- 0 None, 1 Error, 2 Warning, 3 Info, 4 debug, 5 Internal (Nasty) -->
-      <loglevel>3</loglevel>
+    <!-- log to a local file -->
+    <logfile>/openils/var/log/osrfsys.log</logfile>
 
+    <!-- Log to syslog. You can use this same layout for 
+        defining the logging of all services in this file -->
+<!--
+    <logfile>syslog</logfile>
+    <syslog>local2</syslog>
+    <actlog>local1</actlog>
+-->
+
+    <!-- 0 None, 1 Error, 2 Warning, 3 Info, 4 debug, 5 Internal (Nasty) -->
+    <loglevel>3</loglevel>
+
     <!-- config file for the services -->
     <settings_config>/openils/conf/opensrf.xml</settings_config>
+
   </opensrf>
 
-	<!-- Update this if you use ChopChop -->
-	<chopchop> <!-- Our jabber server -->
-		<domain>localhost</domain>
-		<port>5222</port>
+  <!-- Update this if you use ChopChop -->
+  <chopchop>
 
-		<!-- used when multiple servers need to communicate -->
-		<s2sport>5269</s2sport>
-		<secret>secret</secret>
+    <!-- Our jabber server -->
+    <domain>localhost</domain>
+    <port>5222</port>
 
-		<listen_address>10.0.0.3</listen_address>
-		<loglevel>3</loglevel>
-		<logfile>/openils/var/log/osrfsys.log</logfile>
-	</chopchop>
+    <!-- used when multiple servers need to communicate -->
+    <s2sport>5269</s2sport>
+    <secret>secret</secret>
+    <listen_address>10.0.0.3</listen_address>
+    <loglevel>3</loglevel>
+    <logfile>/openils/var/log/osrfsys.log</logfile>
+  </chopchop>
 
-	<!-- The section between <gateway>...</gateway> is a standard OpenSRF C stack config file -->
-	<gateway>
+  <!-- The section between <gateway>...</gateway> is a standard OpenSRF C stack config file -->
+  <gateway>
 
-        <!-- we consider ourselves to be the "originating" client for requests,
+    <!-- we consider ourselves to be the "originating" client for requests,
             which means we define the log XID string for log traces -->
-        <client>true</client>
+    <client>true</client>
 
-		<!--  the routers's name on the network -->
-		<router_name>router</router_name>
+    <!--  the routers's name on the network -->
+    <router_name>router</router_name>
 
-		<!-- jabber domains to connect to (domain1, domain2, ...) -->
-		<domains>
-			<domain>localhost</domain>
-		</domains>
+    <!-- jabber domains to connect to (domain1, domain2, ...) -->
+    <domains>
+      <domain>localhost</domain>
+    </domains>
 
-		<!-- These are the services that the gateway will serve. 
-			Any other requests will receive an HTTP_NOT_FOUND (404) 
-			DO NOT put any services here that you don't want the internet to have access to
-			-->
-		<services>
-			<service>opensrf.math</service> 
-			<service>open-ils.cat</service> 
-			<service>open-ils.search</service> 
-			<service>open-ils.circ</service> 
-			<service>open-ils.actor</service> 
-			<service>open-ils.auth</service> 
-		</services>
+<!-- These are the services that the gateway will serve. 
+	Any other requests will receive an HTTP_NOT_FOUND (404) 
+	DO NOT put any services here that you don't want the internet to have access to
+-->
+    <services>
+      <service>opensrf.math</service>
+      <service>open-ils.cat</service>
+      <service>open-ils.search</service>
+      <service>open-ils.circ</service>
+      <service>open-ils.actor</service>
+      <service>open-ils.auth</service>
+    </services>
 
+    <!-- jabber login info -->
+    <username>mylogin</username>
+    <passwd>mypassword</passwd>
+    <port>5222</port>
+    <logfile>/openils/var/log/gateway.log</logfile>
+    <loglevel>3</loglevel>
 
-		<!-- jabber login info -->
-		<username>mylogin</username>
-		<passwd>mypassword</passwd>
-		<port>5222</port>
-	
-		<logfile>/openils/var/log/gateway.log</logfile>
-		<loglevel>3</loglevel>
+  </gateway>
 
-	</gateway>
+  <!-- ======================================================================================== -->
 
+  <router>
 
-	<!-- ======================================================================================== -->
+    <!-- do not change -->
+    <component>0</component>
 
-	<router>
+    <trusted_domains>
 
-		<!-- do not change -->
-		<component>0</component>
-	
-		<trusted_domains>
-			<!-- Trusted servers are allowed to register apps with the router -->
-			<server>localhost</server>
-			<!-- Trusted clients are allowed to send packets through the router -->
-			<client>localhost</client>
-		</trusted_domains>
-	
-		<transport>
-			<!-- jabber server are we connecting to -->
-			<server>localhost</server>
-			<port>5222</port>
+      <!-- Trusted servers are allowed to register apps with the router -->
+      <server>localhost</server>
 
-			<!-- if this is changed, all "router_name" settings 
+      <!-- Trusted clients are allowed to send packets through the router -->
+      <client>localhost</client>
+
+    </trusted_domains>
+
+    <transport>
+
+      <!-- jabber server are we connecting to -->
+      <server>localhost</server>
+      <port>5222</port>
+
+      <!-- if this is changed, all "router_name" settings 
                 will need to be updated to match this setting -->
-			<username>router</username>
+      <username>router</username>
+      <password>mypassword</password>
 
-			<password>mypassword</password>
+      <!-- router's jabber resource -->
+      <!-- do not change this -->
+      <resource>router</resource>
+      <connect_timeout>10</connect_timeout>
+      <max_reconnect_attempts>5</max_reconnect_attempts>
 
-			<!-- router's jabber resource --> 
-			<!-- do not change this -->
-			<resource>router</resource>
+    </transport>
+    <logfile>/openils/var/log/router.log</logfile>
+    <loglevel>3</loglevel>
 
-			<connect_timeout>10</connect_timeout>
-			<max_reconnect_attempts>5</max_reconnect_attempts>
-		</transport>
-	
-		<logfile>/openils/var/log/router.log</logfile>
-		<loglevel>3</loglevel>
-	
-	</router>
+  </router>
 
-	<!-- ======================================================================================== -->
+  <!-- ======================================================================================== -->
 
 </config>

Modified: trunk/examples/srfsh.xml.example
===================================================================
--- trunk/examples/srfsh.xml.example	2007-06-29 14:07:01 UTC (rev 985)
+++ trunk/examples/srfsh.xml.example	2007-06-29 15:36:58 UTC (rev 986)
@@ -1,12 +1,13 @@
-<!-- This file follows the standard C stack bootstrap config file layout -->
+<?xml version="1.0"?>
+<!-- This file follows the standard bootstrap config file layout found in opensrf_core.xml -->
 <srfsh>
-	<router_name>router</router_name>
-	<domains>
-		<domain>127.0.0.1</domain> 
-	</domains>
-	<username>myusername</username>
-	<passwd>mypassword</passwd>
-	<port>5222</port>
-	<logfile>/path/to/log/srfsh.log</logfile>
-	<loglevel>4</loglevel>
+  <router_name>router</router_name>
+  <domains>
+    <domain>127.0.0.1</domain>
+  </domains>
+  <username>myusername</username>
+  <passwd>mypassword</passwd>
+  <port>5222</port>
+  <logfile>/path/to/log/srfsh.log</logfile>
+  <loglevel>4</loglevel>
 </srfsh>



More information about the opensrf-commits mailing list