Hi Yiwen,

IIRC, "EVENT LOST" messages will be output when the receiver application name 
of the event
could not be found in "SERVICE_BRICKS" dictionary.

"SERVICE_BRICKS" stores the receiver application name to the event sender 
application.
e.g.) simple_switch_13.py

SERVICE_BRICKS={'SimpleSwitch13': <simple_switch_13.SimpleSwitch13 object at 
0x7f7885871400>,
'ofp_event': <ryu.controller.ofp_handler.OFPHandler object at 0x7f7885875128>}

This means "SimpleSwitch13" is a observer for the events generated by 
"ofp_event".


FYI:
When I faced the same problem (I couldn't receive events at all though), I 
could solve it
with adding the events into "_EVENTS" list in the event "sender" application.
  
https://github.com/osrg/ryu/blob/master/ryu/services/protocols/bgp/application.py#L180-L184
The following means "RyuBGPSpeaker" will generate "EventBestPathChanged", 
"EventPeerDown"
and "EventPeerUp" for the observer applications.


Thanks,
Iwase

On 2017年02月13日 13:59, Yiwen Shen wrote:
> Hi, 
> 
> Yes I mean the debug log message that says EVENT LOST when I use the 
> --verbose option. 
> 
> My code has a traffic request arrive and this causes events to be sent 
> between different apps to handle this request. The issue I'm facing is that 
> sometimes I get the event lost message so the code doesn't finish to the end, 
> but other times it does. This means that the event handler works and the code 
> is correct, but somehow something is causing the events to be lost 
> occasionally. Now, if I have many events in succession, then there's a higher 
> chance for the code to fail because one of the events gets lost. 
> 
> So I'm wondering if you might know anything like timing or some other reason 
> that might cause this to happen. I'm running the code on an Ubuntu system, 
> and also tried it on Cygwin. 
> 
> Thank you, 
> Yiwen 
> 
> On Feb 12, 2017 11:01 PM, "Iwase Yusuke" <[email protected] 
> <mailto:[email protected]>> wrote:
> 
>     Hi Yiwen,
> 
>     What does "lost" exactly mean?
> 
>     You mean:
>     - Getting the following debug log message when some events occurred.
>       
> https://github.com/osrg/ryu/blob/master/ryu/base/app_manager.py#L317-L318 
> <https://github.com/osrg/ryu/blob/master/ryu/base/app_manager.py#L317-L318>
>     - Your event handler was not called when interested events occurred.
>     or else?
> 
>     Thanks,
>     Iwase
> 
> 
>     On 2017年02月11日 07:06, Yiwen Shen wrote:
>     > Hi,
>     >
>     > In my system, I am using send_event to send events around some Ryu apps 
> and each time I run it, sometimes the events succeed but most of the time one 
> of the events are lost. I have tried using hub.sleep(1) at the beginning but 
> it doesn't make it any better. 80% of the time the code cannot reach the end 
> because one of the events are lost.
>     >
>     > Thank you,
>     > Yiwen
>     >
>     >
>     > 
> ------------------------------------------------------------------------------
>     > Check out the vibrant tech community on one of the world's most
>     > engaging tech sites, SlashDot.org! http://sdm.link/slashdot
>     >
>     >
>     >
>     > _______________________________________________
>     > Ryu-devel mailing list
>     > [email protected] <mailto:[email protected]>
>     > https://lists.sourceforge.net/lists/listinfo/ryu-devel 
> <https://lists.sourceforge.net/lists/listinfo/ryu-devel>
>     >
> 
> 
> 
> 
> ------------------------------------------------------------------------------
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, SlashDot.org! http://sdm.link/slashdot
> 
> 
> 
> _______________________________________________
> Ryu-devel mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/ryu-devel
> 

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
_______________________________________________
Ryu-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/ryu-devel

Reply via email to