config: Synchronously create 'native' Routing Instance and link to it on VirtualMachineInterface create

Bug #1488181 reported by Hampapur Ajay
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Juniper Openstack
Status tracked in Trunk
R2.20
Fix Committed
Medium
Hampapur Ajay
Trunk
Fix Committed
Medium
Hampapur Ajay

Bug Description

To reduce edge-cases for creating objects/references needed by the system, it would be preferable to create the Native RI (for a VN vn1 this would be RI with name vn1) and link a VMI to this native RI upon VMI creation. With this schema-transformer will be responsible for higher-level 'compilation' and simple, predictable transforms could be done within api-server synchronously in the request context itself.

Tags: config
Revision history for this message
OpenContrail Admin (ci-admin-f) wrote : [Review update] master

Review in progress for https://review.opencontrail.org/13258
Submitter: Hampapur Ajay (<email address hidden>)

Nischal Sheth (nsheth)
tags: added: config
Revision history for this message
OpenContrail Admin (ci-admin-f) wrote :

Review in progress for https://review.opencontrail.org/13460
Submitter: Hampapur Ajay (<email address hidden>)

Revision history for this message
OpenContrail Admin (ci-admin-f) wrote : A change has been merged

Reviewed: https://review.opencontrail.org/13460
Committed: http://github.org/Juniper/contrail-test/commit/fd1c972c56e37ca8163388f0a6b940f328ca31e3
Submitter: Zuul
Branch: master

commit fd1c972c56e37ca8163388f0a6b940f328ca31e3
Author: Hampapur Ajay <email address hidden>
Date: Mon Aug 31 18:09:14 2015 -0700

Retry till routing-instance has route-target reference.

With change of creating native RI synchronously in api-server, it
is no longer the case that RI will have RT on first read (schema
transformer sets the RT ref).

Change-Id: Id064e2fa9c2bb3db9005a89dcfc52baed1b7076b
Partial-Bug: #1488181

Revision history for this message
OpenContrail Admin (ci-admin-f) wrote : [Review update] master

Review in progress for https://review.opencontrail.org/13258
Submitter: Hampapur Ajay (<email address hidden>)

Revision history for this message
OpenContrail Admin (ci-admin-f) wrote :

Review in progress for https://review.opencontrail.org/13258
Submitter: Sachin Bansal (<email address hidden>)

Revision history for this message
OpenContrail Admin (ci-admin-f) wrote : A change has been merged

Reviewed: https://review.opencontrail.org/13258
Committed: http://github.org/Juniper/contrail-controller/commit/a4d76bf81e432bc6cc7cd2b71ac7a9cb7ac06585
Submitter: Zuul
Branch: master

commit a4d76bf81e432bc6cc7cd2b71ac7a9cb7ac06585
Author: Sachin Bansal <email address hidden>
Date: Thu Sep 10 16:38:29 2015 -0700

config: sync native-ri create/delete vmi->native-ri ref.

Synchronously create the 'native' routing-instance for a
virtual-network. Also when a virtual-machine-interface is
created, link it to the native routing-instance in the same
context. To achieve this following refactoring is done:

1. create a ApiContext object which will be present
in every request as a 'thread'-local-variable.
2. ApiContext will hold a reference to a <request> object
which could be bottle.request(external) or ApiInternalRequest
which would be requests generated from within api-server.
3. Replace occurences of bottle.request with get_request()
to normalize request structure.
4. Rename and add more interactions from request handling
layer to type-specific handling layer with <pre|post>_dbe_<CUD>
5. Have ApiContext hold a list of undo_callables so that
callee can add to undo-list and caller on any error will
iterate and invoke undo callables.

Closes-Bug: #1488181
Change-Id: Ibf1d5da1d7bd3ce8bc7f1f48eaab0f66d613942c

Revision history for this message
OpenContrail Admin (ci-admin-f) wrote : [Review update] R2.22-dev

Review in progress for https://review.opencontrail.org/13947
Submitter: Sachin Bansal (<email address hidden>)

Revision history for this message
OpenContrail Admin (ci-admin-f) wrote : A change has been merged

Reviewed: https://review.opencontrail.org/13947
Committed: http://github.org/Juniper/contrail-controller/commit/f3ad822b796157669c3ba27044a261a9eda66cf5
Submitter: Zuul
Branch: R2.22-dev

commit f3ad822b796157669c3ba27044a261a9eda66cf5
Author: Sachin Bansal <email address hidden>
Date: Tue Jun 9 17:33:25 2015 -0700

config: sync native-ri create/delete vmi->native-ri ref.

Synchronously create the 'native' routing-instance for a
virtual-network. Also when a virtual-machine-interface is
created, link it to the native routing-instance in the same
context. To achieve this following refactoring is done:

1. create a ApiContext object which will be present
in every request as a 'thread'-local-variable.
2. ApiContext will hold a reference to a <request> object
which could be bottle.request(external) or ApiInternalRequest
which would be requests generated from within api-server.
3. Replace occurences of bottle.request with get_request()
to normalize request structure.
4. Rename and add more interactions from request handling
layer to type-specific handling layer with <pre|post>_dbe_<CUD>
5. Have ApiContext hold a list of undo_callables so that
callee can add to undo-list and caller on any error will
iterate and invoke undo callables.

Closes-Bug: #1488181
Change-Id: Ibf1d5da1d7bd3ce8bc7f1f48eaab0f66d613942c
(cherry picked from commit a4d76bf81e432bc6cc7cd2b71ac7a9cb7ac06585)

Revision history for this message
OpenContrail Admin (ci-admin-f) wrote : [Review update] master

Review in progress for https://review.opencontrail.org/14090
Submitter: Sachin Bansal (<email address hidden>)

Revision history for this message
OpenContrail Admin (ci-admin-f) wrote : A change has been merged

Reviewed: https://review.opencontrail.org/14090
Committed: http://github.org/Juniper/contrail-controller/commit/25b64fa6e998458cb4236e285ca24639bd7d9f6d
Submitter: Zuul
Branch: master

commit 25b64fa6e998458cb4236e285ca24639bd7d9f6d
Author: Sachin Bansal <email address hidden>
Date: Mon Sep 28 11:07:13 2015 -0700

Fix the usage of default_ri_name

default_ri_name now stores fq name of the ri. We should not prepend vn's fq name
to get it

Change-Id: Ibb2b7c371a695bf0553930f0a42ad6a9e04a08d5
Related-Bug: 1488181

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.