             [plumbing.core :refer (map-vals map-keys map-from-vals)])
   (:import org.apache.curator.framework.CuratorFrameworkFactory
            org.apache.curator.framework.state.ConnectionStateListener
-           org.apache.curator.retry.BoundedExponentialBackoffRetry)
+           org.apache.curator.retry.BoundedExponentialBackoffRetry
+           org.joda.time.DateTimeUtils)
   (:gen-class))
 
 ;;; This namespace contains a simulator for cook scheduler that accepts a trace file

            [clojure.data.csv :as csv]
            [clojure.data.json :as json]
            [clojure.java.io :as io]
            [clojure.tools.cli :refer  [parse-opts]]
            [clojure.tools.logging :as log]
            [clojure.walk :refer (keywordize-keys)]
            [com.rpl.specter :refer (transform ALL MAP-VALS MAP-KEYS select FIRST)]

            (when (seq trace)
              (recur (drop (count submission-batch) trace)
                     (+ simulation-time cycle-step-ms)
                     (if (> time-ms-since-last-rebalancer time-ms-between-rebalancing)
                       0
                       (+ time-ms-since-last-rebalancer cycle-step-ms))
                     (if (> time-ms-since-last-optimizer-call time-ms-between-optimizer-calls)
                       0
                       (+ time-ms-since-last-optimizer-call cycle-step-ms))))))
        (println "count of jobs submitted " (count (d/q '[:find ?e
                                                          :where
                                                          [?e :job/uuid _]]
