Iwamoto-San,

My responses are inline.

On Feb 10, 2016, at 3:00 AM, IWAMOTO Toshihiro <[email protected]> wrote:
<snip/>
>> +        self._events_sem = hub.BoundedSemaphore(self.events.maxsize)
>> +        self._sc_events_sem = hub.BoundedSemaphore(self.sc_events.maxsize)
>> +        self._pi_events_sem = hub.BoundedSemaphore(self.pi_events.maxsize)
> 
> Do we really need these semaphores?
> eventlet.queue.Queue.put should block if a queue is full.
> 

Yes, we do.
The queues *should block*, but do not always do so.
I have discovered, in our testing environment, that eventlet synchronized 
queues have missed wakeup problems under heavy load.

This is a bug in eventlet's synchronized queues, for which I intend to submit a 
patch in the near-ish future - and that I am working around with these 
semaphores (which I have verified to not suffer from the same missed wakeup 
problems).

<snip/>
>>    def _event_loop(self):
>>        while self.is_active or not self.events.empty():
> 
> If pi_events (or sc_events) isn't empty but events is empty,
> pi_events doesn't seem to be processed.  Correct?
> 

Good catch; I will fix this.

>> -            ev, state = self.events.get()
>> -            if ev == self._event_stop:
>> +            # Process events according to priority.
>> +            # StatusChange highest, PacketIn lowest, all others in between.
>> +            ev = state = None
>> +            if self.sc_events.qsize():
> 
> Just a nit, but it seems to be better to use empty() instead of
> qsize() for consistency.
> 

Eh - I guess that "if not $queue.empty()" might be more clear.
I'll make the change.

Thanks!

Best,
Victor
--
Victor J. Orlikowski <> vjo@[cs.]duke.edu


------------------------------------------------------------------------------
Site24x7 APM Insight: Get Deep Visibility into Application Performance
APM + Mobile APM + RUM: Monitor 3 App instances at just $35/Month
Monitor end-to-end web transactions and take corrective actions now
Troubleshoot faster and improve end-user experience. Signup Now!
http://pubads.g.doubleclick.net/gampad/clk?id=272487151&iu=/4140
_______________________________________________
Ryu-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/ryu-devel

Reply via email to