Liking cljdoc? Tell your friends :D
Clojure only.

ds-test-tools.core


run-pipelineclj

(run-pipeline inputs outputs body-fn)
(run-pipeline options inputs outputs body-fn)

Run a pipeline. It dumps inputs in temporary files as well as create a temporary directory for the output. It inject them in the config then run a pipeline and collect its outputs.

Simple example:

(defn my-job [conf p] (->> p (ds/read-edn-file (:numbers conf)) (ds/map inc) (ds/write-edn-file (str (:output conf) "/higher.edn"))))

(let [{:keys [result]} (run-pipeline {:numbers [1 2 3 4]} {:result "higher"} my-job)] (println (sort result))) ; '(2 3 4 5)

Run a pipeline. It dumps inputs in temporary files as well as create a
temporary directory for the output. It inject them in the config then run
a pipeline and collect its outputs.


Simple example:

   (defn my-job [conf p]
     (->> p
       (ds/read-edn-file (:numbers conf))
       (ds/map inc)
       (ds/write-edn-file (str (:output conf) "/higher.edn"))))


   (let [{:keys [result]} (run-pipeline
                            {:numbers [1 2 3 4]}
                            {:result "higher"}
                            my-job)]
     (println (sort result))) ; '(2 3 4 5)
sourceraw docstring

cljdoc is a website building & hosting documentation for Clojure/Script libraries

× close