[prev in list] [next in list] [prev in thread] [next in thread] 

List:       linux-ha-dev
Subject:    Re: [Linux-ha-dev] Rename parameter of conntrackd RA
From:       Dejan Muhamedagic <dejan () suse ! de>
Date:       2012-05-11 14:53:36
Message-ID: 20120511145335.GA18721 () walrus ! homenet
[Download RAW message or body]

Hi Andreas,

On Fri, May 11, 2012 at 04:28:55PM +0200, Andreas Kurz wrote:
> Hi all,
> 
> Dejan asked me to bring this up on mailing-list.
> 
> Please have a look at this proposed patch for conntrackd. It renames the
> parameter "conntrackd" to "binary" and does a remap of "conntrackd" to
> "binary" if users of the old RA version use it.

Note that the old configurations are going to become invalid,
because they specify a parameter which doesn't exist anymore.
Well, at least crm shell is going to complain about it, not sure
about others.

> Background: Internally the RA expects a parameter called "binary" to be
> defined. So whatever value users specified in "conntrackd" parameter, it
> was ignored. A default value was used instead.
> 
> Please share your thoughts on changing a parameter name of an already
> released resource agent.

Thanks for the excellent summary! Here's the short discussion we
had at github:

https://github.com/akurz/resource-agents/commit/88f0ce97c8dbb6c70736a4cad2edaac328f933f1


Opinions?

Cheers,

Dejan

> thx & regards,
> Andreas
> 

> diff --git a/heartbeat/conntrackd b/heartbeat/conntrackd
> index 7502f5a..3ee2f83 100755
> --- a/heartbeat/conntrackd
> +++ b/heartbeat/conntrackd
> @@ -36,7 +36,10 @@
> 
> OCF_RESKEY_binary_default=conntrackd
> OCF_RESKEY_config_default=/etc/conntrackd/conntrackd.conf
> -: ${OCF_RESKEY_binary=${OCF_RESKEY_binary_default}}
> +
> +# For users of versions prior to 1.2:
> +# Map renamed parameter "conntrackd" to "binary" if in use
> +: ${OCF_RESKEY_binary=${OCF_RESKEY_conntrackd-${OCF_RESKEY_binary_default}}}
> > ${OCF_RESKEY_config=${OCF_RESKEY_config_default}}
> 
> meta_data() {
> @@ -44,7 +47,7 @@ meta_data() {
> <?xml version="1.0"?>
> <!DOCTYPE resource-agent SYSTEM "ra-api-1.dtd">
> <resource-agent name="conntrackd">
> -<version>1.1</version>
> +<version>1.2</version>
> 
> <longdesc lang="en">
> Master/Slave OCF Resource Agent for conntrackd
> @@ -53,7 +56,7 @@ Master/Slave OCF Resource Agent for conntrackd
> <shortdesc lang="en">This resource agent manages conntrackd</shortdesc>
> 
> <parameters>
> -<parameter name="conntrackd">
> +<parameter name="binary">
> <longdesc lang="en">Name of the conntrackd executable.
> If conntrackd is installed and available in the default PATH, it is sufficient to \
> configure the name of the binary For example "my-conntrackd-binary-version-0.9.14"
> -- 
> 1.7.4.1
> 
> 




> _______________________________________________________
> Linux-HA-Dev: Linux-HA-Dev@lists.linux-ha.org
> http://lists.linux-ha.org/mailman/listinfo/linux-ha-dev
> Home Page: http://linux-ha.org/

_______________________________________________________
Linux-HA-Dev: Linux-HA-Dev@lists.linux-ha.org
http://lists.linux-ha.org/mailman/listinfo/linux-ha-dev
Home Page: http://linux-ha.org/


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic