Liking cljdoc? Tell your friends :D

std.dispatch.board


+counter+clj


add-dependentsclj

(add-dependents m group dependents)

add dependents to a given lookup

(add-dependents {:a #{:d}} :a #{:b :c}) => {:a #{:c :b :d}}

add dependents to a given lookup

(add-dependents {:a #{:d}} :a #{:b :c})
=> {:a #{:c :b :d}}
raw docstring

clear-boardclj

(clear-board {:keys [runtime] :as dispatch} group ticket)

clears the board

(def -ex- (doto (-> (create-dispatch +test-config+)) (submit-board {:id "a"} "t0") (poll-board "a")))

(clear-board -ex- "a" "t0") => {:group "a", :dependent #{"a"}}

clears the board

(def -ex- (doto (-> (create-dispatch +test-config+))
            (submit-board {:id "a"} "t0")
            (poll-board "a")))

(clear-board -ex- "a" "t0")
=> {:group "a", :dependent #{"a"}}
raw docstring

create-dispatchclj

(create-dispatch {:keys [hooks options] :as m})

creates the board executor

creates the board executor
raw docstring

create-dispatch-typecheckclj


get-ticketclj

(get-ticket)

gets a ticket

gets a ticket
raw docstring

new-boardclj

(new-board {:keys [limit]})

creates a new board

(new-board {})

creates a new board

(new-board {})
raw docstring

poll-boardclj

(poll-board {:keys [runtime options] :as dispatch} group)

polls the board for job entry

(def -ex- (doto (create-dispatch +test-config+) (submit-board {:id "a"} "t0")))

(poll-board -ex- "a") => (contains {:groups ["a"], :entry {:id "a"}, :ticket "t0"})

polls the board for job entry

(def -ex- (doto (create-dispatch +test-config+)
            (submit-board {:id "a"} "t0")))

(poll-board -ex- "a")
=> (contains {:groups ["a"], :entry {:id "a"}, :ticket "t0"})
raw docstring

poll-dispatchclj

(poll-dispatch {:keys [handler runtime] :as dispatch} groups)

polls the executor for more work

polls the executor for more work
raw docstring

start-dispatchclj

(start-dispatch dispatch)

starts the board executor

(test-scaffold +scaffold-config+ [[:a :b :c] [:a :b] [:c] [:b :d] [:b :c :d] [:c] [:a] [:b :c] [:c] [:d] [:a]]) => (contains [{:id 0, :groups [:a :b :c]} {:id 2, :groups [:c]} {:id 1, :groups [:a :b]} {:id 3, :groups [:b :d]} {:id 6, :groups [:a]} {:id 10, :groups [:a]} {:id 4, :groups [:b :c :d]} {:id 5, :groups [:c]} {:id 9, :groups [:d]} {:id 7, :groups [:b :c]} {:id 8, :groups [:c]}] :in-any-order)

starts the board executor

(test-scaffold +scaffold-config+
               [[:a :b :c]
                [:a :b]
                [:c]
                [:b :d]
                [:b :c :d]
                [:c]
                [:a]
               [:b :c]
                [:c]
                [:d]
                [:a]])
=> (contains
    [{:id 0,  :groups [:a :b :c]}
     {:id 2,  :groups [:c]}
     {:id 1,  :groups [:a :b]}
     {:id 3,  :groups [:b :d]}
     {:id 6,  :groups [:a]}
     {:id 10, :groups [:a]}
     {:id 4,  :groups [:b :c :d]}
     {:id 5,  :groups [:c]}
     {:id 9,  :groups [:d]}
     {:id 7,  :groups [:b :c]}
     {:id 8,  :groups [:c]}]
    :in-any-order)
raw docstring

stop-dispatchclj

(stop-dispatch dispatch)

stops the board executor

stops the board executor
raw docstring

submit-boardclj

(submit-board dispatch entry)
(submit-board {:keys [runtime options] :as dispatch} entry ticket)

submits an entry to a board

(def -ex- (create-dispatch +test-config+))

(-> -ex- (submit-board {:id "a"} "t0")) => (contains ["t0" ["a"] h/future?])

submits an entry to a board

(def -ex- (create-dispatch +test-config+))

(-> -ex-
    (submit-board {:id "a"} "t0"))
=> (contains ["t0" ["a"] h/future?])
raw docstring

submit-dispatchclj

(submit-dispatch dispatch entry)

submits to the board executor

submits to the board executor
raw docstring

submit-ticketclj

(submit-ticket m groups ticket)

adds ticket to the board

(submit-ticket {} ["a" "b"] "t1") => {"a" ["t1"], "b" ["t1"]}

adds ticket to the board

(submit-ticket {} ["a" "b"] "t1")
=> {"a" ["t1"], "b" ["t1"]}
raw docstring

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

× close