forked from suede/breakwall
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathp.patch
More file actions
78 lines (71 loc) · 4.18 KB
/
p.patch
File metadata and controls
78 lines (71 loc) · 4.18 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
diff -ruN -x '*.pyc' /sdn/code/dragonflow_baseline/dragonflow/controller/l3_app.py ./dragonflow/controller/l3_app.py
--- /sdn/code/dragonflow_baseline/dragonflow/controller/l3_app.py 2016-10-10 21:44:52.899073000 +0800
+++ ./dragonflow/controller/l3_app.py 2016-10-10 21:33:14.058690111 +0800
@@ -48,13 +48,13 @@
def router_created(self, router):
self._add_new_lrouter(router)
- def router_updated(self, router, old_lrouter):
- if old_lrouter is None:
+ def router_updated(self, router, original_router):
+ if original_router is None:
LOG.info(_LI("Logical Router created = %s"), router)
self._add_new_lrouter(router)
return
- self._update_router_interfaces(old_lrouter, router)
+ self._update_router_interfaces(original_router, router)
def router_deleted(self, router):
for port in router.get_ports():
diff -ruN -x '*.pyc' /sdn/code/dragonflow_baseline/dragonflow/controller/l3_proactive_app.py ./dragonflow/controller/l3_proactive_app.py
--- /sdn/code/dragonflow_baseline/dragonflow/controller/l3_proactive_app.py 2016-10-10 21:44:52.899073000 +0800
+++ ./dragonflow/controller/l3_proactive_app.py 2016-10-10 21:33:14.400322512 +0800
@@ -42,14 +42,14 @@
def router_created(self, router):
self._add_new_lrouter(router)
- def router_updated(self, router, old_lrouter):
- if old_lrouter is None:
+ def router_updated(self, router, original_router):
+ if original_router is None:
LOG.info(_LI("Logical Router created = %s"), router)
self._add_new_lrouter(router)
return
LOG.info(_LI("Logical router updated = %s"), router)
- self._update_router_interfaces(old_lrouter, router)
- self._update_router_attributes(old_lrouter, router)
+ self._update_router_interfaces(original_router, router)
+ self._update_router_attributes(original_router, router)
def router_deleted(self, router):
for port in router.get_ports():
diff -ruN -x '*.pyc' /sdn/code/dragonflow_baseline/dragonflow/controller/ryu_base_app.py ./dragonflow/controller/ryu_base_app.py
--- /sdn/code/dragonflow_baseline/dragonflow/controller/ryu_base_app.py 2016-10-10 21:37:25.175073000 +0800
+++ ./dragonflow/controller/ryu_base_app.py 2016-10-10 21:31:10.823025012 +0800
@@ -83,8 +83,9 @@
def notify_create_router(self, router=None):
self.dispatcher.dispatch('router_created', router=router)
- def notify_update_router(self, router=None):
- self.dispatcher.dispatch('router_updated', router=router)
+ def notify_update_router(self, router=None, original_router=None):
+ self.dispatcher.dispatch('router_updated', router=router,
+ original_router=original_router)
def notify_delete_router(self, router=None):
self.dispatcher.dispatch('router_deleted', router=router)
diff -ruN -x '*.pyc' /sdn/code/dragonflow_baseline/dragonflow/tests/unit/test_ryu_base_app.py ./dragonflow/tests/unit/test_ryu_base_app.py
--- /sdn/code/dragonflow_baseline/dragonflow/tests/unit/test_ryu_base_app.py 2016-10-10 21:44:52.903073000 +0800
+++ ./dragonflow/tests/unit/test_ryu_base_app.py 2016-10-10 21:35:27.682843605 +0800
@@ -64,7 +64,7 @@
self.ryu_df_adapter.notify_add_remote_port(lport=5)
self.ryu_df_adapter.notify_remove_remote_port(lport=6)
self.ryu_df_adapter.notify_create_router(router=9)
- self.ryu_df_adapter.notify_update_router(router=7, old_router=0)
+ self.ryu_df_adapter.notify_update_router(router=7, original_router=0)
self.ryu_df_adapter.notify_delete_router(router=8)
self.ryu_df_adapter.notify_add_security_group_rule(
secgroup=12, secgroup_rule=13)
@@ -78,7 +78,7 @@
mock.call.add_remote_port(lport=5),
mock.call.remove_remote_port(lport=6),
mock.call.router_created(router=9),
- mock.call.router_updated(router=7, old_router=0),
+ mock.call.router_updated(router=7, original_router=0),
mock.call.router_deleted(router=8),
mock.call.add_security_group_rule(
secgroup=12, secgroup_rule=13),