DEBUG messages in RYU OpenFlow controller

Tag: python , python-2.7 , networking , openflow Author: qwx3473 Date: 2014-04-23

I have tried using "self.logger.debug" to print messages inside the following functions.

1) ryu/topology/api.py 
                   - get_all_switch()    [https://github.com/karthik82/ryu/blob/master/ryu/topology/api.py#L27][link here]

                   - get_all_link()        [https://github.com/karthik82/ryu/blob/master/ryu/topology/api.py#L38][link here]


2) ryu/topology/switches.py

                   - switch_request_handler()  [https://github.com/karthik82/ryu/blob/master/ryu/topology/switches.py#L840][link here]

                   - link_request_handler()      [https://github.com/karthik82/ryu/blob/master/ryu/topology/switches.py#L856][link here] 

As per my understanding switch_request_handler() and link_request_handler() handles the messages EventLinkRequest and EventSwitchRequest sent by (1)

I am calling 
               - get_all_switch() 
               - get_all_link() 

from https://github.com/karthik82/ryu/blob/master/ryu/app/simple_switch.py#L53
and  https://github.com/karthik82/ryu/blob/master/ryu/app/simple_switch.py#L57

from packet_in handler of simple_switch.py

My question is

I CAN see debug messages from get_all_switch() and get_all_link() I CANNOT see debug messages from switch_request_handler() and link_request_handler() - WHY???

Below I can see get_all_switch - sending EventSwitchRequest() get_all_link - sending EventLinkRequest()

But I CANNOT see debug messages from switch_request_handler() and link_request_handler()

Partial trace.

get_all_switch
EVENT SimpleSwitch->switches EventSwitchRequest
get_all_link
EVENT SimpleSwitch->switches EventLinkRequest
EVENT ofp_event->switches EventOFPPacketIn
EVENT ofp_event->SimpleSwitch EventOFPPacketIn
get_all_switch
EVENT SimpleSwitch->switches EventSwitchRequest
get_all_link
EVENT SimpleSwitch->switches EventLinkRequest