Signed-off-by: YAMAMOTO Takashi <[email protected]>
---
ryu/controller/controller.py | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/ryu/controller/controller.py b/ryu/controller/controller.py
index c753f01..7ed24de 100644
--- a/ryu/controller/controller.py
+++ b/ryu/controller/controller.py
@@ -40,6 +40,8 @@ from ryu.ofproto import nx_match
from ryu.controller import handler
from ryu.controller import ofp_event
+from ryu.instance_registry import InstanceRegistry
+
LOG = logging.getLogger('ryu.controller.controller')
CONF = cfg.CONF
@@ -106,6 +108,8 @@ def _deactivate(method):
class Datapath(object):
+ __metaclass__ = InstanceRegistry
+
supported_ofp_version = {
ofproto_v1_0.OFP_VERSION: (ofproto_v1_0,
ofproto_v1_0_parser),
@@ -136,6 +140,7 @@ class Datapath(object):
def close(self):
self.set_state(handler.DEAD_DISPATCHER)
+ self.instance_registry_unregister()
def set_state(self, state):
self.state = state
--
1.8.0.1
------------------------------------------------------------------------------
Everyone hates slow websites. So do we.
Make your web apps faster with AppDynamics
Download AppDynamics Lite for free today:
http://p.sf.net/sfu/appdyn_d2d_mar
_______________________________________________
Ryu-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/ryu-devel