]> review.fuel-infra Code Review - openstack-build/neutron-build.git/commit
Schema enhancement to support MultiSegment Network
authorRomil Gupta <romilg@hp.com>
Mon, 30 Jun 2014 12:35:08 +0000 (05:35 -0700)
committerRomil Gupta <romilg@hp.com>
Sun, 19 Oct 2014 19:49:48 +0000 (12:49 -0700)
commitdb5e370b0d68c3e71626c99941fe487059b3cf88
tree89fb6d8c66b46d4f6732996a4d7876fa7a92531f
parent1aaa8b34466b0567c6a5ea0b607f1ac324ee5dfa
Schema enhancement to support MultiSegment Network

Description:
Currently, there is nothing in the schema that ensures segments
for a network are returned in the same order they were specified
when the network was created, or even in a deterministic order.

Solution:
We need to add another field named 'segment_index' in
'ml2_network_segment' table containing a numeric position index.
With segment_index field we can retrieve the segments in the
order in which user created.

This patch set also fixes ML2 invalid unit test case in
test_create_network_multiprovider().

Closes-Bug: #1224978
Closes-Bug: #1377346

Change-Id: I560c34c6fe1c5425469ccdf9b8b4905c123d496d
neutron/db/migration/alembic_migrations/versions/1f71e54a85e7_ml2_net_seg_model.py [new file with mode: 0644]
neutron/db/migration/alembic_migrations/versions/HEAD
neutron/plugins/ml2/db.py
neutron/plugins/ml2/managers.py
neutron/plugins/ml2/models.py
neutron/tests/unit/ml2/test_ml2_plugin.py