LogModule
PackageAxial.PlatformService
Helpers for the logging service.
Summary
| Name | Signature | Synopsis |
|---|---|---|
| service | Log.service | Reads the service from the environment. |
| log | Log.log level message | Writes a log message at the requested level through an explicit logging service. |
| trace | Log.trace message | Writes a trace log message through an explicit logging service. |
| debug | Log.debug message | Writes a debug log message through an explicit logging service. |
| info | Log.info message | Writes an informational log message through an explicit logging service. |
| warning | Log.warning message | Writes a warning log message through an explicit logging service. |
| error | Log.error message | Writes an error log message through an explicit logging service. |
| critical | Log.critical message | Writes a critical log message through an explicit logging service. |
| logException | Log.logException level error message | Writes a log message carrying an exception through an explicit logging service. |
| errorExn | Log.errorExn error message | Writes an error log message carrying an exception through an explicit logging service. |
| criticalExn | Log.criticalExn error message | Writes a critical log message carrying an exception through an explicit logging service. |
| live | Log.live | Creates a no-op logger for tests and local service bundles. |
| fromSink | Log.fromSink sink | Creates a logger from a synchronous sink function. |
| layer | Log.layer | Builds the live logger as a layer. |
Writes a log message at the requested level through an explicit logging service.
Parameters
| Name | Type | Description |
|---|---|---|
| level | LogLevel | |
| message | string |
Returns
Flow<'env, 'error, unit>
Writes a trace log message through an explicit logging service.
Parameters
| Name | Type | Description |
|---|---|---|
| message | string |
Returns
Flow<'env, 'error, unit>
Writes a debug log message through an explicit logging service.
Parameters
| Name | Type | Description |
|---|---|---|
| message | string |
Returns
Flow<'env, 'error, unit>
Writes an informational log message through an explicit logging service.
Parameters
| Name | Type | Description |
|---|---|---|
| message | string |
Returns
Flow<'env, 'error, unit>
Writes a warning log message through an explicit logging service.
Parameters
| Name | Type | Description |
|---|---|---|
| message | string |
Returns
Flow<'env, 'error, unit>
Writes an error log message through an explicit logging service.
Parameters
| Name | Type | Description |
|---|---|---|
| message | string |
Returns
Flow<'env, 'error, unit>
Writes a critical log message through an explicit logging service.
Parameters
| Name | Type | Description |
|---|---|---|
| message | string |
Returns
Flow<'env, 'error, unit>
Writes a log message carrying an exception through an explicit logging service.
Parameters
| Name | Type | Description |
|---|---|---|
| level | LogLevel | |
| error | exn | |
| message | string |
Returns
Flow<'env, 'error, unit>
Writes an error log message carrying an exception through an explicit logging service.
Parameters
| Name | Type | Description |
|---|---|---|
| error | exn | |
| message | string |
Returns
Flow<'env, 'error, unit>
Writes a critical log message carrying an exception through an explicit logging service.
Parameters
| Name | Type | Description |
|---|---|---|
| error | exn | |
| message | string |
Returns
Flow<'env, 'error, unit>
Creates a logger from a synchronous sink function. Exceptions are appended to the message text.
Parameters
| Name | Type | Description |
|---|---|---|
| sink | LogLevel -> string -> unit |
Returns
ILog

