Liking cljdoc? Tell your friends :D

promesa.exec

Executors & Schedulers facilities.

Executors & Schedulers facilities.
raw docstring

*default-executor*clj/s

source

*default-scheduler*clj/s

source

*thread-executor*clj/s

source

*vthread-executor*clj/s

source

cached-executorclj

(cached-executor & {:keys [factory]})

A cached thread executor pool constructor.

A cached thread executor pool constructor.
sourceraw docstring

cached-poolcljdeprecated

(cached-pool)
(cached-pool opts)

A cached thread pool constructor.

A cached thread pool constructor.
sourceraw docstring

concurrency-limiterclj

(concurrency-limiter &
                     {:keys [executor concurrency queue-size on-run on-queue]
                      :or {concurrency 1 queue-size Integer/MAX_VALUE}})

Create an instance of concurrencly limiter. EXPERIMENTAL

Create an instance of concurrencly limiter. EXPERIMENTAL
sourceraw docstring

configure-default-executor!clj

(configure-default-executor! & params)
source

counterclj

source

default-forkjoin-thread-factoryclj

(default-forkjoin-thread-factory &
                                 {:keys [name daemon]
                                  :or {name "promesa/forkjoin/%s" daemon true}})
source

default-thread-factoryclj

(default-thread-factory
  &
  {:keys [name daemon priority]
   :or {daemon true priority Thread/NORM_PRIORITY name "promesa/thread/%s"}})
source

executor?clj/s

(executor? o)
source

fixed-executorclj

(fixed-executor & {:keys [parallelism factory]})

A fixed thread executor pool constructor.

A fixed thread executor pool constructor.
sourceraw docstring

fixed-poolcljdeprecated

(fixed-pool n)
(fixed-pool n opts)

A fixed thread pool constructor.

A fixed thread pool constructor.
sourceraw docstring

forkjoin-executorclj

(forkjoin-executor & {:keys [factory async? parallelism] :or {async? true}})
source

forkjoin-poolcljdeprecated

(forkjoin-pool {:keys [factory async? parallelism] :or {async? true} :as opts})
source

noopclj/s

source

resolve-executorclj/s

(resolve-executor)
(resolve-executor executor)
source

resolve-schedulerclj/s

(resolve-scheduler)
(resolve-scheduler scheduler)
source

run!clj/s

(run! f)
(run! executor f)

Run the task in the provided executor.

Run the task in the provided executor.
sourceraw docstring

same-thread-executorclj/s

source

schedule!clj/s

(schedule! ms f)
(schedule! scheduler ms f)

Schedule a callable to be executed after the ms delay is reached.

In JVM it uses a scheduled executor service and in JS it uses the setTimeout function.

Schedule a callable to be executed after the `ms` delay
is reached.

In JVM it uses a scheduled executor service and in JS
it uses the `setTimeout` function.
sourceraw docstring

scheduled-executorclj

(scheduled-executor & {:keys [parallelism factory] :or {parallelism 1}})

A scheduled thread pool constructor.

A scheduled thread pool constructor.
sourceraw docstring

scheduled-poolcljdeprecated

(scheduled-pool)
(scheduled-pool n)
(scheduled-pool n opts)

A scheduled thread pool constructor.

A scheduled thread pool constructor.
sourceraw docstring

single-executorclj

(single-executor & {:keys [factory]})

A single thread executor pool constructor.

A single thread executor pool constructor.
sourceraw docstring

single-poolcljdeprecated

(single-pool)
(single-pool opts)

A single thread pool constructor.

A single thread pool constructor.
sourceraw docstring

submit!clj/s

(submit! f)
(submit! executor f)

Submit a task to be executed in a provided executor and return a promise that will be completed with the return value of a task.

A task is a plain clojure function.

Submit a task to be executed in a provided executor
and return a promise that will be completed with
the return value of a task.

A task is a plain clojure function.
sourceraw docstring

thread-factory?clj

(thread-factory? o)
source

vthreads-supported?clj/s

source

with-dispatchclj/smacro

(with-dispatch executor & body)

Helper macro for dispatch execution of the body to an executor service. The returned promise is not cancellable (the body will be executed independently of the cancellation).

Helper macro for dispatch execution of the body to an executor
service. The returned promise is not cancellable (the body will be
executed independently of the cancellation).
sourceraw docstring

work-stealing-executorclj

(work-stealing-executor & params)

An alias for the forkjoin-executor.

An alias for the `forkjoin-executor`.
sourceraw docstring

work-stealing-poolcljdeprecated

(work-stealing-pool)
(work-stealing-pool n)

Creates a work-stealing thread pool.

Creates a work-stealing thread pool.
sourceraw docstring

wrap-bindingsclj/s

(wrap-bindings f)
source

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

× close