タグ

epollに関するkeyesberryのブックマーク (2)

  • mixi Engineers’ Blog » Linux Programming、epollの話

    お久しぶりです、初めての日の夏に圧倒されているトールマエサカです。 今日はLinuxにおけるネットワークプログラミング関連のネタです。分散データベースサーバの開発過程で最近よくLinuxのepollというイベントハンドリング機能を使っています。これがまた優秀な機能なので紹介します。 このContextでいうイベントハンドラーはサーバがクライエントのリクエストを処理するためのメカニズムです。イベントの感知と通知は大雑把にいうと以下の三つの処理で構成されています: 一つもしくは複数のディスクリプタを監視 ディスクリプタの準備が整うまでハチ公のごとくひたすら待ち続ける 準備が整ったディスクリプタの通知 アプリケーションでの実装は一昔までselect(2)、もしくはpoll(2)というシステムコールで行われていました。二つとも役目は同じですがselect(2)の場合、kernelをいじらない限り

    mixi Engineers’ Blog » Linux Programming、epollの話
  • EventMachine, How Does It Work?

    At this year’s Scottish Ruby Conference, I gave a talk about EventMachine, slides are available. Amidst the hype around Node.js it’s too easy to forget that Ruby has had evented I/O libraries for years. EventMachine, libebb, rev, cool.io, to name a few. As a general introduction I recommend reading Dan Kegel’s article on the C10K problem, the problem of handling 10000 server connections on a singl

  • 1