V2EX = way to explore
V2EX 是一个关于分享和探索的地方
现在注册
已注册用户请  登录
推荐学习书目
Learn Python the Hard Way
Python Sites
PyPI - Python Package Index
http://diveintopython.org/toc/index.html
Pocoo
值得关注的项目
PyPy
Celery
Jinja2
Read the Docs
gevent
pyenv
virtualenv
Stackless Python
Beautiful Soup
结巴中文分词
Green Unicorn
Sentry
Shovel
Pyflakes
pytest
Python 编程
pep8 Checker
Styles
PEP 8
Google Python Style Guide
Code Style from The Hitchhiker's Guide
wingyiu
V2EX  ›  Python

reddit 的排名算法具体是怎么实现的,每次全部 load 入计算再分页?

  •  
  •   wingyiu · 2015-01-21 23:12:57 +08:00 · 3432 次点击
    这是一个创建于 3372 天前的主题,其中的信息可能已经有所发展或是发生改变。
    不要说_sorts.pyx,可以确定不是sql实现的。代码略复杂,看了许久也没看清具体的实现细节。求解答。
    第 1 条附言  ·  2015-01-22 00:11:21 +08:00
    我问的是工程实现,不是算法原理。
    7 条回复    2015-01-22 12:44:16 +08:00
    octoberzhu
        1
    octoberzhu  
       2015-01-21 23:42:13 +08:00
    google搜一大堆相关文章啊lz
    wingyiu
        2
    wingyiu  
    OP
       2015-01-21 23:46:30 +08:00
    @octoberzhu 来一个?
    wingyiu
        4
    wingyiu  
    OP
       2015-01-22 00:07:53 +08:00
    @octoberzhu 。。。。我问的不是算法的数学原理,早看过了。
    omegaga
        5
    omegaga  
       2015-01-22 12:21:24 +08:00
    哪里可以确定不是SQL实现的……人家wiki写的很清楚了,他在PostgreSQL上搞了一个ThingDB模型(类似key/value store)来存储文章、评论、用户等信息。然后,reddit用了Cassandra做了Cache。
    wingyiu
        6
    wingyiu  
    OP
       2015-01-22 12:33:47 +08:00
    @omegaga 求链接
    omegaga
        7
    omegaga  
       2015-01-22 12:44:16 +08:00
    @wingyiu https://github.com/reddit/reddit/wiki/Architecture-Overview
    然后r2/r2/model/和r2/r2/lib/db/的代码里有不少关于这部分内容的,没仔细看
    关于   ·   帮助文档   ·   博客   ·   API   ·   FAQ   ·   我们的愿景   ·   实用小工具   ·   4619 人在线   最高记录 6543   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 29ms · UTC 10:09 · PVG 18:09 · LAX 03:09 · JFK 06:09
    Developed with CodeLauncher
    ♥ Do have faith in what you're doing.