Observability

Observability allows the FintechOS Platform to generate log events and push those logs to various destinations such as system consoles, files, log servers, or Application Performance Management (APM) services.

Send log messages to the system console

Configuration in the Configuration Manager:

Key Path Key Name Key Value
kv/<environment>/<application>/app-settings console-logging enabled=0; logLevel=Debug;
 
Parameter Description
enabled
  • 0 - disable console logging
  • 1 - enable console logging
logLevel Minimum severity level for the logged messages. Available options are: Verbose, Debug, Info, Warning, Error, and Fatal.

 

 

Send log messages to local file storage

Configuration in the Configuration Manager:

Key Path Key Name Key Value
kv/<environment>/<application>/app-settings file-logging enabled=1; logLevel=Debug; flushInterval=1s; fileName=trace_roll_.log; retainedFileCount=99; rollSizeBytes=31457280;
 
Parameter Description
enabled
  • 0 - disable file logging
  • 1 - enable file logging
logLevel Configures the minimum severity level for the logged messages. Available options are: Verbose, Debug, Info, Warning, Error, and Fatal.
flushInterval If provided, a full disk flush will be performed periodically at the specified interval in seconds. E.g: 1s, 5s, 20s
fileName Name of the log file. The file will be stored in the folder where the application starts.
retainedFileCount Maximum number of log files that will be retained, including the current log file. For unlimited retention, set it to null. The default value is 31.
rollSizeBytes If defined, a new log file is created when the log file size reaches the designated number of bytes. New log files will have an index counter appended in the format _NNN, with the initial log file given no index counter.

 

 

Send log messages to a Seq structured log server

Configuration in the Configuration Manager:

Key Path Key Name Key Value
kv/<environment>/<application>/app-settings seq-logging enabled=0; apiKey={seq instrumentation key}; logLevel=Debug; flushInterval=1s; serverUrl=http://localhost:5341; maxEventCount=100000;
 
Parameter Description
enabled
  • 0 - disable Seq logging
  • 1 - enable Seq logging
apiKey Seq API key that authenticates the client to the Seq server.
logLevel Minimum severity level for the logged messages. Available options are: Verbose, Debug, Info, Warning, Error, and Fatal.
flushInterval Time to wait (in seconds) between checking for event batches.
serverUrl Base URL of the Seq server that log events will be sent to.
maxEventCount Maximum number of events that will be held in-memory while waiting to ship them to Seq. Beyond this limit, events will be dropped. Default: 100000.

 

 

Send log messages to an Azure Application Insights service

You can use the Azure Application Insights application performance management service (subscription required) to collect logging information. If you want to centralize your logs, you can configure multiple machines on the same cluster to send their logging information to the same Application Insights subscription.

NOTE  
Logs saved to the local file storage are visible instantly. Messages sent to Azure Application Insights might be visible after a short delay ranging from seconds to minutes.

Configuration in the Configuration Manager:

Key Path Key Name Key Value
kv/<environment>/<application>/app-settings azure-appinsights-logging enabled=0; apiKey={app insights instrumentation key}; logLevel=Verbose; flushInterval=1m;
 
Parameter Description
enabled
  • 0 - disable Azure Application Insights logging
  • 1 - enable Azure Application Insights logging
apiKey Instrumentation key value that it is used by default by all Microsoft.ApplicationInsights.TelemetryClient instances created in the logger.
logLevel

Minimum severity level for the logged messages. Available options are: Verbose, Debug, Info, Warning, Error, and Fatal.

IMPORTANT!  
Specifying a log level greater than Warning, may flood Azure Application Insights with irrelevant information. It is not recommended to enable Azure Application Insights logging on development environments.
flushInterval Maximum telemetry batching interval. Once the interval expires, Microsoft.ApplicationInsights.WindowsServer.TelemetryChannel serializes the accumulated telemetry items for transmission.

 

 

Configure Azure Application Insights telemetry

Configuration in the Configuration Manager:

Key Path Key Name Key Value
kv/<environment>/<application>/app-settings azure-appinsights-telemetry-logging
  • 0 - disable telemetry
  • 1 - enable telemetry
NOTE  
Deactivating telemetry does not affect logging.
 

Logging context

In addition to the actual log event, developers can track the context in which a log event occurred (machine name, portal profile, user context regional settings, thread ID, etc.), as well as define their own custom log context properties via server-side scripting. For more information, see the Innovation Studio User Guide.