trema 0.3.16 → 0.3.17

Sign up to get free protection for your applications and to get access to all the features.
Files changed (51) hide show
  1. checksums.yaml +5 -5
  2. data/.gitignore +1 -0
  3. data/.rvmrc +52 -0
  4. data/.travis.yml +3 -0
  5. data/Gemfile +1 -1
  6. data/Rakefile +259 -1
  7. data/Rantfile +79 -216
  8. data/features/.nav +12 -0
  9. data/features/dsl/switch_port_specifier.feature +15 -0
  10. data/features/examples/switch-event/C-add_forward_entry.feature +130 -0
  11. data/features/examples/switch-event/C-delete_forward_entry.feature +97 -0
  12. data/features/examples/switch-event/C-dump_forward_entries.feature +80 -0
  13. data/features/examples/switch-event/C-set_forward_entries.feature +85 -0
  14. data/features/examples/switch-event/README.md +40 -0
  15. data/features/examples/switch-event/add_forward_entry.feature +142 -0
  16. data/features/examples/switch-event/delete_forward_entry.feature +142 -0
  17. data/features/examples/switch-event/dump_forward_entries.feature +91 -0
  18. data/features/examples/switch-event/set_forward_entries.feature +90 -0
  19. data/features/support/hooks.rb +1 -0
  20. data/ruby/rake/c/dependency.rb +42 -0
  21. data/ruby/rake/c/library-task.rb +142 -0
  22. data/ruby/rake/c/shared-library-task.rb +38 -0
  23. data/ruby/rake/c/static-library-task.rb +32 -0
  24. data/ruby/trema/path.rb +1 -0
  25. data/ruby/trema/switch-event.c +647 -0
  26. data/{src/switch_manager/management_interface.h → ruby/trema/switch-event.h} +7 -21
  27. data/ruby/trema/trema.c +2 -0
  28. data/ruby/trema/version.rb +1 -1
  29. data/spec/spec_helper.rb +26 -2
  30. data/src/examples/switch_event_config/.gitignore +7 -0
  31. data/src/examples/switch_event_config/add_forward_entry.c +227 -0
  32. data/src/examples/switch_event_config/delete_forward_entry.c +226 -0
  33. data/src/examples/switch_event_config/dump_forward_entries.c +190 -0
  34. data/src/examples/switch_event_config/set_forward_entries.c +210 -0
  35. data/src/lib/event_forward_interface.c +783 -0
  36. data/src/lib/event_forward_interface.h +138 -0
  37. data/src/lib/trema.h +1 -0
  38. data/src/lib/utility.c +13 -1
  39. data/src/lib/utility.h +3 -0
  40. data/src/switch_manager/event_forward_entry_manipulation.c +120 -0
  41. data/src/switch_manager/event_forward_entry_manipulation.h +31 -0
  42. data/src/switch_manager/secure_channel_listener.c +23 -3
  43. data/src/switch_manager/switch.c +99 -29
  44. data/src/switch_manager/switch_manager.c +176 -3
  45. data/src/switch_manager/switch_manager.h +4 -0
  46. data/src/switch_manager/switch_option.c +30 -0
  47. data/src/switch_manager/switch_option.h +41 -0
  48. data/trema.gemspec +2 -1
  49. data/unittests/lib/event_forward_interface_test.c +1646 -0
  50. data/unittests/lib/utility_test.c +23 -1
  51. metadata +48 -10
data/features/.nav CHANGED
@@ -13,7 +13,19 @@
13
13
  - dump_flows.feature
14
14
  - version.feature
15
15
  - help.feature
16
+ - dsl:
17
+ - switch_port_specifier.feature
16
18
  - examples:
19
+ - switch-event:
20
+ - README.md
21
+ - add_forward_entry.feature
22
+ - delete_forward_entry.feature
23
+ - dump_forward_entries.feature
24
+ - set_forward_entries.feature
25
+ - C-add_forward_entry.feature
26
+ - C-delete_forward_entry.feature
27
+ - C-dump_forward_entries.feature
28
+ - C-set_forward_entries.feature
17
29
  - hello_trema.feature
18
30
  - list_switches.feature
19
31
  - switch_monitor.feature
@@ -0,0 +1,15 @@
1
+ @wip
2
+ Feature: Switch Port Specifier
3
+ By adding a postfix (`:port#`) to the switch's name found in the `link` directive you can specify the exact port number to be used when the link is created.
4
+
5
+ vswitch( "switch" ) { dpid 0xabc }
6
+ vhost "host1"
7
+ vhost "host2"
8
+ vhost "host3"
9
+ link "host1", "switch:1" # Connects host1 to switch-port #1
10
+ link "host2", "switch:2" # Connects host2 to switch-port #2
11
+ link "host3", "switch:3" # Connects host3 to switch-port #3
12
+
13
+ The reason why this feature required is that if the port number is not explicitly specified, trema randomly determines this. Which might be sufficient for some simple test cases but it is inadequate for other complex test cases.
14
+
15
+ Therefore, if you wish to test your controllers rigorously on a configured virtual network you might find the `switch_name:port_number` syntax useful. It is also useful to be able to send packets to destined hosts or switches via the specified ports by using `SendOutPort` actions.
@@ -0,0 +1,130 @@
1
+ Feature: C function example command "add_forward_entry"
2
+
3
+ Switch Event forwarding configuration command (`add_forward_entry`)
4
+ is a command to add an event forwarding entry to
5
+ Switch Manager and Switch Daemons.
6
+
7
+ Following switch event types can be configured by this command:
8
+
9
+ * vendor
10
+ * packet_in
11
+ * port_stat
12
+ * state_notify
13
+
14
+ This command is a simple usage example for C version of switch event forwarding API.
15
+ C version API is defined as a group of functions declared in event_forward_interface.h.
16
+ These functions are used in topology manager to
17
+ add itself to packet_in forwarding entry of all existing switch daemons and
18
+ switch manager to receive LLDP packets.
19
+ By adding and removing entry for 'topology' from some switches, it is possible to make
20
+ topology manager to map only a subset of the switches managed by trema.
21
+
22
+ Please see README.md for general notes on switch event forwarding API.
23
+
24
+ Background:
25
+ Given I cd to "../../src/examples/switch_event_config/"
26
+ And I compile "add_forward_entry.c" into "add_forward_entry"
27
+ And I compile "dump_forward_entries.c" into "dump_forward_entries"
28
+
29
+ Scenario: add_forward_entry Usage
30
+ When I successfully run `trema run './add_forward_entry -h'`
31
+ Then the output should contain:
32
+ """
33
+ Add OpenFlow Switch Manager/Daemon event forward entry.
34
+ Both Switch Mgr/Daemon: add_forward_entry -t EVENT_TYPE service_name
35
+ Only Switch Manager : add_forward_entry -m -t EVENT_TYPE service_name
36
+ Only Switch Daemon : add_forward_entry -s SWITCH_DPID -t EVENT_TYPE service_name
37
+
38
+ EVENT_TYPE:
39
+ -t, --type={vendor,packet_in,port_status,state_notify} Specify event type.
40
+ """
41
+
42
+ Scenario Outline: Add 'mirror' to All Switch Manager/Daemon's event forwarding entries of packet_in
43
+ Given a file named "nw_dsl.conf" with:
44
+ """
45
+ vswitch { datapath_id 0x1 }
46
+ vswitch { datapath_id 0x2 }
47
+ """
48
+ And I successfully run `trema run ../repeater_hub/repeater-hub.rb -c nw_dsl.conf -d`
49
+ And wait until "RepeaterHub" is up
50
+ When I successfully run `trema run './add_forward_entry -t packet_in mirror'`
51
+ Then the output should contain "Operation Succeeded."
52
+ And I successfully run `trema run './dump_forward_entries <option> -t packet_in'`
53
+ And the output should contain "Current service name list:"
54
+ And the output should match /.* RepeaterHub.*/
55
+ And the output should match /.* mirror.*/
56
+
57
+ Examples:
58
+ | target | option |
59
+ | SW MGR | -m |
60
+ | SW 0x1 | -s 0x1 |
61
+ | SW 0x2 | -s 0x2 |
62
+
63
+ Scenario Outline: Switch added after event forwarding entry manipulation should also reflect new configuration of Switch Manager.
64
+ Given a file named "nw_dsl.conf" with:
65
+ """
66
+ vswitch { datapath_id 0x1 }
67
+ vswitch { datapath_id 0x2 }
68
+ """
69
+ And I successfully run `trema run ../repeater_hub/repeater-hub.rb -c nw_dsl.conf -d`
70
+ And wait until "RepeaterHub" is up
71
+ And I successfully run `trema run './add_forward_entry -t packet_in mirror'`
72
+ And the output should contain "Operation Succeeded."
73
+ And a file named "switch_event_config_add.conf" with:
74
+ """
75
+ vswitch { datapath_id 0x3 }
76
+ """
77
+ And I successfully run `trema run -c switch_event_config_add.conf -d`
78
+ When I successfully run `trema run './dump_forward_entries <option> -t packet_in'`
79
+ Then the output should contain "Current service name list:"
80
+ And the output should match /.* RepeaterHub.*/
81
+ And the output should match /.* mirror.*/
82
+
83
+ Examples:
84
+ | target | option |
85
+ | SW 0x3 | -s 0x3 |
86
+ | SW MGR | -m |
87
+ | SW 0x1 | -s 0x1 |
88
+ | SW 0x2 | -s 0x2 |
89
+
90
+ Scenario Outline: Add 'mirror' only to Switch Manager's event forwarding entry of packet_in
91
+ Given a file named "nw_dsl.conf" with:
92
+ """
93
+ vswitch { datapath_id 0x1 }
94
+ vswitch { datapath_id 0x2 }
95
+ """
96
+ And I successfully run `trema run ../repeater_hub/repeater-hub.rb -c nw_dsl.conf -d`
97
+ And wait until "RepeaterHub" is up
98
+ When I successfully run `trema run './add_forward_entry -m -t packet_in mirror'`
99
+ Then the output should contain "Updated service name list:"
100
+ And the output should contain " RepeaterHub"
101
+ And the output should contain " mirror"
102
+ And I successfully run `trema run './dump_forward_entries -s <switch> -t packet_in'`
103
+ And the output should match /Current service name list:.* RepeaterHub/
104
+ And the output should not match /Current service name list:.* mirror/
105
+
106
+ Examples:
107
+ | switch |
108
+ | 0x1 |
109
+ | 0x2 |
110
+
111
+ Scenario Outline: Add 'mirror' only to Switch Daemon 0x1's event forwarding entries of packet_in
112
+ Given a file named "nw_dsl.conf" with:
113
+ """
114
+ vswitch { datapath_id 0x1 }
115
+ vswitch { datapath_id 0x2 }
116
+ """
117
+ And I successfully run `trema run ../repeater_hub/repeater-hub.rb -c nw_dsl.conf -d`
118
+ And wait until "RepeaterHub" is up
119
+ When I successfully run `trema run './add_forward_entry -s 0x1 -t packet_in mirror'`
120
+ Then the output should contain "Updated service name list:"
121
+ And the output should contain " RepeaterHub"
122
+ And the output should contain " mirror"
123
+ And I successfully run `trema run './dump_forward_entries <option> -t packet_in'`
124
+ And the output should match /Current service name list:.* RepeaterHub/
125
+ And the output should not match /Current service name list:.* mirror/
126
+
127
+ Examples:
128
+ | target | option |
129
+ | SW MGR | -m |
130
+ | SW 0x2 | -s 0x2 |
@@ -0,0 +1,97 @@
1
+ Feature: C function example command "delete_forward_entry"
2
+
3
+ Switch Event forwarding configuration command (`delete_forward_entry`)
4
+ is a command to delete an event forwarding entry from
5
+ Switch Manager and Switch Daemons.
6
+
7
+ Following switch event types can be configured by this command:
8
+
9
+ * vendor
10
+ * packet_in
11
+ * port_stat
12
+ * state_notify
13
+
14
+ This command is a simple usage example for C version of switch event forwarding API.
15
+ C version API is defined as a group of functions declared in event_forward_interface.h.
16
+ These functions are used in topology manager to
17
+ add itself to packet_in forwarding entry of all existing switch daemons and
18
+ switch manager to receive LLDP packets.
19
+ By adding and removing entry for 'topology' from some switches, it is possible to make
20
+ topology manager to map only a subset of the switches managed by trema.
21
+
22
+ Please see README.md for general notes on switch event forwarding API.
23
+
24
+ Background:
25
+ Given I cd to "../../src/examples/switch_event_config/"
26
+ And I compile "delete_forward_entry.c" into "delete_forward_entry"
27
+ And I compile "dump_forward_entries.c" into "dump_forward_entries"
28
+
29
+ Scenario: delete_forward_entry Usage
30
+ When I successfully run `trema run './delete_forward_entry -h'`
31
+ Then the output should contain:
32
+ """
33
+ Delete OpenFlow Switch Manager/Daemon event forward entry.
34
+ Both Switch Mgr/Daemon: delete_forward_entry -t EVENT_TYPE service_name
35
+ Only Switch Manager : delete_forward_entry -m -t EVENT_TYPE service_name
36
+ Only Switch Daemon : delete_forward_entry -s SWITCH_DPID -t EVENT_TYPE service_name
37
+
38
+ EVENT_TYPE:
39
+ -t, --type={vendor,packet_in,port_status,state_notify} Specify event type.
40
+ """
41
+
42
+ Scenario Outline: Delete 'RepeaterHub' from All Switch Manager/Daemon's event forwarding entries of packet_in
43
+ Given a file named "nw_dsl.conf" with:
44
+ """
45
+ vswitch { datapath_id 0x1 }
46
+ vswitch { datapath_id 0x2 }
47
+ """
48
+ And I successfully run `trema run ../repeater_hub/repeater-hub.rb -c nw_dsl.conf -d`
49
+ And wait until "RepeaterHub" is up
50
+ When I successfully run `trema run './delete_forward_entry -t packet_in RepeaterHub '`
51
+ Then the output should contain "Operation Succeeded."
52
+ And I successfully run `trema run './dump_forward_entries <option> -t packet_in'`
53
+ And the output should not match /Current service name list:.* RepeaterHub/
54
+
55
+ Examples:
56
+ | target | option |
57
+ | SW MGR | -m |
58
+ | SW 0x1 | -s 0x1 |
59
+ | SW 0x2 | -s 0x2 |
60
+
61
+ Scenario Outline: Delete 'RepeaterHub' only from Switch Manager's event forwarding entries of packet_in
62
+ Given a file named "nw_dsl.conf" with:
63
+ """
64
+ vswitch { datapath_id 0x1 }
65
+ vswitch { datapath_id 0x2 }
66
+ """
67
+ And I successfully run `trema run ../repeater_hub/repeater-hub.rb -c nw_dsl.conf -d`
68
+ And wait until "RepeaterHub" is up
69
+ When I successfully run `trema run './delete_forward_entry -m -t packet_in RepeaterHub'`
70
+ Then the output should contain "Updated service name list is empty."
71
+ And the output should not contain " RepeaterHub"
72
+ And I successfully run `trema run './dump_forward_entries -s <switch> -t packet_in'`
73
+ And the output should match /Current service name list:.* RepeaterHub/
74
+
75
+ Examples:
76
+ | switch |
77
+ | 0x1 |
78
+ | 0x2 |
79
+
80
+ Scenario Outline: Delete 'RepeaterHub' only from Switch Daemon 0x1's event forwarding entries of packet_in
81
+ Given a file named "nw_dsl.conf" with:
82
+ """
83
+ vswitch { datapath_id 0x1 }
84
+ vswitch { datapath_id 0x2 }
85
+ """
86
+ And I successfully run `trema run ../repeater_hub/repeater-hub.rb -c nw_dsl.conf -d`
87
+ And wait until "RepeaterHub" is up
88
+ When I successfully run `trema run './delete_forward_entry -s 0x1 -t packet_in RepeaterHub'`
89
+ Then the output should contain "Updated service name list is empty."
90
+ And the output should not contain " RepeaterHub"
91
+ And I successfully run `trema run './dump_forward_entries <option> -t packet_in'`
92
+ And the output should match /Current service name list:.* RepeaterHub/
93
+
94
+ Examples:
95
+ | target | option |
96
+ | SW MGR | -m |
97
+ | SW 0x2 | -s 0x2 |
@@ -0,0 +1,80 @@
1
+ Feature: C function example command "dump_forward_entries"
2
+
3
+ Switch Event forwarding configuration command (`dump_forward_entries`)
4
+ is a command to dump event forwarding entries of
5
+ Switch Manager and Switch Daemons.
6
+
7
+ Following switch event types can be configured by this command:
8
+
9
+ * vendor
10
+ * packet_in
11
+ * port_stat
12
+ * state_notify
13
+
14
+ This command is a simple usage example for C version of switch event forwarding API.
15
+ C version API is defined as a group of functions declared in event_forward_interface.h.
16
+ These functions are used in topology manager to
17
+ add itself to packet_in forwarding entry of all existing switch daemons and
18
+ switch manager to receive LLDP packets.
19
+ By adding and removing entry for 'topology' from some switches, it is possible to make
20
+ topology manager to map only a subset of the switches managed by trema.
21
+
22
+ Please see README.md for general notes on switch event forwarding API.
23
+
24
+ Background:
25
+ Given I cd to "../../src/examples/switch_event_config/"
26
+ And I compile "dump_forward_entries.c" into "dump_forward_entries"
27
+
28
+ Scenario: dump_forward_entries Usage
29
+ When I successfully run `trema run './dump_forward_entries -h'`
30
+ Then the output should contain:
31
+ """
32
+ Dump OpenFlow Switch Manager/Daemon event forward entries.
33
+ Switch Manager: dump_forward_entries -m -t EVENT_TYPE
34
+ Switch Daemon : dump_forward_entries -s SWITCH_DPID -t EVENT_TYPE
35
+
36
+ EVENT_TYPE:
37
+ -t, --type={vendor,packet_in,port_status,state_notify} Specify event type.
38
+ """
39
+
40
+ Scenario Outline: Dump Switch Manager's event forwarding entries for each event type
41
+ Given a file named "nw_dsl.conf" with:
42
+ """
43
+ vswitch { datapath_id 0x1 }
44
+ vswitch { datapath_id 0x2 }
45
+ """
46
+ And I successfully run `trema run ../repeater_hub/repeater-hub.rb -c nw_dsl.conf -d`
47
+ And wait until "RepeaterHub" is up
48
+ When I successfully run `trema run './dump_forward_entries -m -t <type>'`
49
+ Then the output should contain "Current service name list:"
50
+ And the output should contain " RepeaterHub"
51
+
52
+ Examples:
53
+ | type |
54
+ | vendor |
55
+ | packet_in |
56
+ | port_status |
57
+ | state_notify |
58
+
59
+ Scenario Outline: Dump Switch Daemon's event forwarding entries for each event type on each switch
60
+ Given a file named "nw_dsl.conf" with:
61
+ """
62
+ vswitch { datapath_id 0x1 }
63
+ vswitch { datapath_id 0x2 }
64
+ """
65
+ And I successfully run `trema run ../repeater_hub/repeater-hub.rb -c nw_dsl.conf -d`
66
+ And wait until "RepeaterHub" is up
67
+ When I successfully run `trema run './dump_forward_entries -s <switch> -t <type>'`
68
+ Then the output should contain "Current service name list:"
69
+ And the output should contain " RepeaterHub"
70
+
71
+ Examples:
72
+ | switch | type |
73
+ | 0x1 | vendor |
74
+ | 0x1 | packet_in |
75
+ | 0x1 | port_status |
76
+ | 0x1 | state_notify |
77
+ | 0x2 | vendor |
78
+ | 0x2 | packet_in |
79
+ | 0x2 | port_status |
80
+ | 0x2 | state_notify |
@@ -0,0 +1,85 @@
1
+ Feature: C function example command "set_forward_entries"
2
+
3
+ Switch Event forwarding configuration command (`set_forward_entries`)
4
+ is a command to replace event forwarding entries of
5
+ Switch Manager and Switch Daemons.
6
+
7
+ Following switch event types can be configured by this command:
8
+
9
+ * vendor
10
+ * packet_in
11
+ * port_stat
12
+ * state_notify
13
+
14
+ This command is a simple usage example for C version of switch event forwarding API.
15
+ C version API is defined as a group of functions declared in event_forward_interface.h.
16
+ These functions are used in topology manager to
17
+ add itself to packet_in forwarding entry of all existing switch daemons and
18
+ switch manager to receive LLDP packets.
19
+ By adding and removing entry for 'topology' from some switches, it is possible to make
20
+ topology manager to map only a subset of the switches managed by trema.
21
+
22
+ Please see README.md for general notes on switch event forwarding API.
23
+
24
+ Background:
25
+ Given I cd to "../../src/examples/switch_event_config/"
26
+ And I compile "set_forward_entries.c" into "set_forward_entries"
27
+ And I compile "dump_forward_entries.c" into "dump_forward_entries"
28
+
29
+ Scenario: set_forward_entries Usage
30
+ When I successfully run `trema run './set_forward_entries -h'`
31
+ Then the output should contain:
32
+ """
33
+ Set OpenFlow Switch Manager/Daemon event forward entries.
34
+ Switch Manager: set_forward_entries -m -t EVENT_TYPE service_name1,service_name2,...
35
+ Switch Daemon : set_forward_entries -s SWITCH_DPID -t EVENT_TYPE service_name1,service_name2,...
36
+
37
+ EVENT_TYPE:
38
+ -t, --type={vendor,packet_in,port_status,state_notify} Specify event type.
39
+ """
40
+
41
+ Scenario Outline: Replace Switch Manager's event forwarding entries of packet_in to 'mirror' and 'filter'
42
+ Given a file named "nw_dsl.conf" with:
43
+ """
44
+ vswitch { datapath_id 0x1 }
45
+ vswitch { datapath_id 0x2 }
46
+ """
47
+ And I successfully run `trema run ../repeater_hub/repeater-hub.rb -c nw_dsl.conf -d`
48
+ And wait until "RepeaterHub" is up
49
+ When I successfully run `trema run './set_forward_entries -m -t packet_in mirror,filter'`
50
+ Then the output should contain "Updated service name list:"
51
+ And the output should contain " mirror"
52
+ And the output should contain " filter"
53
+ And the output should not contain " RepeaterHub"
54
+ And I successfully run `trema run './dump_forward_entries -s <switch> -t packet_in'`
55
+ And the output should match /Current service name list:.* RepeaterHub/
56
+ And the output should not match /Current service name list:.* mirror/
57
+ And the output should not match /Current service name list:.* filter/
58
+
59
+ Examples:
60
+ | switch |
61
+ | 0x1 |
62
+ | 0x2 |
63
+
64
+ Scenario Outline: Replace Switch Daemon 0x1's event forwarding entries of packet_in to 'mirror' and 'filter'
65
+ Given a file named "nw_dsl.conf" with:
66
+ """
67
+ vswitch { datapath_id 0x1 }
68
+ vswitch { datapath_id 0x2 }
69
+ """
70
+ And I successfully run `trema run ../repeater_hub/repeater-hub.rb -c nw_dsl.conf -d`
71
+ And wait until "RepeaterHub" is up
72
+ When I successfully run `trema run './set_forward_entries -s 0x1 -t packet_in mirror,filter'`
73
+ Then the output should contain "Updated service name list:"
74
+ And the output should contain " mirror"
75
+ And the output should contain " filter"
76
+ And the output should not contain " RepeaterHub"
77
+ And I successfully run `trema run './dump_forward_entries <option> -t packet_in'`
78
+ And the output should match /Current service name list:.* RepeaterHub/
79
+ And the output should not match /Current service name list:.* mirror.*/
80
+ And the output should not match /Current service name list:.* filter.*/
81
+
82
+ Examples:
83
+ | target | option |
84
+ | SW MGR | -m |
85
+ | SW 0x2 | -s 0x2 |
@@ -0,0 +1,40 @@
1
+ # Switch Event forwarding API
2
+
3
+ This API controls the forwarding of certain type of Openflow messages received from a switch to a specified controller.
4
+ The processes responsible for this are Switch Manager and Switch Daemons.
5
+
6
+ This API can be used for:
7
+
8
+ * Diagnosing a controller environment:
9
+ * Check which controller is handling the messages from a certain switch.
10
+ * Forward a copy of a message to another user-defined controller
11
+ for debug level logging, etc.
12
+ * Dynamically change configuration to:
13
+ * Add/Remove a controller on a running network setup.
14
+ * Replace a running controller with another controller.
15
+
16
+ Switch events, are OpenFlow messages sent from switches on various types of events,
17
+ and forwarded to controllers based on the event forwarding entries of each Switch Daemon.
18
+ Initial forwarding entries of a Switch Daemon derived from the
19
+ forwarding entries of the Switch Manager, when a switch first connects to trema.
20
+
21
+ In other words, configuring a Switch Daemon changes the behavior of
22
+ existing connected switches, and configuring a Switch Manager changes the behavior
23
+ of switches that may connect later on.
24
+
25
+ Following switch event types can be forwarded by this API:
26
+
27
+ * :vendor
28
+ * :packet_in
29
+ * :port_stat
30
+ * :state_notify
31
+
32
+ Note that this API only change where each event is forwarded,
33
+ and it will **not** emulate any switch events, which normally occur when a
34
+ switch is connected to or disconnected from a controller.
35
+
36
+ * switch_ready event will **not** be generated by adding an entry to an existing switch.
37
+ * disconnected event will **not** be generated by removing an entry from an existing switch.
38
+
39
+ Please see the YARD generated document for method details.
40
+