   (str stormroot "/" RESOURCES-SUBDIR))
 
 (defn ^LocalState supervisor-state [conf]
-  (LocalState. (str (conf STORM-LOCAL-DIR) "/localstate")))
+  (LocalState. (str (supervisor-local-dir conf) "/localstate")))
 
 
 (defn worker-root

  (str stormroot "/stormconf.ser"))

(defn supervisor-tmp-dir [conf]
  (let [ret (str (conf STORM-LOCAL-DIR) "/tmp")]
    (FileUtils/forceMkdir (File. ret))
    ret ))


(defn read-yaml-config [name]
  (clojurify-structure (Utils/findAndReadConfigFile name true)))

(defn master-local-dir [conf]
  (let [ret (str (conf STORM-LOCAL-DIR) "/nimbus")]
    (FileUtils/forceMkdir (File. ret))
    ret
    ))

(defn master-stormdist-root [conf storm-id]
  (str (master-local-dir conf) "/stormdist/" storm-id))

(defn master-stormjar-path [stormroot]
  (str stormroot "/stormjar.jar"))
