- 07 Mar 2024
- 4 Minutes to read
- Print
- DarkLight
Logging Overview
- Updated on 07 Mar 2024
- 4 Minutes to read
- Print
- DarkLight
Overview
Logs are records of events throughout the environment, often used as a reference for troubleshooting issues. By tracking information via Logs, Administrators can better pinpoint and monitor any problematic events occurring in a workflow. Information collected by Logs may pertain to various things, such as Flow step execution, System Errors, information on the Email System, etc.
The following article demonstrates a detailed overview of logging and references to other articles for detailed information.
Accessing Logs
File Storage
By default, the platform generates a log file in the designated file storage location. To access and review the logs, navigate to C:\Program Files\Decisions\Decisions Server\Logs and open the Decisions.Web.Core.log file.
The following table represents the various types of Logs that can be viewed in the Logging Folder or System Logs file and a brief description of each one.
Log Type | Description |
---|---|
Decisions.Web.Core.log | This is the central location where all log messages from the Decisions application are recorded and stored. |
LoggingError.log | This file serves the purpose of recording any errors that may occur during the logging process. |
Primary.shmcc.log | This file records the event of any issues encountered during code compilation. |
Decisions.Web.Core.Usage.csv | It records the count of individual API calls, Flow runs, etc., at regular intervals of every 30 seconds. |
Decisions.Web.Core.UsageDetails.txt | It records the logs of Flow executions, API calls, job executions, etc., at regular intervals of every 30 seconds. |
From the Platform
Admin users can access all the log messages within the platform. To view logs within the platform, navigate to the desired Designer Folder > Settings > Health > Logs. Click on the log message to view the details.
Reading Logs
It is important to note that log messages consist of various components that require some knowledge to interpret them effectively. This article aims to provide guidance on reading and comprehending log messages, empowering end users to effectively utilize the information contained within the logs.
Log Levels
Log Levels declare the level of importance and severity of the error described in the log. The following default types are as follows:
Type Name | Description |
---|---|
Info | This provides information to the user on an occurrence and is typically used outside of error tracking. |
Debug | This catches most exceptions that do not fall under the other categories. |
Warn | This tracks potential issues that do not impede the process from running. These are typically less critical issues. |
Error | This tracks when a process cannot complete properly. |
Fatal | This is an environment-breaking level warning that stops a process (or multiple processes) from running. |
External Logging
Logging to Database
Admin users can configure the platform to store the Log messages in the MS SQL or Postgres database. These settings are located at Settings > Health > Logs. For more information on configuration, refer to Write logs to MSSQL and PostgreSQL.
Logging to Cloud Storage
Storing Logs on the cloud helps to centralize them and manage them efficiently when the server is hosted in a clustered environment. Administrators have the option for external logging and profiling through cloud monitoring services.
Logging in different Infrastructure
Multi-Tenant Environment
If the Control instance and Tenant instance are hosted on the same machine, the logs for the control instance can be located at the default path C:\Program Files\Decisions\Decisions Server\Logs. As for the Tenant Instance, the logs are stored in C:\Program Files\Decisions\Decisions Server\Logs\[tenant_name], with the file name being [tenant_name].Core.log.
If the Tenants are hosted on different machines, the log files can be found at the same as the Control instances path.
Clustered Environment
In a clustered environment, all nodes share a common database and file storage. Consequently, each node generates its own logs, which are stored in the default directory C:\Program Files\Decisions\Decisions Server\Logs.
To centralize the logs of all the nodes, admin users must send logs to the cloud logging service.
Logging in Containers
Volume Mapping: To persistently store files from containers, users must volume map the containers with the file storage. Volume mapping establishes a connection between the container and physical storage for file retention.
Decisions default persistent storage in the container is at /opt/decisions/data. Users can establish a shared storage space by mapping a directory on the host machine with /opt/decisions/data in containers.
Example: In the following example, the storage path D:\Decisions\FileStorage
is mapped with opt/decisions/data
.
docker run -p [host port]:[container port] --name [CONTAINER_NAME] -v D:\Decisions\FileStorage:/opt/decisions/data --env-file="[ENVIRONMENT_FILE_PATH]" [IMAGE_NAME]
Log Step
The Log step is a Flow Step used to define a specific log category and a log message. Use this step to create new logs and/or custom log categories detailing execution data of its connected Workflow.
The resulting Logs are viewed via Settings > Health > Logs within a Designer Folder or in the Logs folder via Local File System.
Logging Settings
The Logging Settings found in Settings > Health > Logs in the Designer Folder can be used by Administrators to establish and edit settings about Logging at both the Local and Global levels.