]> review.fuel-infra Code Review - openstack-build/neutron-build.git/commit
Support oslo_db 1.12
authorCedric Brandily <zzelle@gmail.com>
Tue, 23 Jun 2015 22:08:22 +0000 (00:08 +0200)
committerCedric Brandily <zzelle@gmail.com>
Tue, 23 Jun 2015 23:32:44 +0000 (01:32 +0200)
commit7eb9d9d316d35840706a767576ff083c9a04d781
treec0dd5396e38053cca4a1589d3eac6f820d217fb2
parentaf41907e066b11c068ee18fd82b870289e44e25a
Support oslo_db 1.12

oslo_db 1.12[1] decorates oslo_context.context.RequestContext with
session management[2][3] and add a read-only attribute 'session'. Such
feature breaks Brocade plugin and its unittests because they define
on RequestContext the 'session' attribute which now is a read-only
property. This change uses neutron.context instead of
oslo_context.context in order to delegate session management to the
neutron.context and remove read-only attribute set.

A follow-up change will refactor neutron.context in order to use oslo_db
1.12 session management instead of homemade one.

[1] https://github.com/openstack/oslo.db/releases/tag/1.12.0
[2] https://github.com/openstack/oslo.db/commit/\
    fdbd928b1fdf0334e1740e565ab8206fff54eaa6
[3] https://github.com/openstack/oslo.db/blob/\
    fdbd928b1fdf0334e1740e565ab8206fff54eaa6/oslo_db/sqlalchemy/\
    enginefacade.py#L782

Closes-Bug: #1468128
Change-Id: I0e3331f9a383fa2562706eeadb229f55593b888c
neutron/plugins/brocade/NeutronPlugin.py
neutron/tests/unit/plugins/brocade/test_brocade_vlan.py