In this article:
When working in Foresight Analytics Platform, the kernel forms and displays debug output. For details see specialized programs, for example, DebugView, which is included in the Sysinternals software package.
Debug information is not saved anywhere by default. In some cases it may be needed to determine the cause of some errors. For this purpose, the user can write debug output to a file. All the settings for logging debug information are stored in the operating system registry. Note that outputting debug information to a file slows down the development environment and applications. Thus, remove the parameters specified below after the problem is investigated and the log file is no more required.
The description below displays the example of the [HKEY_CURRENT_USER] registry key that is used only for the current user. If it is assumed to determine settings for all operating system users or settings are determined during the work with Foresight Analytics Platform BI server, the [HKEY_LOCAL_MACHINE] registry key should be used.
Debug messages are created and displayed by means of the REG_DWORD parameter WriteToDebugOutput located in the key [HKEY_CURRENT_USER\Software\Foresight\Foresight Analytics Platform\10.0\Log]. By default, this parameter can be absent in the registry, debug messages are output by the platform kernel. To disable output of all debug messages, except for information about loaded and unloaded libraries, create the WriteToDebugOutput parameter with the 0 value.
To output debug info to file, make changes in the registry:
Create the Log section in the registry key [HKEY_CURRENT_USER\Software\Foresight\Foresight Analytics Platform\10.0] if it is absent.
Set the parameters in the Log section:
FileName. The string parameter that contains path and name of the file, to which the debug information is output.
SeverityLevel. The REG_DWORD parameter that contains the logging level. The following values can be set for this parameter:
0. All debug output generated by Foresight Analytics Platform kernel is registered.
1. Default value. Information about operation execution duration, query parameters, warnings, and errors is registered.
2. Warnings, errors and critical errors are registered.
3. Errors and critical errors are registered.
4. Only critical errors are registered.
IsolatedByDate. The REG_DWORD parameter that indicates whether a file should be split by dates. If the parameter is created and has the 1 value, a new file is created each day, to which debug output is written. The current date is added to the file name.
To output additional debug info of development environment and task scheduler make changes in the registry specified below.
Debug output can be used to detect errors, which may cause memory leaks. To log in the file the debug info generated by development environment kernel, make changes in the registry:
Make sure that the registry contains the Log section with the FileName and SeverityLevel parameters.
NOTE. Development environment debug information is output if the SeverityLevel parameter is set to 0.
Add the following parameters:
In the key [HKEY_CURRENT_USER\Software\Foresight\Foresight Analytics Platform\10.0\Debug] create REG_DWORD parameters and set them to 1:
GCTrace. It specifies whether it is required to register all garbage collector messages.
DisableMetabaseSqlLog. It disables output of SQL queries to repository system tables to debug info, which are created on working with repository objects.
In the key [HKEY_CURRENT_USER\Software\Foresight\Foresight Analytics Platform\10.0\DevEnv] create REG_DWORD parameters and set them to 1:
DevEnvDebug. Registering information about components creation.
DevEnvParserDebug. Registering development environment parser information.
In the key [HKEY_CURRENT_USER\Software\Foresight\Foresight Analytics Platform\10.0\Fore] create the parameters:
CheckLeaks. The REG_DWORD parameter enables checking of memory leaks after closing repository in the desktop application. To enable the check, set the parameter to 1. If there are memory leaks, the dialog box for saving memory leaks to file opens.
LeaksGraphFile. The path and name of the file, to which the memory leaks list is to be saved on closing repository. If the parameter is set, the dialog box does not open, and the list is saved to the specified file. The file is created in the TGF (trivial graph format) format.
ExternRefLogging. The REG_DWORD parameter enables logging of changes in external links on logging in to repository.
ExtRefChangesFile. The path and name of the file, to which the log of changes in external links is to be saved on closing repository. The file format is TXT.
To log in the file the debug info generated by task scheduler, make changes in the registry:
Make sure that the registry contains the Log section with the FileName and SeverityLevel parameters.
NOTE. Task scheduler debug info is displayed if the SeverityLevel parameter is set to 0.
Create the Scheduler section in the registry key [HKEY_CURRENT_USER\Software\Foresight\Foresight Analytics Platform\10.0] if it is absent.
In the Scheduler section create a REG_DWORD parameter and set it to 3:
Trace. Log trace messages, debug messages and information messages, warnings and all error types.
To log task scheduler debug info in Linux OS, set the <LOG> section in the configuration file structure.
See also: