Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/nlog/nlog.elmah

ELMAH target for NLog
https://github.com/nlog/nlog.elmah

elmah nlog nlog-target

Last synced: 10 days ago
JSON representation

ELMAH target for NLog

Awesome Lists containing this project

README

        

# NLog.Elmah
[![Version](https://badge.fury.io/nu/NLog.ELMAH.svg)](https://www.nuget.org/packages/NLog.ELMAH)
[![AppVeyor](https://img.shields.io/appveyor/ci/nlog/nlog-Elmah/master.svg)](https://ci.appveyor.com/project/nlog/nlog-Elmah/branch/master)

ELMAH target for NLog

Extensions to [NLog](https://github.com/NLog/NLog/)

# Usage

Install the library with Nuget

> Install-Package NLog.Elmah

Update NLog to the latest version

> Update-Package NLog

Read the [NLog tutorial](https://github.com/NLog/NLog/wiki/Tutorial)

Example config:

```xml







```

## Options
- **Layout** - Used for rendering the `Elmah.Message`. Default is `${message}`
- **LogType** - Layout for rendering the `Elmah.Type` Field. Default is `${exception:format=Type:whenEmpty=${level}}`
> Introduced with NLog.Elmah v4.1 and replaces obsolete `LogLevelAsType`
- **LogSource** - Layout for rendering the `Elmah.Source` Field. Default is `${exception:format=Source:whenEmpty=${logger}}`
- **LogDetail** - Layout for rendering the `Elmah.Detail` Field. Default is `${exception:format=ToString}`
- **LogHostName** - Layout for rendering the `Elmah.HostName` Field. Default is `${hostname}`
- **LogUser** - Layout for rendering the `Elmah.User` Field. Default is blank.
- **IdentityNameAsUser** - Use HttpContext.User as fallback when `LogUser` gives blank value. Default is `false`

## Notes
Not strong named (SNK) because [the dependency](https://www.nuget.org/packages/elmah.corelibrary/) isn't strong named.