lkn-core v0.4.3 Lkn.Core.Pool View Source
A specialized Supervisor which spawns new Map Instance when required.
Link to this section Summary
Functions
Returns a specification to start this module under a supervisor
Register a given Puppeteer to an Instance of a given Map
Spwans a new Instances Pool for a given Lkn.Core.Map
Link to this section Functions
Returns a specification to start this module under a supervisor.
See Supervisor
.
register_puppeteer(Lkn.Core.Map.k(), Lkn.Core.Puppeteer.k(), Lkn.Core.Puppeteer.m()) :: Lkn.Core.Instance.k()
Register a given Puppeteer to an Instance of a given Map.
If required, the Pool will spawn a new Instance, so the Puppeteer do not have to worry about that. The Pool will return the Instance key.
Spwans a new Instances Pool for a given Lkn.Core.Map
.
The Map is expected to be alive before this function is called. After that, it
is possible for a Puppeteer to join an Instance of this Map using
register_puppeteer
.
Note: The Pool lives inside a dedicated Supervisor tree.