                   t-type (dispatch-type tweet)]
               (store-published uid _id url-id t-type hids created_at)))]
     (let [tweets (mc/find-maps @db "tweets"
-                               {:created_at {$gt (t/date-time 2014 7 1)
-                                             $lt (t/date-time 2014 10 1)}
+                               {:created_at {$gt (t/date-time 2014 8 1)
+                                             $lt (t/date-time 2014 9 1)}
                                 :user.screen_name {$in news-accounts}})]
       (time
        (doall




  ;; export published news tweets
  (letfn [(dispatch-type [{:keys [entities retweeted_status in_reply_to_status_id]}]
            (if in_reply_to_status_id
              :reply
              (if-not (empty? retweeted_status)
                :retweet
                :source)))
          (transact-published [{:keys [user ]}])]
    (doall
     (let [tweets (mc/find-maps @db "tweets" {:created_at {$gt (t/date-time 2014 7 1)
                                                           $lt (t/date-time 2014 10 1)}
                                              :user.screen_name {$in news-accounts}})]
       (->> tweets
            (pmap #(store-published ))
            aprint))))


  ;; export tmp urls
  (letfn [(x-url [url]
            (let [expanded-url (-> url :url expand-url :url)]

              (do
                (doall (pmap #(when-not (nil? %) (store-mention % pub-id)) user-mentions))
                (store-reaction pub-id source-tid))))]
    (let [retweets (mc/find-maps @db "tweets" {:created_at {$gt (t/date-time 2014 8 1)
                                                            $lt (t/date-time 2014 9 1)}
                                               :retweeted_status {$ne nil}
                                               :user.screen_name {$nin news-accounts}})]
      (time (doall (pmap transact-published retweets)))))



)
