4 Commits

Author SHA1 Message Date
Boden R
f7f6910195 sync callbacks: Eliminate SUBNET_GATEWAY resource
Commit 7b239a928f7834ff98e0fff82491bfbb2a10eece removed subnet gateway
from the callback resources in neutron. This follows suit in lib in
order to sync up.

Change-Id: I7b2f2f018723fed6c30480a92dc89654c352e6ae
2017-05-22 14:01:56 -06:00
Boden R
c13b6dfd55 sync callbacks with neutron
Change Ie8249ddc3de643bfcb5c97480f30dc3500699256 recently landed in
neutron's callbacks. This patch syncs that change into lib.

Change-Id: I03c10b4eb291db49b0aec112ed53a3670f2c1546
2017-04-24 08:45:02 -06:00
Boden R
5bfdb3d4cd Sync neutron callbacks into lib
A few commits have come into neutron's callback
modules in the past weeks. This patch syncs the latest
from neutron into neutron-lib's callback package.

Note that new decorators have been added to the
registry module. While these are not battle tested
(yet) they are isolated and only executed when using
the new decorators. Therefore they are low risk.

Change-Id: I87685a3da1e1ca14e4dd0941bfbc0bf96f24ecc5
2017-03-02 12:58:01 -07:00
Boden R
fea8bb64ba Expose/Improve callback notification interface
This patch builds a small hierarchy of event objects that
represent the payload for callback notification events. The
overall goal of this work is to begin moving away from the
existing unstructured  **kwargs passed today and standardize
on a common set of event payload objects; the beginning of such
contained herein.

A PoC/dummy patch for neutron is provided in [1] that exemplifies
consumption of the new API by:
- Removes neutron.callbacks and moves all uses to
neutron_lib.callbacks.
- Neutron uses of callbacks for BEFORE_RESPONSE events
now use neutron-lib.
- Neutron uses of callbacks for ROUTER and PROCESS
resource events now use neutron-lib.
- Neutron UTs updated to pass with this patch.

For existing discussion on this approach please see [2][3].

Co-Authored-By: Armando Migliaccio <armamig@gmail.com>

[1] https://review.openstack.org/400404/
[2] https://review.openstack.org/#/c/345718
[3] https://review.openstack.org/#/c/342304

Change-Id: If76457b1f0d5d3479e394d0dba3b22a90928f0f2
2017-01-11 13:47:12 -07:00