Skip to content

johninvictus/pool

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Pooly

A poolboy concept application

It for learning purpose

Here is the supervision tree,

Image

The example pool config

pool_config = [
      [name: "Pool1", mfa: {Pooly.SampleWorker, :start_link, [[]]}, size: 5],
      [name: "Pool2", mfa: {Pooly.SampleWorker, :start_link, [[]]}, size: 3],
      [name: "Pool3", mfa: {Pooly.SampleWorker, :start_link, [[]]}, size: 4]
    ]

Usage

Checkout a process

iex> Pooly.checkout(pool_name)

Return/checkin a process

iex> Pooly.checkin(pool_name, process_pid)

Get the current state of a pool

iex> Pooly.status(pool_name)

About

Pool Supervision tree

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages