Liking cljdoc? Tell your friends :D

clj-poolman.core


assoc-new-resourceclj

(assoc-new-resource {:keys [resources init] :as pool})

get-resourceclj

(get-resource {:keys [init high resources] :as pool})

Low level resource getting process. Use with-resource macro instead.

Low level resource getting process. Use with-resource macro instead.
raw docstring

mk-poolclj

(mk-pool high low f-init f-close)

Make a mutable resource pool.

Make a mutable resource pool.
raw docstring

mk-pool*clj

(mk-pool* high low f-init f-close)

Make a new resource pool where high for high watermark, low for low watermark, f-init is a function without argument to open a new resource, f-close is a function which take resource as a argument and do something to release the resource, the return value of f-close will be ignored.

Make a new resource pool where high for high watermark, low for low watermark,
f-init is a function without argument to open a new resource,
f-close is a function which take resource as a argument and do something to release the resource,
the return value of f-close will be ignored.
raw docstring

new-resourceclj

(new-resource f-init resources)

Make a new resource of a pool

Make a new resource of a pool
raw docstring

next-idclj

(next-id resources)

Find the next resource id

Find the next resource id
raw docstring

release-resourceclj

(release-resource {:keys [low close resources] :as pool}
                  {res-id :id :as resource})

Low level resource releasing. Use with-resource macro instead.

Low level resource releasing. Use with-resource macro instead.
raw docstring

resource-poolclj


shutdown-poolclj

(shutdown-pool ref-pool)

Shutdown a mutable resource pool

Shutdown a mutable resource pool
raw docstring

shutdown-pool*clj

(shutdown-pool* {:keys [resources close]})

Intenal function, to shutdown a resource pool.

Intenal function, to shutdown a resource pool.
raw docstring

with-resourcecljmacro

(with-resource [res-name ref-pool] & body)

Get a resource from a pool, bind it to res-name, so you can use it in body, after body finish, the resource will be returned to the pool.

Get a resource from a pool, bind it to res-name, so you can use it in body,
after body finish, the resource will be returned to the pool.
raw docstring

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

× close