 
 
 (defn es-listdir
+  "list contents of directory 'parent' in index 'index-name'"
   [index-name parent]
   (esd/search index-name
               ["dir" "doc"]

(ns brainbot.nozzle.esconnect
  (:require [clojure.pprint :refer [pprint]])
  (:require [clojure.string :as string])
  (:require [clojure.tools.logging :as logging])



(defn ensure-index-and-mappings
  "create index with name index-name and make sure the mappings in
mapping-types are used. if the index already exists, just update the
mappings"
  [index-name]
  (if (esi/exists? index-name)
    (doseq [[doctype mapping] mapping-types]
