API Reference ecs_elixir_core v#1.1.0

Copy Markdown

Modules

Manages configuration for the ECS middleware.

Manages configuration for the ECS middleware.

GenServer that asynchronously dispatches ECS log commands to the Plug use case.

Provides configuration for request, response basic info visibility in logs.

Configuration for the masking feature.

Provides configuration for request visibility in logs.

Provides configuration for request visibility in logs.

Manages sampling feature configuration.

Domain model for a validated and normalized exception before it becomes a log record.

domain struct representing the normalized input to the ECS use case.

ECS-compliant log record. Serialized to JSON and emitted by the infrastructure layer.

Validates field presence and types for a CoreException.

Error message constants for the ECS log build and execution process.

Value object: constants and factory for the default ECS error response.

Value object representing the error section of an ECS log record.

Represents one masking rule configuration.

Validates the structure and values of masking properties.

Parsed sampling ruleset. Provides parsing, building, and lookup of 20x and 40x rules.

Value object for deriving a 2-segment sampling error code from an error type string.

Value object representing a single sampling rule (show_count, skip_count, cycle).

Pure validation logic for sampling rule objects decoded from JSON.

Normalizes the message-id field from any known key variant.

Command object that travels from the entry point to the use case.

Execution context for an ECS Command.

Centralized internal logging for the ECS library.

Plug-specific use case for ECS response logging.

REST-API-specific use case for ECS logging.

Applies basic info visibility rules to log_record.

Applies masking rules to LogRecord attributes based on configuration.

Applies request visibility rules to log_record additionalInfo.

Applies request visibility rules to log_record additionalInfo.

Applies request/response visibility rules to log_record additionalInfo.

Decides whether a LogRecord should be printed or discarded based on sampling rules.

Command-line output adapter for ECS logs. Implements TechToPrint — serializes a LogRecord to JSON and emits it via Logger.

ETS-backed atomic counter for sampling positions, owned by a GenServer.

Plug that logs the outgoing HTTP response using the ECS middleware.

Builds an ECS success payload from a Plug connection response.

REST API entry point — public API of the library.

Builds an error ECS log payload from an exception map and connection.

Builds a success ECS log payload from a connection and response.

Supervisor for the EcsElixirCore application. This supervisor is responsible for starting and supervising the main components of the EcsElixirCore application.