insights
2022.4
false
- Release Notes
- Getting Started
- Access and Permissions
- Interacting with Insights
- Logs
- Configuring Log Rules
Configuring Log Rules
Insights
Last updated Dec 18, 2024
Configuring Log Rules
Robot logs capture diagnostic and execution logs. You can configure the conditions for which Robot logs are ingested by Insights. For example, you only want to capture logs for Processes that include a specific name.
For more information, see Robot logs.
You can configure the Orchestrator settings in the
nlog.custom.config
file. To modify the settings, take the following steps:
- Place the new log rules inside the
nlog.custom.config
file. Check the details below for an example:{ "10_Robot_Insights": { "logger": "Robot.*", "ruleName": "insightsRobotLogsRule", "minLevel": "Info", "writeTo": "insightsRobotLogs", "enabled": false, "final": false, "filters": { "defaultAction": "Ignore", "conditions": [ { "condition": "level >= LogLevel.Error or ends-with('${message}', ' execution ended')", "action": "Log" } ] } } }
{ "10_Robot_Insights": { "logger": "Robot.*", "ruleName": "insightsRobotLogsRule", "minLevel": "Info", "writeTo": "insightsRobotLogs", "enabled": false, "final": false, "filters": { "defaultAction": "Ignore", "conditions": [ { "condition": "level >= LogLevel.Error or ends-with('${message}', ' execution ended')", "action": "Log" } ] } } } - Use the Orchestrator Configurator Tool to update
the configuration. Use the following command to merge the keys from the custom
nlog.custom.config
file with the settings already available in theorchestrator-customconfig
configuration map.This command does not remove any existing settings../orchestrator-configurator.sh -l nlog.custom.config
./orchestrator-configurator.sh -l nlog.custom.config
In the following example we are only sending logs that are above a certain level or contain the message that the execution has ended:
{
"10_Robot_Insights": {
"logger": "Robot.*",
"ruleName": "insightsRobotLogsRule",
"minLevel": "Info",
"writeTo": "insightsRobotLogs",
"enabled": false,
"final": false,
"filters": {
"defaultAction": "Ignore",
"conditions": [
{
"condition": "level >= LogLevel.Error or ends-with('${message}', ' execution ended')",
"action": "Log"
}
]
}
}
}
{
"10_Robot_Insights": {
"logger": "Robot.*",
"ruleName": "insightsRobotLogsRule",
"minLevel": "Info",
"writeTo": "insightsRobotLogs",
"enabled": false,
"final": false,
"filters": {
"defaultAction": "Ignore",
"conditions": [
{
"condition": "level >= LogLevel.Error or ends-with('${message}', ' execution ended')",
"action": "Log"
}
]
}
}
}