                              :or {wait 500}}]
    (let [keep-watching? (atom true)
          f (future 
-             (println "Watching" watch "for changes")
+             (debug-do (println "Watching" watch "for changes"))
              (loop [last-value {}]
                (let [latest (watch-fn)]
                  (if (and (not= last-value {})

            [clojure.core.async :refer [go chan close! timeout <!! >!! <! >!]]
            [clj-ravendb.responses :as res]))

(def not-nil? (complement nil?))

(defn- post-req
  [{:keys [url body]}]
  (println "Sending HTTP POST to" url "with JSON body " body)
  (client/post url {:body body :as :json-string-keys}))

(defn- put-req
  [{:keys [url body]}]
  (println "Sending HTTP PUT to" url "with JSON body " body)
  (client/put url {:body body :as :json-string-keys}))

(defn- get-req
  [{:keys [url]}]
  (println "Sending HTTP GET to" url)
  (client/get url {:as :json-string-keys}))

(defn- is-valid-client?

    (let [response (try
                     (handle (merge {:url (first urls)} request)) 
                     (catch java.net.ConnectException ce 
                       (debug-do (println "Failed to execute request using " (first urls)))))]
      (if (not (nil? response))
        response
        (recur (rest urls))))))   
