Unify the code path of creating segment

Bug #1621720 reported by Hong Hui Xiao
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
neutron
Won't Fix
Low
Hong Hui Xiao

Bug Description

Before routed network, functions in [1] are used to manage network segment. Routed network introduces a plugin [2] to manage network segment. So, now there are 2 code paths to do the same job.

This cause issue when create network in ml2. When the network is created, related segmentation_id will be reserved in ml2 and related segments will be created by using [1]. In [1], PRECOMMIT_CREATE event for SEGMENT will be sent out.

In patch [3], a subscriber was added in ml2 to subscribe the PRECOMMIT_CREATE event of SEGMENT. The subscriber will reserve the segmentation_id.

But the segmentation_id has already been reserved. A workaround was added at [4] to avoid issue.

Ideally, ml2 should use [2] to create segment and let [2] to do other things(like reserve segmentation_id). This can eliminate the workaround.

[1] neutron.db.segments_db
[2] neutron.services.segments.plugin
[3] f564dcad4d8c072767ae235353a982653b156c76
[4] https://github.com/openstack/neutron/blob/8dffc238759cf543681443a2a4540dd0d569da6a/neutron/plugins/ml2/plugin.py#L1814-L1821

Revision history for this message
Hong Hui Xiao (xiaohhui) wrote :

I add some code at [1] and will use [1] to track the progress.

[1] https://review.openstack.org/#/c/359147/

Changed in neutron:
assignee: nobody → Hong Hui Xiao (xiaohhui)
Changed in neutron:
status: New → In Progress
John Schwarz (jschwarz)
Changed in neutron:
importance: Undecided → Low
Changed in neutron:
status: In Progress → Won't Fix
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.