On 2013-07-03T10:26:09, Dejan Muhamedagic <[email protected]> wrote:
> > Not sure that is expected by most people.
> > How you then delete attributes?
> Tough call :) Ideas welcome.
Set them to an empty string, or a magic "#undef" value.
> It's not only for the nodes. Attributes of resources should be
> merged as well. Perhaps to introduce another load method, say
> merge, which would merge attributes of elements instead of
> replacing them. Though the use would then get more complex (which
> seems to be justified here).
Well, that leaves open the question of how higher-level objects
(primitives, clones, groups, constraints ...) would be affected/deleted.
I'm not sure the complexity is really worth it. Merge rules get *really*
complex, quickly. And eventually, one ends with the need to annotate the
input with how one wants a merge to be resolved (such as "#undef"
values).
Then, one might go the easier way of having the caller tell us what they
want changed explicitly, instead of having to figure it out ourselves.
The whole "I'll magically replace the whole configuration and crmsh will
figure it out" premise seems broken.
Regards,
Lars
--
Architect Storage/HA
SUSE LINUX Products GmbH, GF: Jeff Hawn, Jennifer Guild, Felix Imendörffer, HRB
21284 (AG Nürnberg)
"Experience is the name everyone gives to their mistakes." -- Oscar Wilde
_______________________________________________
Linux-HA mailing list
[email protected]
http://lists.linux-ha.org/mailman/listinfo/linux-ha
See also: http://linux-ha.org/ReportingProblems