ErrorLogHandler implements ErrorHandler
Read onlyYes
FinalYes
Default ErrorHandler. Writes formatted Throwables via PHP's error_log() — stderr in CLI by default, or the error_log ini setting otherwise.
Matches the OTEL spec recommendation to "log to standard error output".
Interfaces
- ErrorHandler
- Receives Throwables raised inside the SDK at runtime.
Methods
- __construct() : mixed
- handle() : void
Methods
__construct()
public
__construct([ErrorLogMessageType $messageType = ErrorLogMessageType::OperatingSystem ][, bool $expandNewlines = false ][, string $messagePrefix = '[flow-telemetry]' ]) : mixed
Parameters
- $messageType : ErrorLogMessageType = ErrorLogMessageType::OperatingSystem
- $expandNewlines : bool = false
- $messagePrefix : string = '[flow-telemetry]'
handle()
public
handle(Throwable $error) : void
Parameters
- $error : Throwable