                              (get-paths-from-paths-rollups (first rollups))
                              (sort))]
       (newline)
-      (dorun (map println obsolete-data)))
+      (dorun (map println obsolete-data))))
     (catch Exception e
       (clog/unhandled-error e))))
 


(defn- process-metrics
  "Process metrics."
  [tenant rollups paths cass-hosts pstore options processor-fn & [tpool]]
  (let [tpool (get-thread-pool options tpool)
        mstore (mstore/cassandra-metric-store cass-hosts options)
        processor (processor-fn mstore pstore tpool tenant rollups paths options)
        paths-rollups (mp-get-paths-rollups processor)]
    (try

      (log/info starting-str)
      (log-cli-cmd options)
      (dry-mode-warn options)
      (cp/with-shutdown! [tpool (get-thread-pool options)]
        (let [pstore (pstore/elasticsearch-path-store es-url options)
              sort (get-sort-or-dummy-fn (:sort options))
              processed-data (process-metrics tenant rollups paths cass-hosts
                                              pstore options
                                              remove-obsolete-metrics-processor
                                              tpool)
              obsolete-paths (->> processed-data
                                  (get-paths-from-paths-rollups (first rollups))
                                  (filter #(contains? @paths-info %))
                                  (sort)
                                  (doall))]
          (swap! paths-info (fn [_] nil))
          (process-paths tenant obsolete-paths pstore options
                         remove-obsolete-paths-processor tpool))))
    (catch Exception e
      (clog/unhandled-error e))))

