[OPEN-ILS-DEV] PATCH: Throw away bootstrap.conf and use opensrf_core.xml

Dan Scott denials at gmail.com
Fri Jun 29 09:47:55 EDT 2007


On 29/06/07, Bill Erickson <billserickson at gmail.com> wrote:
>
>
>
> On 6/28/07, Dan Scott <denials at gmail.com> wrote:
> > On 28/06/07, Mike Rylander <mrylander at gmail.com> wrote:
> > > On 6/28/07, Dan Scott <denials at gmail.com> wrote:
> > > > On 27/06/07, Mike Rylander < mrylander at gmail.com> wrote:
> > > > > On 6/27/07, Dan Scott <denials at gmail.com> wrote:
> > > > > > Building on Nathan Eady's suggestion / intention from December
> > > > >
> > > > > Per discussion (and Dan's suggestion) in IRC, we're holding off on
> > > > > this patch for further refinement of the in-module documentation
> (and
> > > > > a DCO).
> > > >
> > > > Now featuring up-to-date perldoc _AND_ a DCO. Still not sure this is
> > > > exactly what you want technically, though.
> >
> > > I think the approach is fine ... it seems a very direct way of not
> > > disrupting the API.  I do have a concern about part of
> > > OpenSRF::Utils::Config::Section, though.
> >
> > <snip>
> >
> > > I can make these changes, or just kick it back to you.  Just say the
> word.
> >
> > Please, make the changes :) For some reason, VMWare Server is giving
> > me networking grief so I can't do any thorough testing atm. Your
> > analysis and corrections to my rusty Perl are greatly appreciated!
> >
> > --
> > Dan Scott
> > Laurentian University
>
>
> I updated dev.gapines.org this morning with this new patch.  All I had to do
> was add the <settings_config> section to my existing config :)  This is an
> itch that's needed scratching for a while, now, so THANKS DAN AND MIKE!
>

Glad to hear it works, Bill :)

Heh. Looks like I got too smart in my patch creation and omitted
opensrf_core.xml.example update in the patch.

Here's opensrf_core.xml.example, with <settings_config> added and a
general whitespace cleanup (2-space indents) to boot. Also included
one more required cleanup: delete bootstrap.conf.example.

I think this counts as a trivial patch, so no DCO should be necessary.

-- 
Dan Scott
Laurentian University
-------------- next part --------------
Index: examples/bootstrap.conf.example
===================================================================
--- examples/bootstrap.conf.example	(revision 932)
+++ examples/bootstrap.conf.example	(working copy)
@@ -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
-
-# --------------------------------------
-
Index: examples/opensrf_core.xml.example
===================================================================
--- examples/opensrf_core.xml.example	(revision 978)
+++ examples/opensrf_core.xml.example	(working copy)
@@ -2,145 +2,142 @@
 
 <config>
 
-	<opensrf> <!-- bootstrap config for the C apps -->
+  <opensrf> <!-- bootstrap config for OpenSRF apps -->
 
-		<!--  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 routers's name on the network -->
+    <!-- do not change this -->
+    <router_name>router</router_name>
 
-      <domains>
-			<!-- Our jabber domain, currenlty only one domain is supported -->
-         <domain>localhost</domain>
-      </domains>
+    <routers> 
+      <!-- 
+      list of router domains we should register with. 
+      We must at least have our default jabber domain in here
+      -->
+      <router>localhost</router>
+    </routers>
 
-      <username>client</username>
-      <passwd>mypass</passwd>
-      <port>5222</port>
+    <domains>
+      <!-- Our jabber domain, currently only one domain is supported -->
+      <domain>localhost</domain>
+    </domains>
 
-		<!-- log to a local file -->
-      <logfile>/openils/var/log/osrfsys.log</logfile>
+    <username>client</username>
+    <passwd>mypass</passwd>
+    <port>5222</port>
 
-		<!-- 
-			Log to syslog. You can use this same layout for 
-			defining the logging of all services in this file 
-		-->
+    <!-- log to a local file -->
+    <logfile>/openils/var/log/osrfsys.log</logfile>
 
-		<!--
-		<logfile>syslog</logfile>
-		<syslog>local2</syslog>
-		<actlog>local1</actlog>
-		-->
+    <!-- 
+    Log to syslog. You can use this same layout for 
+    defining the logging of all services in this file 
+    -->
 
-		<!-- 0 None, 1 Error, 2 Warning, 3 Info, 4 debug, 5 Internal (Nasty) -->
-      <loglevel>3</loglevel>
-   </opensrf>
+    <!--
+    <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>
 
-	<!-- Update this if you use ChopChop -->
-	<chopchop> <!-- Our jabber server -->
-		<domain>localhost</domain>
-		<port>5222</port>
+    <!-- config file for the services -->
+    <settings_config>/openils/conf/opensrf.xml</settings_config>
+  </opensrf>
 
-		<!-- used when multiple servers need to communicate -->
-		<s2sport>5269</s2sport>
-		<secret>secret</secret>
+  <!-- Update this if you use ChopChop -->
+  <chopchop> <!-- 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,
-            which means we define the log XID string for log traces -->
-        <client>true</client>
+    <!-- we consider ourselves to be the "originating" client for requests,
+    which means we define the log XID string for log traces -->
+    <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>
 
-	</gateway>
+    <logfile>/openils/var/log/gateway.log</logfile>
+    <loglevel>3</loglevel>
 
+  </gateway>
 
-	<!-- ======================================================================================== -->
 
-	<router>
+  <!-- ======================================================================================== -->
 
-		<!-- 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>
+  <router>
 
-			<!-- if this is changed, all "router_name" settings 
-                will need to be updated to match this setting -->
-			<username>router</username>
+    <!-- do not change -->
+    <component>0</component>
 
-			<password>mypassword</password>
+    <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>
 
-			<!-- router's jabber resource --> 
-			<!-- do not change this -->
-			<resource>router</resource>
+    <transport>
+      <!-- jabber server are we connecting to -->
+      <server>localhost</server>
+      <port>5222</port>
 
-			<connect_timeout>10</connect_timeout>
-			<max_reconnect_attempts>5</max_reconnect_attempts>
-		</transport>
-	
-		<logfile>/openils/var/log/router.log</logfile>
-		<loglevel>3</loglevel>
-	
-	</router>
+      <!-- if this is changed, all "router_name" settings 
+      will need to be updated to match this setting -->
+      <username>router</username>
 
-	<!-- ======================================================================================== -->
+      <password>mypassword</password>
 
-</config>
+      <!-- router's jabber resource --> 
+      <!-- do not change this -->
+      <resource>router</resource>
 
+      <connect_timeout>10</connect_timeout>
+      <max_reconnect_attempts>5</max_reconnect_attempts>
+    </transport>
 
+    <logfile>/openils/var/log/router.log</logfile>
+    <loglevel>3</loglevel>
 
+  </router>
 
+  <!-- ======================================================================================== -->
+
+</config>


More information about the Open-ils-dev mailing list