Inheritance

John Relph John.Relph at noaa.gov
Mon Feb 5 20:15:35 CET 2007


Christoph Maser writes:
>-----BEGIN PGP SIGNED MESSAGE-----
>Hash: SHA1
>
>
>
>John Relph wrote:
>> Christoph Maser writes:
>> Could we change that to read
>> 
>> hostgroups	+, linux-servers,web-servers
>> 
>> 
>> this +<string> looks a bit awkward to me. Also considering how you use
>> "!" as a unary operator +<string> makes people think the "+" is an
>> operator for the following string.
>> 
>>> Disagreed.  Your proposed syntax is more confusing.  Your syntax makes
>>> it look like "+" is itself a hostgroup (albeit with special meaning).
>>> The original syntax is well known and understood.  For example, Apache
>>> configuration files use the "+" as proposed below.
>> 
>>> I prefer Ethan's proposed syntax.
>> 
>>> 	-- John
>> 
>> Chris
>
>John,
>
>i see your point but i really think the way +<string> and !<string> are
>used are not very consistent. I'm not quite certain which parts in
>httpd-config you mean? Options? Could you further elaborate this comparison?

See http://httpd.apache.org/docs/2.0/mod/core.html#options

  ... if all the options on the Options directive are preceded by a +
  or - symbol, the options are merged. Any options preceded by a + are
  added to the options currently in force, and any options preceded by
  a - are removed from the options currently in force. 

Which basically says you can do this:

  hostgroups +linux-servers,web-servers

which adds the specified groups to those inherited from the template,
or this:

  hostgroups +linux-servers,-web-servers

which adds the first group to and removes the second group from those
inherited from the template, or this:

  hostgroups linux-servers,web-servers

which replaces any groups inherited from the template with those
specified.

I don't know if we need the minus "-" operator for Nagios (though I
suppose if we built it, they would come).

Also see xhost(1) for similar syntax.

	-- John

>Chris
>
>-----BEGIN PGP SIGNATURE-----
>Version: GnuPG v1.2.6 (GNU/Linux)
>Comment: Using GnuPG with CentOS - http://enigmail.mozdev.org
>
>iD8DBQFFx39ksLjW0HYht7URAh8eAJ9lawMLRCNpSo1nXkLNUMn2M0JTggCcC1G0
>C63XAf2DxvgKDb7GZf/DOPM=
>=XhmA
>-----END PGP SIGNATURE-----
>
>-------------------------------------------------------------------------
>Using Tomcat but need to do more? Need to support web services, security?
>Get stuff done quickly with pre-integrated technology to make your job easier.
>Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
>http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
>_______________________________________________
>Nagios-devel mailing list
>Nagios-devel at lists.sourceforge.net
>https://lists.sourceforge.net/lists/listinfo/nagios-devel

-- 
John Relph <John.Relph at noaa.gov>
NOAA/NESDIS/National Oceanographic Data Center

-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier.
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642




More information about the Developers mailing list