NLog.GelfTarget
1.1.0
See the version list below for details.
dotnet add package NLog.GelfTarget --version 1.1.0
NuGet\Install-Package NLog.GelfTarget -Version 1.1.0
<PackageReference Include="NLog.GelfTarget" Version="1.1.0" />
paket add NLog.GelfTarget --version 1.1.0
#r "nuget: NLog.GelfTarget, 1.1.0"
// Install NLog.GelfTarget as a Cake Addin #addin nuget:?package=NLog.GelfTarget&version=1.1.0 // Install NLog.GelfTarget as a Cake Tool #tool nuget:?package=NLog.GelfTarget&version=1.1.0
NLog.Targets.Gelf is a custom target for NLog and Graylog2 server
To use NLog.Targets.Gelf just add the following to your config file and place NLog.Targets.Gelf.dll in the same location as the NLog.dll file:
<nlog>
<extensions>
<add assembly="NLog.Targets.Gelf" />
</extensions>
<targets>
<target name="Gelf" type="Gelf" gelfserver="" port="12201" maxchunksize="8154" graylogversion="0.9.5" />
</targets>
<rules>
<logger name="*" minLevel="Trace" appendTo="Gelf"/>
</rules>
</nlog>
Just remember to add in your server URL (without http://) or IP address. Because of differences in the Graylog2 server you need to specify the version as "0.9.5" or "0.9.6" otherwise long message chunking won't work. The default is "0.9.5" if it's left out.
This project was an amalgamation of NLog.Targets.Syslog (https://github.com/graffen/NLog.Targets.Syslog) and Gelf4Net (https://github.com/jjchiw/gelf4net). Thanks to those guys for their code.
This project is also using Newtonsoft.Json.dll (https://json.codeplex.com/) for json serialization.
Product | Versions Compatible and additional computed target framework versions. |
---|---|
.NET Framework | net40 is compatible. net403 was computed. net45 is compatible. net451 was computed. net452 was computed. net46 was computed. net461 was computed. net462 was computed. net463 was computed. net47 was computed. net471 was computed. net472 was computed. net48 was computed. net481 was computed. |
-
- Newtonsoft.Json (>= 6.0.3)
- NLog (>= 3.1.0)
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.