Module leo_pod

API of leo_pod.

References

Description

API of leo_pod

Function Index

checkin/2Checkin the worker into the worker pool.
checkin_async/2Checkin the worker into the worker pool assynchronously.
checkout/1Checkout a worker from the worker pool.
start_link/6Initialize a work pool.
status/1Get the status of the worker pool.
stop/1Stop the worker pool.

Function Details

checkin/2

checkin(PodName, Worker) -> ok

Checkin the worker into the worker pool.

checkin_async/2

checkin_async(PodName, Worker) -> ok

Checkin the worker into the worker pool assynchronously.

checkout/1

checkout(PodName) -> {ok, pid()}

Checkout a worker from the worker pool.

start_link/6

start_link(PodName, PodSize, MaxOverflow, WorkerMod, WorkerArgs, InitFun) -> {ok, pid()}

Initialize a work pool.

status/1

status(PodName) -> {ok, {NumOfWorking, NumOfWating, NumOfRoomForOverflow}}

Get the status of the worker pool. It returns the tuple of the numbers of working_processes, waiting processes, and room of overflow.

stop/1

stop(PodName) -> true | not_started

Stop the worker pool.


Generated by EDoc