On Thu, 3 May 2007, Alan Robertson wrote:

> David Lee wrote:
> > On Mon, 30 Apr 2007, David Lee wrote:
> >
> >> [...]
> >> We already have such code, and already have it duplicated (ouch!) in
> >> "resources/OCF/IPaddr.in" and "resources/heartbeat/IPaddr.in".  And
> >> "pingd.sh" is in danger of making this triplicate.
> >> [...]
> >
> > Following my own email above, and going to a slightly tangential issue...
> >
> > In almost all cases "resources/heartbeat/BLAH" is now just a minimal
> > wrapper around the corresponding "resources/OCF/BLAH" which does the real
> > work.
> >
> > But in the case of "IPaddr", the "/heartbeat/" version still does the
> > "monitor" operation itself instead of passing it through to the "/OCF/"
> > version.
>
> Yes there is.
>
> Heartbeat resource agents don't support monitor ;-).
>
> However, we use this odd and different behavior to good effect in the
> CTS tests, and it's actually caught a kernel bug with respect to the
> caching of MAC addresses by some version of Linux or another.
>
> Since it's been useful, we kept it.
>
> IIRC, if you remove this behavior, everything will work fine except CTS,
> which relies on this behavior to do a little bit deeper testing.  [Or at
> least it used to, or maybe only in R1 configurations.  The details
> escape me].

No, I wasn't planning on changing the behaviour (in the sense of interface
from other places in the code).  Rather, from the software maintenance
perspective I had spotted an apparent inconsistency (the heartbeat version
not wrapping onto the OCF version in this one instance) with associated
code duplication.  So my main plans were (as discussed on the "pingd.sh"
thread) to do internal, black-box rationalisation (no interface change) of
that duplicate.

Earlier today I adjusted the "dev" repository to eliminate the duplicate
code.  But I left in place, unchanged, the "not wrapping" feature.  There
is still the double existence of "ip_monitor()", but now internally they
both call to a single instance of common code.
   http://hg.linux-ha.org/dev/rev/ab9b4952f0f6


-- 

:  David Lee                                I.T. Service          :
:  Senior Systems Programmer                Computer Centre       :
:  UNIX Team Leader                         Durham University     :
:                                           South Road            :
:  http://www.dur.ac.uk/t.d.lee/            Durham DH1 3LE        :
:  Phone: +44 191 334 2752                  U.K.                  :
_______________________________________________
Linux-HA mailing list
[email protected]
http://lists.linux-ha.org/mailman/listinfo/linux-ha
See also: http://linux-ha.org/ReportingProblems

Reply via email to