faucet.faucet module

OSKenApp shim between Ryu and Valve.

class faucet.faucet.EventFaucetAdvertise[source]

Bases: EventBase

Event used to trigger periodic network advertisements (eg IPv6 RAs).

class faucet.faucet.EventFaucetEventSockHeartbeat[source]

Bases: EventBase

Event used to trigger periodic events on event sock, causing it to raise an exception if conn is broken.

class faucet.faucet.EventFaucetFastAdvertise[source]

Bases: EventBase

Event used to trigger periodic fast network advertisements (eg LACP).

class faucet.faucet.EventFaucetFastStateExpire[source]

Bases: EventBase

Event used to trigger fast expiration of state in controller.

class faucet.faucet.EventFaucetMaintainStackRoot[source]

Bases: EventBase

Event used to maintain stack root.

class faucet.faucet.EventFaucetMetricUpdate[source]

Bases: EventBase

Event used to trigger update of metrics.

class faucet.faucet.EventFaucetResolveGateways[source]

Bases: EventBase

Event used to trigger gateway re/resolution.

class faucet.faucet.EventFaucetStateExpire[source]

Bases: EventBase

Event used to trigger expiration of state in controller.

class faucet.faucet.Faucet(*args, **kwargs)[source]

Bases: OSKenAppBase

A OSKenApp that implements an L2/L3 learning VLAN switch.

Valve provides the switch implementation; this is a shim for the Ryu event handling framework to interface with Valve.

bgp = None
desc_stats_reply_handler(ryu_event)[source]

Handle OFPDescStatsReply from datapath.

Parameters:

ryu_event (ryu.controller.ofp_event.EventOFPDescStatsReply) – trigger.

error_handler(ryu_event)[source]

Handle an OFPError from a datapath.

Parameters:

ryu_event (ryu.controller.ofp_event.EventOFPErrorMsg) – trigger

event_socket_heartbeat_time = 0
exc_logname = 'faucet.exception'
features_handler(ryu_event)[source]

Handle receiving a switch features message from a datapath.

Parameters:

ryu_event (ryu.controller.ofp_event.EventOFPStateChange) – trigger.

flowremoved_handler(ryu_event)[source]

Handle a flow removed event.

Parameters:

ryu_event (ryu.controller.ofp_event.EventOFPFlowRemoved) – trigger.

logname = 'faucet'
metric_update(_)[source]

Handle a request to update metrics in the controller.

notifier = None
packet_in_handler(ryu_event)[source]

Handle a packet in event from the dataplane.

Parameters:

ryu_event (ryu.controller.event.EventReplyBase) – packet in message.

port_desc_stats_reply_handler(ryu_event)[source]

Handle OFPPortDescStatsReply from datapath.

Parameters:

ryu_event (ryu.controller.ofp_event.EventOFPPortDescStatsReply) – trigger.

port_status_handler(ryu_event)[source]

Handle a port status change event.

Parameters:

ryu_event (ryu.controller.ofp_event.EventOFPPortStatus) – trigger.

reload_config(ryu_event)[source]

Handle a request to reload configuration.

start()[source]

Start controller.

valves_manager = None