View Source AbsintheFieldTelemetry.Backend.Batch (absinthe_field_telemetry v0.2.0)

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.

Summary

Functions

Returns a specification to start this module under a supervisor.

Types

@type t() :: %AbsintheFieldTelemetry.Backend.Batch{
  backend: AbsintheFieldTelemetry.Backend.t(),
  field_cache: %{required(atom()) => list()},
  path_cache: %{required(atom()) => list()},
  threshold: integer()
}

Functions

Returns a specification to start this module under a supervisor.

See Supervisor.

@spec start(keyword()) :: :ignore | {:error, any()} | {:ok, pid()}
@spec start_link(keyword()) :: :ignore | {:error, any()} | {:ok, pid()}
@spec stop() :: any()