摘要: //测试分布式算法 $ports = array('端口1', '端口2', '端口3', '端口4', '端口5'); //Memcache端口 $users = array('1000', '1001', '1002', '1004', '9803'); //登录用户 foreach ($users as $u){ $crc = crc32($u); $mod = abs($crc % count($ports)); echo &q 阅读全文
posted @ 2014-03-21 09:41 王翔(kingfly) 阅读(672) 评论(0) 推荐(0) 编辑