diff options
| author | Scott Ostler <scottbot9000@gmail.com> | 2011-02-23 22:03:01 -0500 |
|---|---|---|
| committer | Scott Ostler <scottbot9000@gmail.com> | 2011-02-23 22:03:01 -0500 |
| commit | be6f1bcca3424b0dd6dc3cba7adbe06ebeacceda (patch) | |
| tree | dadfec94863aa4c99cef8f4caab0907a56274fe7 /src | |
| parent | 9522d729741a49d609cf141e7338f869d056b284 (diff) | |
| parent | 81f51f9f0ea6abd3d18bed4e9880237e06998ef7 (diff) | |
Merge branch 'master' of ssh://dump.fm/pichat/repo
Diffstat (limited to 'src')
| -rw-r--r-- | src/redisload.clj | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/src/redisload.clj b/src/redisload.clj index 15ca299..c08cb32 100644 --- a/src/redisload.clj +++ b/src/redisload.clj @@ -153,17 +153,18 @@ WHERE (defn build-daily-hall [dt] (let [top-posts (get-top-posts dt 20) datekey (redis-daily-hall-key dt)] - (println (count top-posts) "posts for" datekey) + (println (count top-posts) "posts for" datekey ", top with" (:score (first top-posts))) (redis/with-server redis-server (redis/atomically - ;(redis/del datekey) + (redis/del datekey) (doseq [m top-posts] (println (:nick m) (:message_id m) (:score m)) - ;(redis/zadd datekey (:score m) (:message_id m)) + (redis/zadd datekey (:score m) (:message_id m)) ))))) (defn build-all-daily-hall [] (doseq [dt (get-fav-date-range)] (build-daily-hall dt))) -(build-daily-hall (parse-yyyy-mm-dd-date "2010-05-30"))
\ No newline at end of file +;(build-daily-hall (parse-yyyy-mm-dd-date "2010-05-30")) +;(build-all-daily-hall) |
