锘??xml version="1.0" encoding="utf-8" standalone="yes"?>888av在线,国产一区二区三区久久久,亚洲欧美日韩国产综合精品二区 http://www.aygfsteel.com/Skynet/category/38248.html鍗佷竴闀垮亣 鏁寸悊 www.aygfsteel.com/Good-Game 涓? 鎵撴惉瀹朵簡(jiǎn) ;)zh-cnThu, 26 Mar 2009 04:46:06 GMTThu, 26 Mar 2009 04:46:06 GMT60memcachedb http://www.aygfsteel.com/Skynet/archive/2009/02/26/256836.html鍒樺嚡姣?/dc:creator>鍒樺嚡姣?/author>Thu, 26 Feb 2009 08:23:00 GMThttp://www.aygfsteel.com/Skynet/archive/2009/02/26/256836.htmlhttp://www.aygfsteel.com/Skynet/comments/256836.htmlhttp://www.aygfsteel.com/Skynet/archive/2009/02/26/256836.html#Feedback0http://www.aygfsteel.com/Skynet/comments/commentRss/256836.htmlhttp://www.aygfsteel.com/Skynet/services/trackbacks/256836.html 瀹夎鍙傝冿細(xì)
   http://www.cnblogs.com/cerxp/archive/2008/04/22/1165620.html

鐩稿 memcached 澧炲己鐨勫姛鑳斤細(xì)
  1. 鍧犳満鍚庯紝“緙撳瓨”鍒濆鍖栧洖鍒版柇鐢?shù)鍓?br />   2. 鏀寔鍚屾錛堝彲鐪嬫垚闆嗙兢錛?a id="AjaxHolder_ctl01_TitleUrl" class="postTitle2" >Memcachedb 綆鍗曚嬌鐢?/a>

浠d環(huán)錛?br />   姣?memcached 鎱?15%
鍙傝冿細(xì)http://swik.net/Jabber-linux/Jabber+XMPP+resource/memcachedb%E7%9A%84%E6%80%A7%E8%83%BD%E6%B5%8B%E8%AF%95/b1odq



]]>
Memcached 瀵硅瘽 Google ProtocolBuffers (perl)http://www.aygfsteel.com/Skynet/archive/2009/02/26/256804.html鍒樺嚡姣?/dc:creator>鍒樺嚡姣?/author>Thu, 26 Feb 2009 05:45:00 GMThttp://www.aygfsteel.com/Skynet/archive/2009/02/26/256804.htmlhttp://www.aygfsteel.com/Skynet/comments/256804.htmlhttp://www.aygfsteel.com/Skynet/archive/2009/02/26/256804.html#Feedback0http://www.aygfsteel.com/Skynet/comments/commentRss/256804.htmlhttp://www.aygfsteel.com/Skynet/services/trackbacks/256804.html
  鐪嬬湅鎴戣繖寮?web  緋葷粺鏋舵瀯鍥撅紝閭e氨鐭ラ亾 浣跨敤緇熶竴瀛樺偍鏍煎紡鐨勫ソ澶勪簡(jiǎn)銆?br />   鍦ㄨ繖縐嶇粨鏋勪腑浣犲氨鍗曠函浣跨敤 java 錛屾垨 php 鏌愪竴縐嶅崟涓璇█鎻忚堪鏍煎紡錛屽瓨鍌ㄤ綘闆嗙兢浜や簰鐨勬暟鎹悧錛侊紵浣跨敤ProtocolBuffers 鍚э紝Google 宸茬粡鏈?鐜版垚鐨刟pi鏉ュ府浣犳墿灞曚簡(jiǎn)銆?/strong>

鍙傝冿細(xì)
http://blog.csdn.net/lcj8/archive/2009/02/17/3900157.aspx




     浣滀負(fù) Memcached 灝辨槸涓洪泦緹や嬌鐢紝閭d箞浣滀負(fù)鍦ㄧ紦瀛樺瓨鍌ㄧ殑鏁版嵁鎴戞兂涔熷簲璇ラ傜敤涓庡悇縐嶇幆澧冿紝榪欐椂鍊?鏁版嵁緇撴瀯鍗忚 Google ProtocolBuffers
鍙傝冿細(xì)http://code.google.com/apis/protocolbuffers/docs/overview.html
鍏朵粬璇█錛?/strong>http://code.google.com/p/protobuf/wiki/OtherLanguages
錛堝彲閫傜敤涓庡縐嶈璦錛?br />     javascript 璇誨彇緙撳瓨?shù)腑鐨勬暟鎹?,浣犲彲浠ユ兂璞′笅浣犵殑 web鏈嶅姟寮鍙?鐨勫皢鏉ワ紒錛?br />


鐩墠瀛︿範(fàn)perl 涓?灝卞厛涓婁釜榪欑殑浠g爜錛?br /> 鍙傝冿細(xì)
http://search.cpan.org/~gariev/Google-ProtocolBuffers-0.08/lib/Google/ProtocolBuffers.pm#___top
#!/bin/perl -w
use Cache::Memcached;
use Google::ProtocolBuffers;
#寮鍚?memd
my $memd = new Cache::Memcached{servers => ['10.0.2.15:11211'] };

#澹版槑 緙撳瓨 瀛樺偍 protocol 鏍煎紡
my $key='test';
Google
::ProtocolBuffers->parse("
  message Person{
    required int32 id           =1;
    required string name        =2;
  }
",{create_accessors=>1});

my $data=Person->encode({
  id
=>123,
  name
=>'liukaiyi'
});

#緙撳瓨瀛樺偍
$memd->add($key =>$data,3600);

#######################################################################


my $memd = new Cache::Memcached{servers => ['10.0.2.15:11211'] };
my $person;{
  #浠庣紦瀛樹(shù)腑鍙栧嚭
  
$person = Person->decode($memd->get($key));
}

print $person->id,"-",$person->name;

 


緇撴灉錛?br />   123-liukaiyi




]]>
memcached 浣跨敤錛坧erl錛?/title><link>http://www.aygfsteel.com/Skynet/archive/2009/02/25/256642.html</link><dc:creator>鍒樺嚡姣?/dc:creator><author>鍒樺嚡姣?/author><pubDate>Wed, 25 Feb 2009 08:23:00 GMT</pubDate><guid>http://www.aygfsteel.com/Skynet/archive/2009/02/25/256642.html</guid><wfw:comment>http://www.aygfsteel.com/Skynet/comments/256642.html</wfw:comment><comments>http://www.aygfsteel.com/Skynet/archive/2009/02/25/256642.html#Feedback</comments><slash:comments>0</slash:comments><wfw:commentRss>http://www.aygfsteel.com/Skynet/comments/commentRss/256642.html</wfw:commentRss><trackback:ping>http://www.aygfsteel.com/Skynet/services/trackbacks/256642.html</trackback:ping><description><![CDATA[  <br />   榪欏ぇ浣撲笂鍙互鐪嬪嚭錛屾湇鍔″櫒绔彛緙撳瓨鎶鏈?br /> <br />   memcached 瀹樻柟錛歨ttp://www.danga.com/memcached/<br />   瀹夎鍓嶏紝鍏堝畨瑁?<a >libevent</a><br />   鍏朵笂涓?linux 杞歡涓鑸畨瑁咃紝鐪嬩粬浠瑀eadme鏂囨。 <br />   $>memcached -d -u nobody -m 512 127.0.0.1 -p 11211<br />   <br />   濡傛灉鏈夊紓甯革紝<br />   <strong><span style="color: rgb(53, 24, 255);">ln -s /usr/local/lib/libevent-1.4.so.2 /lib/libevent-1.4.so.2<br />   鍙傝?nbsp; </span></strong>http://blog.chinaunix.net/u2/70049/showart_1665279.html<br /> <strong><span style="color: rgb(53, 24, 255);">  </span></strong>鎴戣繖灝變嬌鐢?<strong>perl</strong> 璇█浜?jiǎn)锛?br />    鍏朵粬璇█鍙傝?http://code.google.com/p/memcached/wiki/Clients<br /> <br />    perl 浣跨敤 cpan> install <span style="color: rgb(0, 0, 0);">Cache</span><span style="color: rgb(0, 0, 0);">::</span><span style="color: rgb(0, 0, 0);">Memcached ;<strong>#浼?xì)鋴社?perl 鎴戝氨涓嶈浜?/strong></span><br /> 浠g爜璇存槑錛氫笉鍋滃 key 涓簍est 鐨勫艱繘琛岄掑   <br /> <div style="border: 1px solid rgb(204, 204, 204); padding: 4px 5px 4px 4px; background-color: rgb(238, 238, 238); font-size: 13px; width: 98%;"><!--<br /> <br /> Code highlighting produced by Actipro CodeHighlighter (freeware)<br /> http://www.CodeHighlighter.com/<br /> <br /> --><span style="color: rgb(0, 128, 0);">#</span><span style="color: rgb(0, 128, 0);">!/bin/perl -w</span><span style="color: rgb(0, 128, 0);"><br /> </span><span style="color: rgb(0, 0, 255);">use</span><span style="color: rgb(0, 0, 0);"> Cache</span><span style="color: rgb(0, 0, 0);">::</span><span style="color: rgb(0, 0, 0);">Memcached;<br /> <br /> </span><span style="color: rgb(0, 0, 255);">my</span><span style="color: rgb(0, 0, 0);"> </span><span style="color: rgb(128, 0, 128);">$memd</span><span style="color: rgb(0, 0, 0);"> </span><span style="color: rgb(0, 0, 0);">=</span><span style="color: rgb(0, 0, 0);"> new Cache</span><span style="color: rgb(0, 0, 0);">::</span><span style="color: rgb(0, 0, 0);">Memcached{servers </span><span style="color: rgb(0, 0, 0);">=></span><span style="color: rgb(0, 0, 0);"> [</span><span style="color: rgb(0, 0, 0); font-weight: bold;">'</span><span style="color: rgb(0, 0, 0); font-weight: bold;">127.0.0.1:11211</span><span style="color: rgb(0, 0, 0); font-weight: bold;">'</span><span style="color: rgb(0, 0, 0);">] };<br /> </span><span style="color: rgb(0, 0, 255);">my</span><span style="color: rgb(0, 0, 0);"> </span><span style="color: rgb(128, 0, 128);">$key</span><span style="color: rgb(0, 0, 0);"> </span><span style="color: rgb(0, 0, 0);">=</span><span style="color: rgb(0, 0, 0);"> </span><span style="color: rgb(0, 0, 0); font-weight: bold;">'</span><span style="color: rgb(0, 0, 0); font-weight: bold;">test</span><span style="color: rgb(0, 0, 0); font-weight: bold;">'</span><span style="color: rgb(0, 0, 0);">;<br /> </span><span style="color: rgb(128, 0, 128);">$memd</span><span style="color: rgb(0, 0, 0);">-></span><span style="color: rgb(0, 0, 0);">add(</span><span style="color: rgb(128, 0, 128);">$key</span><span style="color: rgb(0, 0, 0);"> </span><span style="color: rgb(0, 0, 0);">=></span><span style="color: rgb(0, 0, 0);"> </span><span style="color: rgb(128, 0, 0);">1</span><span style="color: rgb(0, 0, 0);">,</span><span style="color: rgb(128, 0, 0);">3600</span><span style="color: rgb(0, 0, 0);">) or </span><span style="color: rgb(0, 0, 255);">warn</span><span style="color: rgb(0, 0, 0);"> </span><span style="color: rgb(0, 0, 0); font-weight: bold;">'</span><span style="color: rgb(0, 0, 0); font-weight: bold;">Alread added</span><span style="color: rgb(0, 0, 0); font-weight: bold;">'</span><span style="color: rgb(0, 0, 0);">;<br /> </span><span style="color: rgb(0, 0, 255);">while</span><span style="color: rgb(0, 0, 0);">(</span><span style="color: rgb(128, 0, 0);">1</span><span style="color: rgb(0, 0, 0);">){<br />   </span><span style="color: rgb(0, 0, 255);">print</span><span style="color: rgb(0, 0, 0);"> </span><span style="color: rgb(128, 0, 128);">$memd</span><span style="color: rgb(0, 0, 0);">-></span><span style="color: rgb(0, 0, 0);">get(</span><span style="color: rgb(128, 0, 128);">$key</span><span style="color: rgb(0, 0, 0);">)</span><span style="color: rgb(0, 0, 0);">,</span><span style="color: rgb(0, 0, 0); font-weight: bold;">"</span><span style="color: rgb(0, 0, 0); font-weight: bold;">\n</span><span style="color: rgb(0, 0, 0); font-weight: bold;">"</span><span style="color: rgb(0, 0, 0);">;<br />   </span><span style="color: rgb(128, 0, 128);">$memd</span><span style="color: rgb(0, 0, 0);">-></span><span style="color: rgb(0, 0, 0);">incr(</span><span style="color: rgb(128, 0, 128);">$key</span><span style="color: rgb(0, 0, 0);">) or </span><span style="color: rgb(0, 0, 255);">warn</span><span style="color: rgb(0, 0, 0);"> </span><span style="color: rgb(0, 0, 0); font-weight: bold;">'</span><span style="color: rgb(0, 0, 0); font-weight: bold;">FAIL!</span><span style="color: rgb(0, 0, 0); font-weight: bold;">'</span><span style="color: rgb(0, 0, 0);">;<br /> }</span><span style="color: rgb(0, 0, 0);"><br /> </span></div> <strong></strong> <br /> 浣跨敤 telnet 127.0.0.1 11211<br />      $> get  test <br />      VALUE test 0 2<br />      <strong><span style="color: rgb(248, 0, 0);">97</span></strong> <strong>#榪欏氨鏄垜浠掑鐨勫?褰撶劧浣犱嬌鐢ㄤ粈涔堣璦鍙栭兘鏄竴鏍風(fēng)殑 <br /> </strong>     END <br /> <br /> <img src ="http://www.aygfsteel.com/Skynet/aggbug/256642.html" width = "1" height = "1" /><br><br><div align=right><a style="text-decoration:none;" href="http://www.aygfsteel.com/Skynet/" target="_blank">鍒樺嚡姣?/a> 2009-02-25 16:23 <a href="http://www.aygfsteel.com/Skynet/archive/2009/02/25/256642.html#Feedback" target="_blank" style="text-decoration:none;">鍙戣〃璇勮</a></div>]]></description></item></channel></rss> <footer> <div class="friendship-link"> <a href="http://www.aygfsteel.com/" title="狠狠久久亚洲欧美专区_中文字幕亚洲综合久久202_国产精品亚洲第五区在线_日本免费网站视频">狠狠久久亚洲欧美专区_中文字幕亚洲综合久久202_国产精品亚洲第五区在线_日本免费网站视频</a> </div> </footer> 主站蜘蛛池模板: <a href="http://" target="_blank">黄平县</a>| <a href="http://" target="_blank">大安市</a>| <a href="http://" target="_blank">武冈市</a>| <a href="http://" target="_blank">阳泉市</a>| <a href="http://" target="_blank">广丰县</a>| <a href="http://" target="_blank">平泉县</a>| <a href="http://" target="_blank">上蔡县</a>| <a href="http://" target="_blank">南充市</a>| <a href="http://" target="_blank">手游</a>| <a href="http://" target="_blank">伊宁县</a>| <a href="http://" target="_blank">和平县</a>| <a href="http://" target="_blank">英德市</a>| <a href="http://" target="_blank">都匀市</a>| <a href="http://" target="_blank">邯郸市</a>| <a href="http://" target="_blank">闻喜县</a>| <a href="http://" target="_blank">章丘市</a>| <a href="http://" target="_blank">吉安县</a>| <a href="http://" target="_blank">阿拉善盟</a>| <a href="http://" target="_blank">萍乡市</a>| <a href="http://" target="_blank">望奎县</a>| <a href="http://" target="_blank">青铜峡市</a>| <a href="http://" target="_blank">永寿县</a>| <a href="http://" target="_blank">江陵县</a>| <a href="http://" target="_blank">肇东市</a>| <a href="http://" target="_blank">通渭县</a>| <a href="http://" target="_blank">兴义市</a>| <a href="http://" target="_blank">朝阳市</a>| <a href="http://" target="_blank">紫云</a>| <a href="http://" target="_blank">谷城县</a>| <a href="http://" target="_blank">永和县</a>| <a href="http://" target="_blank">漯河市</a>| <a href="http://" target="_blank">甘孜</a>| <a href="http://" target="_blank">苏尼特左旗</a>| <a href="http://" target="_blank">固安县</a>| <a href="http://" target="_blank">张家界市</a>| <a href="http://" target="_blank">体育</a>| <a href="http://" target="_blank">柏乡县</a>| <a href="http://" target="_blank">伊通</a>| <a href="http://" target="_blank">霍邱县</a>| <a href="http://" target="_blank">濉溪县</a>| <a href="http://" target="_blank">光泽县</a>| <script> (function(){ var bp = document.createElement('script'); var curProtocol = window.location.protocol.split(':')[0]; if (curProtocol === 'https') { bp.src = 'https://zz.bdstatic.com/linksubmit/push.js'; } else { bp.src = 'http://push.zhanzhang.baidu.com/push.js'; } var s = document.getElementsByTagName("script")[0]; s.parentNode.insertBefore(bp, s); })(); </script> </body>