             [clojure.string :as str]
             [clojure.tools.logging :as log]
             [clojure.walk :as walk]
+            [cook.cached-queries :as cached-queries]
             [cook.config :as config]
             [cook.kubernetes.metrics :as metrics]
-            [cook.pool :as pool]
             [cook.regexp-tools :as regexp-tools]
             [cook.scheduler.constraints :as constraints]
             [cook.task :as task]

        {:keys [docker volumes]} container
        {:keys [image parameters port-mapping]} docker
        {:keys [environment]} command
        pool-name (some-> job :job/pool :pool/name)
        ; gpu count is not stored in scalar-requests because Fenzo does not handle gpus in binpacking
        gpus (or (:gpus resources) 0)
        gpu-model-requested (constraints/job->gpu-model-requested gpus job pool-name)

    (.setRestartPolicy pod-spec "Never")

    (.addTolerationsItem pod-spec toleration-for-deletion-candidate-of-autoscaler)
    (.addTolerationsItem pod-spec (toleration-for-pool cook-pool-taint-name cook-pool-taint-prefix pool-name))
    ; We need to make sure synthetic pods --- which don't have a hostname set --- have a node selector
    ; to run only in nodes labelled with the appropriate cook pool
    (when-not hostname (add-node-selector pod-spec cook-pool-label-name pool-name))

    (when pod-constraints
      (doseq [{:keys [constraint/attribute
