Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

Version 1 Next »

When debugging issues related to coverage on .NET, we sometimes need to retrieve Profiler logs.

The Profiler is a C++ component in charge of instrumenting tests during runtime, as well as the applications under test.

The following document details the necessary steps to collect these logs.

Collecting Profiler logs from IIS

  1. Open the Registry editor (regedit.exe)

  2. Navigate to your service’s key: System\CurrentControlSet\Services\WAS

  3. In the “Environment” multi-string value, add the following parameters in separate lines:

    1. SL_LogLevel=6

    2. SL_LogDir=C:\SeaLights\Logs

  4. Perform the previous step on System\CurrentControlSet\Services\W3SVC

Collecting Profiler logs from Windows Services

  1. Open the Registry editor (regedit.exe)

  2. Navigate to your service’s key: System\CurrentControlSet\Services{YourService}

  3. In the “Environment” multi-string value, add the following parameters in separate lines:

    1. SL_LogLevel=6

    2. SL_LogDir=C:\SeaLights\Logs

Collecting Profiler logs from Windows Processes

  1. Define the following Environment Variables in the environment from which your process is started:

    1. SL_LogLevel=6

    2. SL_LogDir=C:\SeaLights\Logs

  2. This can be achieved by running the following commands in their respective shells:

    1. set SL_LogLevel=6

    2. set SL_LogDir=C:\SeaLights\Logs

Note: if your process starts from within a .bat file, a PowerShell script etc, the above environment variables need to be declared in those shells, or as Global environment variables.

Collecting Profiler logs from VSTS/Azure DevOps Test Stages

  1. In the “SeaLights Start Test Execution” step:

    1. Set the “Profiler log level” to Debug

  2. Run the build, including the test stage in question

  3. After the build finished, review the logging destination:

    1. Select the “SeaLights Start Test Execution” log

    2. Towards the end of the logging output, there should be a string “Logs will be saved to”

    3. The logging files will be inside the folder denoted above

  • No labels