ex_flux v0.1.0 ExFlux.Database.Supervisor View Source
Orchestration and supervision of ex_influx database components
The two components of an ex_influx database process: a “sliding buffer” queue,
ExFlux.Database.QueueWorker
, and a pool of connections to the influxdb
server, ExFlux.Database.PoolWorker
.
The options required by the queue are:
:database
- the name of the database:batch_size
- an upper limit on the number of points to send at once:max_queue_size
- a limit to the number of points to attempt to hold if the data cannot be shipped to influxdb fast enough:flush_interval
- a time interval in seconds used to help drain the queue
The options required by the pool are:
:database
- the name of the database:pool_size
- the number of connections/workers to maintain (via:poolboy
):pool_overflow
- if set to a number > 0, this allows poolboy to create extra workers when the demand for workers exceeds the supply:upd_conn_opts
- a list of one or more UDP connection options required by:gen_udp
, defaults to[:binary, {:active, false}]
since we are exclusively writing:host
- hostname of the influxdb server:port
- the port number influxdb is listening on for this particular database
Link to this section Summary
Functions
Merge the config and defaults to create a single cohesive configuration map to be used by the pool worker, poolboy, and the queue worker
Link to this section Types
Link to this section Functions
Merge the config and defaults to create a single cohesive configuration map to be used by the pool worker, poolboy, and the queue worker.