Skynet

          ---------- ---------- 我的新 blog : liukaiyi.cublog.cn ---------- ----------

            BlogJava :: 首頁 :: 聯系 :: 聚合  :: 管理
            112 Posts :: 1 Stories :: 49 Comments :: 0 Trackbacks

          首先 好東西
            http://kr.github.com/beanstalkd/


          其次 真的是好東西 支持 java , python ,perl,ruby,erlang 和我不知道的 語言
            官方的原文介紹:
          $ ./beanstalkd -d -l 10.0.1.5 -p 11300

          This starts up beanstalkd as a daemon listening on address 10.0.1.5, port 11300.

          Use It

          Here’s an example in Ruby (see the client libraries to find your favorite language).

          First, have one process put a job into the queue:

          beanstalk = Beanstalk::Pool.new(['10.0.1.5:11300'])

          beanstalk.put('hello')

          Then start another process to take jobs out of the queue and run them:

          beanstalk = Beanstalk::Pool.new(['10.0.1.5:11300'])

          loop do

          job = beanstalk.reserve

          puts job.body # prints "hello"

          job.delete

          end





          Thanks

          Many thanks to memcached for providing inspiration for simple protocol design and for the structure of the documentation. Not to mention a fantastic piece of software!




          整理 www.aygfsteel.com/Good-Game
          posted on 2009-10-28 19:21 劉凱毅 閱讀(2395) 評論(0)  編輯  收藏 所屬分類: python集群開發 、消息隊列
          主站蜘蛛池模板: 疏附县| 新干县| 西充县| 秦皇岛市| 白沙| 将乐县| 简阳市| 吉林市| 佛冈县| 新龙县| 高清| 长治县| 太仆寺旗| 东乡县| 新沂市| 沁源县| 沙河市| 凤山市| 新源县| 邵阳市| 佛冈县| 阿城市| 楚雄市| 遂川县| 灵石县| 自治县| 南通市| 德钦县| 武平县| 来宾市| 马边| 长岭县| 十堰市| 泰宁县| 保靖县| 汶川县| 岚皋县| 房产| 台中市| 铁力市| 天柱县|