Skip to content

Sitefinity/external-logging

Repository files navigation

External logging project

Latest supported version: Sitefinity CMS 11.0.6700.0

Documentation articles: Tutorial: Create and enable a custom trace listener

Overview

Developers can implement their own custom error logger. This sample demonstrates error logging to an external application, which in this case is Raygun.io.

Prerequisites

  • You must have a Sitefinity CMS license.
  • Your setup must comply with the system requirements.
    For more information, see the System requirements for the respective Sitefinity CMS version.
  • Obtain a Raygun API key.
    To acquire a Raygun API key register in Raugun.io and create a new application on your Raygun.io dashboard.

Installation

  1. Clone the sample repository.

  2. Clear the NuGet cache files.
    a. Open the solution file in Visual Studio.
    b. In the toolbar, navigate to Tools >> NuGet Package Manager >> Package Manager Settings.
    c. In the left pane, navigate to NuGet Package Manager >> General.
    d. Click Clear All NuGet Cache(s).

  3. Restore the NuGet packages in the solution.

    NOTE: The solution in this repository relies on NuGet packages with automatic package restore while the build procedure takes place.
    For a full list of the referenced packages and their versions see the packages.config file.
    For a history and additional information related to package versions on different releases of this repository, see the Releases page.

    a. Navigate to Tools >> NuGet Package Manager >> Package Manager Console.
    b. In Source, select Sitefinity CMS NuGet Repository.
    c. Click Restore button.

  4. Open your Sitefinity CMS application in Visual Studio.

  5. In the context menu of the solution, click Add >> Existing project…

  6. Browse to the folder of the cloned project and select the ExternalLogging.csproj file.

  7. In your project, in the context menu of the Reference folder, click Add >> References…

  8. Select the newly added ExternalLogging project.

  9. Open the web.config file of your Sitefinity CMS application and configure Raygun:

  • Inside the <configSections> tag, add the following section:
    <section name="RaygunSettings" type="Mindscape.Raygun4Net.RaygunSettings, Mindscape.Raygun4Net"/>
  • After the <configSections> tag, add the Raygun settings configuration block:
    <RaygunSettings apikey="YOUR_APP_API_KEY" />
  1. Build your solution.

RESULT: You can monitor your application in the Dashboard of your Reygun application. For more information, see Raugun.io.

Additional resources

Youtube video demo:

Tooltip

About

The external logging sample project demonstrates how to log Sitefinity CMS errors to an external application.

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages