[openstack-dev] {neutron][db][models]
Henry Gessau
HenryG at gessau.net
Thu Jul 28 14:59:33 UTC 2016
Ihar Hrachyshka <ihrachys at redhat.com> wrote:
> Manjeet S <manjeet.s.bhatia at intel.com> wrote:
>
>> Hello Team,
>>
>> I have a question regarding centralizing all db models in neutron. As you
>> all know
>> Oslo versioned object work is under progress and I also had a ticket
>> opened for refactoring
>> Db models. (https://bugs.launchpad.net/neutron/+bug/1597913). There are
>> three way I can do this,
>> 1, move all models to db/models_v2.py 2, create a new dir db/models/ and
>> move whatever models are giving issue
>> Of cyclic import to db_models.py under db/models/ tree but all in same
>> file, 3rd is move into different files under
>> Same tree db/models. I liked second way better, please let me know which
>> one according to experienced developers
>> is better, I’ll do that way.
>
> I don’t think 2. is the best way forward because it still keeps all models
> in a single file with no classification. I prefer we split models by topic,
> so option 3.
>
> I took the approach for security groups here:
> https://review.openstack.org/#/c/284738/49/neutron/db/models/securitygroup.py
I also prefer this organization (option 3).
More information about the OpenStack-dev
mailing list