John and Xu,
in the last view days I have done some thinking about the idea from Xu
to work with the unknown tags and properties.
Starting off by looking at how one would get into the situation of
losing additional tags and properties I ended up with actually only one
feasible explanation: A libvirt-cim user wants to use a libvirt feature
not implemented in libvirt-cim.
With that in mind I revisited the new proposed pattern again:
Before I was thinking that the errors caused by new (unknown) tags and
properties are just kind of the reversal of losing the new (unknown)
tags and properties.
I now come to another conclusion: Now I think that the errors are far
worse than I thought, because as long as libvirt-cim is reducing
everything to the known management scope the libvirt-cim user has it in
his control to create and manage a new error free and working libvirt
domain.
With the new proposed pattern that is no longer true since if errors are
caused by new (unknown) tags and properties that are outside of the
known management scope of libvirt-cim the users have NO LONGER the
capability to fix these problems from within libvirt-cim!
What would be the result? I would guess that bugs would be opened
against libvirt-cim reporting that it creates erroneous libvirt domain
definitions.
I would really not like to see libvirt-cim fixes in support for
unsupported libvirt features which are caused by the new pattern of how
unknown tag and properties are maintained.
If currently bugs are opened that libvirt-cim is following the pattern
of reducing a domain definition to its known management scope the answer
is very easy: The used libvirt feature that is removed from the domain
definition is not supported by libvirt-cim and libvirt-cim only
maintains what it is supporting in the domain definition.
The question should actually be how the missing libvirt feature can be
implemented in libvirt-cim. This unsurprisingly correlates exactly with
the second paragraph above ("A libvirt-cim user wants to...").
In summary: I no longer agree to the idea of replacing the old pattern
with the new proposed pattern of how to handle unknown tags and properties.
Sorry that it took me a while to realize that. I hope that my above
explanations can be followed of why I changed my mind.
On 11/26/2013 01:31 PM, Xu Wang wrote:
于 2013/11/23 0:18, Boris Fiuczynski 写道:
> On 11/21/2013 04:15 AM, Xu Wang wrote:
>>
>> 于 2013/11/21 5:10, John Ferlan 写道:
>>> On 11/20/2013 08:27 AM, Boris Fiuczynski wrote:
>>>> John and Xu,
>>>>
>>>> On 11/19/2013 10:49 PM, John Ferlan wrote:
>>>>> On 11/18/2013 09:59 AM, Boris Fiuczynski wrote:
>>>>>> John and Xu Wang,
>>>>>> here are a few general observations from side:
>>>>> First off - I tend to find myself agreeing with Boris here. I
>>>>> think the
>>>>> concept is important and necessary; however, I'm not convinced
the
>>>>> implementation goes far enough.
>>>>>
>>>>>> 1) I agree that it makes sense to preserve the unknown xml
>>>>>> "entities"
>>>>>> even so it can create complex scenarios and even new kinds of
>>>>>> errors if
>>>>>> unknown entities depend on known entities which get modified
making
>>>>>> them
>>>>>> unusable for the unknown entities. This error would probably be
the
>>>>>> reversal of what is currently the problem when unknown entities
>>>>>> simply
>>>>>> disappear.
>>>>> Is there a more concrete example of "new kinds of errors if
unknown
>>>>> entities depend on known entities which get modified making them
>>>>> unusable for the unknown entities" that can be given? Just for
>>>>> clarity.
>>>>> I've read that line a few times and I'm still not sure :-)
>>>> OK, let's take a look at device type disk.
>>>> Since 1.0.2 the property sgio was added. Let's assume this is the
>>>> unknown entity. sgio is only valid for property device "lun".
>>>> If one now changes the property device to "disk" than the
unknown
>>>> entity
>>>> sgio would cause an error when specified.
>>>>
>>> Ah - I see. Not only do you have to manage the properties you have to
>>> know how to use them as well and all their rules. I forgot about
>>> that. I
>>> came from HP/HPVM and yes, this brings back all sorts of memories...
>>>
>>> Seems like in this case, when/if the property was changed from
"lun" to
>>> "disk" - code would have to search that 'others' list for
the "sgio"
>>> property and know how to handle adjusting it. That'll get tricky...
> You cannot search in others for something you do not know about...
> unless you can code magic! :-)
If needed that's possible. We just coding just like...xpath. Before that
we should make sure if it's necessary.
--
Mit freundlichen Grüßen/Kind regards
Boris Fiuczynski
IBM Deutschland Research & Development GmbH
Vorsitzender des Aufsichtsrats: Martina Köderitz
Geschäftsführung: Dirk Wittkopp
Sitz der Gesellschaft: Böblingen
Registergericht: Amtsgericht Stuttgart, HRB 243294