5 ms·
Why Events Are A Bad Idea (for high-concurrency servers)
- prpatel 15y ago"SEDA is a hybrid approach between events and threads, using events between stages and threads within them [17]. This approach is quite similar to the message-passing model discussed by Lauer and Needham [10], though Lauer and Needham advocate a single thread per stage in order to avoid synchronization within a stage. SEDA showed the value of keeping the server in its operating range, which it did by using explicit queues; we agree that the various queues for threads should be visible, as they enable better debugging and scheduling. In addition, the stage boundaries of SEDA provide a form of modularity that simplifies composition in the case of pipelines. When call/return patterns are used, such boundaries require stack ripping and are better implemented with threads using blocking calls." The above is, IMO, the most important quote from the paper. Of course, this paper is from 2003, so I would like to think we have made some progress in understanding events vs/and/or threads, but I don't believe we really have.
- simonw 15y agoPrevious discussions: http://news.ycombinator.com/item?id=1269090 http://news.ycombinator.com/item?id=1269090 http://news.ycombinator.com/item?id=1355309 http://news.ycombinator.com/item?id=1355309 http://news.ycombinator.com/item?id=2907415 http://news.ycombinator.com/item?id=2907415 http://news.ycombinator.com/item?id=2910849 http://news.ycombinator.com/item?id=2910849
- jparise 15y agoThanks. I should have done a more thorough search before submitting this. I was honestly surprised that this particularly link hadn't been posted before, and now we see that this paper has nearly a half-dozen URIs on the same site. Bummer.