 (ns celestial.workflows
   "Main workflows"
   (:use 
-    [celestial.common :only (get!)]
+    [celestial.common :only (get! import-logging)]
     [clojure.core.strint :only (<<)]
-    [celestial.common :only (slurp-edn)]
-    [taoensso.timbre :only (debug info trace)] 
     [slingshot.slingshot :only  [throw+ try+]]
     [celestial.model :only (vconstruct pconstruct rconstruct)]) 
   (:require ; loading defmethods

  [args workflow event]
  (doseq [[f conf] (get! :hooks)]
    (debug "running hook"  f (resolve f))
    ((resolve- f) (merge args conf {:workflow workflow :event event}))))

(defmacro deflow
  "Defines a basic flow functions with post-success and post-error hooks"

    [celestial.puppet_standalone Standalone]
    [proxmox.provider Container]))

(import-logging)
(defn resolve- [fqn-fn]
  ;(resolve- (first (keys (get-in config [:hooks :post-create]))))
  (let [[n f] (.split (str fqn-fn) "/")] 
