[Engine-devel] [engine-devel] instance type as top-level entity

Itamar Heim iheim at redhat.com
Wed Dec 4 16:29:57 UTC 2013


On 12/04/2013 02:17 PM, Omer Frenkel wrote:
>
>
> ----- Original Message -----
>> From: "Tomas Jelinek" <tjelinek at redhat.com>
>> To: "engine-devel" <engine-devel at ovirt.org>
>> Cc: "Omer Frenkel" <ofrenkel at redhat.com>
>> Sent: Wednesday, December 4, 2013 2:14:06 PM
>> Subject: [engine-devel] instance type as top-level entity
>>
>> Hey all,
>>
>> I have started to work on the instance types[1] again and hit an issue. Since
>> the instance types are supposed to be top-level entities
>> (e.g. without the connection to DC/Cluster) but they are modeled as templates
>> it is not possible to store them to DB since the DB constraints violation on
>> vm_static table
>> (e.g. the vds_group_id has to be unique and point to an existing vds_group).
>>
>> So, I see 4 options:
>>
>> 1: drop the constraints on the vm_static.vds_group_id (the
>> vds_groups_vm_static constraint)
>>     (most simple approach but would open the door to some issues which are now
>>     guard on the DB level)
>>
>> 2: do the same magic [well, hacks :) ] as with the "blank" template which is
>> in the same situation
>>     (not exactly a nice solution to have the instance types wired to one
>>     specific cluster just to satisfy the constraint but return them all the
>>     time)
>>
>> 3: do not store this data in vm_static but create some new table called e.g.
>> instance_type which would contain all of the fields from vm_static which are
>> needed by it
>>     (actually the best approach AFAIK but to do it correctly it would require
>>     some more refactoring to do some hierarchy of tables and not copy the
>>     fields from table to table)
>>
>> 4: make the instance types not top-level (e.g. bound to specific DC/Cluster)
>>     (would bring some issues for example with the default instance types which
>>     should be present for all the DC/Clusters)
>>
>> Thoughts?
>>
>> Thank you,
>> Tomas
>>
>> [1]: http://www.ovirt.org/Features/Instance_Types
>>
>
> according to the wiki (and discussions we had) instance type is bounded to a cluster (even if only as a changeable default)
> so i dont think there is an issue..

where in the wiki please?
the way i read the wiki its DC level, just like templates?




More information about the Devel mailing list