Skip to content

Instantly share code, notes, and snippets.

@yasuhito
Created December 9, 2015 08:43
Show Gist options
  • Save yasuhito/32f933344cdb6c9c7daf to your computer and use it in GitHub Desktop.
Save yasuhito/32f933344cdb6c9c7daf to your computer and use it in GitHub Desktop.
class RoutingSwitch < Trema::Controller
delegate :switch_ready, to: :@topology
delegate :features_reply, to: :@topology
delegate :switch_disconnected, to: :@topology
delegate :port_modify, to: :@topology
def packet_in(dpid, packet_in)
@topology.packet_in(dpid, packet_in)
@path_manager.packet_in(dpid, packet_in) unless packet_in.lldp?
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment