View Source AbsintheFieldTelemetry.Backend.Batch (absinthe_field_telemetry v0.2.5)
This implementation of the backend is provided to be a wrapper around another backend.
The idea related to this backend is that it will cache field and path hits
in memory and then report them in batches of size threshold
the other
backend.
This is designed to improve performance and throughput when a backend requires a network call.
The backend process is started by calling start_link
:
AbsintheFieldTelemetry.Backend.Batch.start_link(
threshold: 10_000,
interval_ms: 60_000 * 10,
backend: {AbsintheFieldTelemetry.Backend.Ets, []}
)
Options are:
interval_ms
: If set, this backend will report all unreported cached hits everyinterval_ms
.threshold
: The number of hits to cash before reporting the backend (required)backend
: The persistence backend (required)
Summary
Functions
Returns a specification to start this module under a supervisor.
Types
Functions
Returns a specification to start this module under a supervisor.
See Supervisor
.
@spec stop() :: any()