Skip to content

Commit

Permalink
Initial draft of NLog v6 goals
Browse files Browse the repository at this point in the history
  • Loading branch information
snakefoot committed Oct 1, 2024
2 parents 69ff43f + 3b5f480 commit 3a325d7
Show file tree
Hide file tree
Showing 3 changed files with 29 additions and 14 deletions.
13 changes: 7 additions & 6 deletions _posts/2024-10-01-nlog-6-0-goals.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,19 +9,19 @@ NLog v6.0 has the following goals:
- Support Nullable references
- Remove old target platforms `NetStandard1.3` + `NetStandard1.5`
- Cleanup interfaces for `Logger` / `ILogger` to remove unnecessary boxing optimizations from .NET v1
- Remove Systeml.RegularExpression dependency since a heavy dependency for AOT
- Need to implement a minimal syntax-support for NLog Logging Rules. Ex. `?` and `.*`
- Remove Systeml.Xml dependency since a heavy dependency for AOT
- Remove `System.Text.RegularExpressions` dependency since a heavy dependency for AOT
- Need to implement a minimal syntax-support for NLog Logging Rules. Ex. `?` and `*`
- Remove `System.Xml` dependency since a heavy dependency for AOT
- Need to implement a minimal XML reader to continue loading `NLog.config` XML files
- Extract NLog.Targets.WebServiceTarget to its own nuget-package
- Extract NLog.Targets.NetworkTarget to its own nuget-package
- Extract NLog.Targets.MailTarget to its own nuget-package
- Extract NLog.Targets.FileTarget to its own nuget-package NLog.Targets.ConcurrentFileTarget
- NLog will instead have a simple FileTarget without ConcurrentWrites-support but only KeepFileOpen = false

The overall goal for NLog v6.0 is still to be a fully working logging-library in a single nuget-package.
The overall goal for NLog v6.0 is to continue being a fully working logging-library in a single nuget-package.
The NLog-package will out of the box only handle file- and console-output, which will probably cover 90 pct.
of the use cases. When needing other output destinations or formats, then additional nuget-packages must be included.
of the use cases. When needing other output targets or formats, then additional nuget-packages must be included.

The planned interface cleanup for `Logger` / `ILogger` will probably give a lot of headache,
as it will require all dependencies to be upgraded before upgrading the main-application.
Expand All @@ -37,4 +37,5 @@ will fully support AOT, to allow more ASP.NET or MAUI applications to start usin
NLog should not become a blocker, when wanting to try out AOT builds.

This means NLog v5 will now go into maintenance mode (together with NLog v4), and focus
will now be on getting NLog v6 preview build ready.
will now be on getting NLog v6 preview build ready. If having suggestions for the future direction
of the [NLog v6 milestone](https://github.com/NLog/NLog/milestone/29) then [comments are wellcome](https://github.com/NLog/NLog/issues/4931).
14 changes: 11 additions & 3 deletions config/targets.json
Original file line number Diff line number Diff line change
Expand Up @@ -601,9 +601,9 @@
},
{
"name": "Loupe",
"page": "https://github.com/GibraltarSoftware/Gibraltar.Agent.NLog2",
"package": "Gibraltar.Agent.NLog4",
"description": "Writes NLog messages to Gibraltar https://www.onloupe.com",
"page": "https://github.com/gibraltarsoftware/gibraltar.agent.nlog2",
"package": "Loupe.Agent.NLog",
"description": "Writes NLog messages to Gibraltar Loupe Agent https://www.onloupe.com",
"external": true,
"category": "Integrations (Cloud)"
},
Expand Down Expand Up @@ -869,5 +869,13 @@
"description": "Writes NLog messages to NATS messaging server",
"external": true,
"category": "Integrations"
},
{
"name": "ActiveMQ",
"page": "https://github.com/YuraSidorets/NLog.Targets.ActiveMQ",
"package": "NLog.Targets.ActiveMQ",
"description": "Writes NLog messages using Apache ActiveMQ NMS native OpenWire protocol",
"external": true,
"category": "Integrations"
}
]
16 changes: 11 additions & 5 deletions index.html
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,9 @@ <h1 class="page-header" id="welcome">
Welcome to NLog!
</h1>
<p class="lead">
NLog is a flexible and free logging platform for various .NET platforms, including .NET standard.
NLog makes it easy to write to several <a href="{{ site.baseurl }}/config/?tab=targets">targets</a>. (database, file, console) and change the logging configuration on-the-fly.
NLog is a flexible and free logging platform for various .NET platforms, including .NET standard.

NLog makes it easy to write to several <a href="{{ site.baseurl }}/config/?tab=targets">targets</a>. (console, file, database, etc.) and change the logging configuration on-the-fly.
</p>

<p>
Expand All @@ -34,9 +34,15 @@ <h4>Easy to configure</h4>
</p>
</div>
<div class="col-sm-4">
<h4>Templatable</h4>
<h4>Output formats</h4>
<p>
Every log message can be templated with various <a href="{{ site.baseurl }}/config/?tab=layout-renderers">layout renders</a>
NLog Layouts are available for several output formats like
<a href="https://github.com/NLog/NLog/wiki/SimpleLayout">Simple Text</a>,
<a href="https://github.com/NLog/NLog/wiki/JsonLayout">JSON</a>,
<a href="https://github.com/NLog/NLog/wiki/XmlLayout">XML</a>,
<a href="https://github.com/NLog/NLog/wiki/CsvLayout">CSV</a> etc.,
The output can be enriched by using the many <a href="{{ site.baseurl }}/config/?tab=layout-renderers">layout renders</a>,
that are able to automatically capture additional output details when logging.
</p>
</div>
<div class="col-sm-4">
Expand Down

0 comments on commit 3a325d7

Please sign in to comment.