Skip to content

Commit

Permalink
Version 5.2.1 (#915)
Browse files Browse the repository at this point in the history
  • Loading branch information
snakefoot authored Dec 30, 2022
1 parent 30276ad commit c6c75ee
Show file tree
Hide file tree
Showing 7 changed files with 52 additions and 30 deletions.
14 changes: 14 additions & 0 deletions CHANGELOG.MD
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,20 @@ See also [releases](https://github.com/NLog/NLog.Web/releases) and [milestones](

Date format: (year/month/day)

### Version 5.2.1 (2022/12/29)

- **NLog.Web.AspNetCore**
- [#900](https://github.com/NLog/NLog.Web/pull/900) Introduced NLogBufferingTargetWrapperMiddleware to support AspNetBufferingWrapper (#900) (@bakgerman)
- [#898](https://github.com/NLog/NLog.Web/pull/898) Created README.md for the NLog.Web.AspNetCore nuget-package (#898) (@bakgerman)
- [#904](https://github.com/NLog/NLog.Web/pull/904) Added common Items-property for LayoutRenderers that can output multiple values. Ex Headers/Cookies (#904) (@snakefoot)
- [#915](https://github.com/NLog/NLog.Web/pull/915) Updated dependency NLog.Extensions.Logging v5.2.1 (#915) (@snakefoot)

- **NLog.Web**
- [#900](https://github.com/NLog/NLog.Web/pull/900) Extend AspNetBufferingWrapper to allow use with other integrations than NLogHttpModule (#900) (@bakgerman)
- [#898](https://github.com/NLog/NLog.Web/pull/898) Created README.md for the NLog.Web nuget-package (#898) (@bakgerman)
- [#904](https://github.com/NLog/NLog.Web/pull/904) Added common Items-property for LayoutRenderers that can output multiple values. Ex Headers/Cookies (#904) (@snakefoot)
- [#915](https://github.com/NLog/NLog.Web/pull/915) Updated dependency NLog v5.1.1 (#915) (@snakefoot)

### Version 5.2.0 (2022/11/27)

- **NLog.Web.AspNetCore**
Expand Down
2 changes: 1 addition & 1 deletion build.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
# creates NuGet package at \artifacts
dotnet --version

$versionPrefix = "5.2.0" # Also update version for minor versions in appveyor.yml
$versionPrefix = "5.2.1" # Also update version for minor versions in appveyor.yml
$versionSuffix = ""
$versionFile = $versionPrefix + "." + ${env:APPVEYOR_BUILD_NUMBER}
if ($env:APPVEYOR_PULL_REQUEST_NUMBER) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
<package id="Microsoft.jQuery.Unobtrusive.Validation" version="3.1.2" targetFramework="net461" />
<package id="Microsoft.Web.Infrastructure" version="1.0.0.0" targetFramework="net461" />
<package id="Modernizr" version="2.8.3" targetFramework="net461" />
<package id="NLog" version="5.1.0" targetFramework="net461" />
<package id="NLog" version="5.1.1" targetFramework="net461" />
<package id="System.Diagnostics.DiagnosticSource" version="4.4.1" targetFramework="net461" />
<package id="WebGrease" version="1.6.0" targetFramework="net461" />
</packages>
28 changes: 12 additions & 16 deletions src/NLog.Web.AspNetCore/NLog.Web.AspNetCore.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@
<TargetFrameworks>net461;netstandard2.0;netcoreapp3.1;net5.0;net6.0</TargetFrameworks>
<Product>NLog.Web.AspNetCore v$(VersionPrefix)</Product>
<Description>
Integrates NLog as provider for Microsoft.Extensions.Logging, and provides NLog LayoutRenderers to enrich logging output with details from HttpContext.
</Description>
Integrates NLog as provider for Microsoft.Extensions.Logging, and provides NLog LayoutRenderers to enrich logging output with details from HttpContext.
</Description>
<Authors>Julian Verdurmen</Authors>
<Company>NLog</Company>
<CurrentYear>$([System.DateTime]::Now.ToString(yyyy))</CurrentYear>
Expand All @@ -14,14 +14,10 @@
<PackageId>NLog.Web.AspNetCore</PackageId>
<PackageTags>logging;log;NLog;web;aspnet;aspnetcore;MVC;Microsoft.Extensions.Logging;httpcontext</PackageTags>
<PackageReleaseNotes>
- Changed LoadConfigurationFromAppSettings to prioritize current directory (#885) (@snakefoot)
- Changed AspNetAppBasePathLayoutRenderer to prioritize current directory (#887) (@snakefoot)
- Add ObjectPath to AspNetItemValueLayoutRenderer as better alternative to EvaluateAsNestedProperties (#890) (@bakgerman)
- Add ObjectPath to AspNetSessionValueLayoutRenderer as better alternative to EvaluateAsNestedProperties (#894) (@snakefoot)
- Use CallerArgumentExpressionAttribute in helper method for throwing ArgumentNullException (#889) (@bakgerman)
- Skip allocating RouteData when only need to lookup single value (#891) (@snakefoot)
- Use RegisterConfigSettings instead of ConfigSettingLayoutRenderer (#878 + #879) (@snakefoot)
- Updated dependency NLog.Extensions.Logging v5.2.0 (#894) (@snakefoot)
- Introduced NLogBufferingTargetWrapperMiddleware to support AspNetBufferingWrapper (#900) (@bakgerman)
- Created README.md for the NLog.Web.AspNetCore nuget-package (#898) (@bakgerman)
- Added common Items-property for LayoutRenderers that can output multiple values. Ex Headers/Cookies (#904) (@snakefoot)
- Updated dependency NLog.Extensions.Logging v5.2.1 (#915) (@snakefoot)

List of major changes in NLog 5.0: https://nlog-project.org/2022/05/16/nlog-5-0-finally-ready.html

Expand All @@ -42,13 +38,13 @@ List of available Layout Renderers: https://nlog-project.org/config/?tab=layout-
<TreatWarningsAsErrors>true</TreatWarningsAsErrors>
<GenerateDocumentationFile>true</GenerateDocumentationFile>
<AssemblyTitle>$(Title)</AssemblyTitle>
<EmbedUntrackedSources>true</EmbedUntrackedSources>
<!-- EmbedUntrackedSources for deterministic build -->
<PackageReadmeFile>README.md</PackageReadmeFile>
<EmbedUntrackedSources>true</EmbedUntrackedSources>
<PackageReadmeFile>README.md</PackageReadmeFile>
</PropertyGroup>
<ItemGroup>
<None Include="N.png" Pack="true" PackagePath="" Visible="false" />
<None Include="README.md" Pack="true" PackagePath=""/>
<None Include="README.md" Pack="true" PackagePath=""/>
</ItemGroup>
<Target Name="DownloadMissingContent" BeforeTargets="GenerateNuspec">
<DownloadFile SourceUrl="https://nlog-project.org/N.png" DestinationFolder="$(MSBuildThisFileDirectory)" />
Expand Down Expand Up @@ -76,7 +72,7 @@ List of available Layout Renderers: https://nlog-project.org/config/?tab=layout-
<DefineConstants>$(DefineConstants);ASP_NET_CORE;ASP_NET_CORE3</DefineConstants>
</PropertyGroup>
<ItemGroup>
<PackageReference Include="NLog.Extensions.Logging" Version="5.2.0" />
<PackageReference Include="NLog.Extensions.Logging" Version="5.2.1" />
</ItemGroup>
<ItemGroup Condition=" '$(TargetFramework)' == 'netstandard2.0' or '$(TargetFramework)' == 'net461' ">
<!-- Fixed to 2.1.0 as 2.1 is Long Term Supported (LTS) and only supported version for .NET Framework 4.6.1 -->
Expand All @@ -100,10 +96,10 @@ List of available Layout Renderers: https://nlog-project.org/config/?tab=layout-
<ItemGroup>
<Compile Include="..\Shared\**\*.cs" />
</ItemGroup>

<ItemGroup>
<EmbeddedResource Include="ILLink.Descriptors.xml">
<LogicalName>ILLink.Descriptors.xml</LogicalName>
</EmbeddedResource>
</ItemGroup>
</Project>
</Project>
10 changes: 8 additions & 2 deletions src/NLog.Web.AspNetCore/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
[![](https://sonarcloud.io/api/project_badges/measure?project=nlog.web&branch=master&metric=bugs)](https://sonarcloud.io/dashboard/?id=nlog.web&branch=master)
[![](https://sonarcloud.io/api/project_badges/measure?project=nlog.web&branch=master&metric=vulnerabilities)](https://sonarcloud.io/dashboard/?id=nlog.web&branch=master)

Integrates NLog as [Logging provider](https://learn.microsoft.com/en-us/dotnet/core/extensions/logging-providers) for ASP.NET Core platform via extension methods for IHostBuilder, and IWebHostBuilder.
Integrates NLog as [Logging provider](https://learn.microsoft.com/en-us/dotnet/core/extensions/logging-providers) for the ASP.NET Core platform, by just calling `UseNLog()` with the application host-builder.

Providing features like:

Expand All @@ -22,7 +22,7 @@ Supported platforms:
- For ASP.NET Core 3, .NET Core 3.1
- For ASP.NET Core 2, .NET Standard 2.0 and .NET 4.6.1+

Registration of NLog.Web.AspNetCore in the NLog.config File
Registration of NLog.Web.AspNetCore in the NLog.config file:

```xml
<!-- enable ASP.NET Core layout renderers -->
Expand All @@ -31,6 +31,12 @@ Registration of NLog.Web.AspNetCore in the NLog.config File
</extensions>
```

Registration of NLog.Web.AspNetCore can also be performed with fluent setup:

```csharp
NLog.LogManager.Setup().LoadConfigurationFromAppSettings();
```

Useful Links

- [Home Page](https://nlog-project.org/)
Expand Down
18 changes: 9 additions & 9 deletions src/NLog.Web/NLog.Web.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,9 @@ For ASP.NET Core: Check https://www.nuget.org/packages/NLog.Web.AspNetCore
Remember to register NLog.Web in NLog.config

&lt;extensions&gt;
&lt;add assembly="NLog.Web" /&gt;
&lt;add assembly="NLog.Web" /&gt;
&lt;/extensions&gt;

Full changelog: https://github.com/NLog/NLog.Web/releases

List of available Layout Renderers: https://nlog-project.org/config/?tab=layout-renderers&amp;search=package:nlog.web
Expand All @@ -33,28 +33,28 @@ List of available Layout Renderers: https://nlog-project.org/config/?tab=layout-
<PackageLicenseExpression>BSD-3-Clause</PackageLicenseExpression>
<RepositoryType>git</RepositoryType>
<RepositoryUrl>https://github.com/NLog/NLog.Web.git</RepositoryUrl>

<SignAssembly>true</SignAssembly>
<AssemblyVersion>5.0.0.0</AssemblyVersion>
<AssemblyOriginatorKeyFile>NLog.snk</AssemblyOriginatorKeyFile>

<TreatWarningsAsErrors>true</TreatWarningsAsErrors>
<GenerateDocumentationFile>true</GenerateDocumentationFile>
<AssemblyTitle>$(Title)</AssemblyTitle>
<DisableImplicitFrameworkReferences>true</DisableImplicitFrameworkReferences>
<EmbedUntrackedSources>true</EmbedUntrackedSources>
<!-- EmbedUntrackedSources for deterministic build -->
<PackageReadmeFile>README.md</PackageReadmeFile>
<!-- EmbedUntrackedSources for deterministic build -->
<EmbedUntrackedSources>true</EmbedUntrackedSources>
<PackageReadmeFile>README.md</PackageReadmeFile>
</PropertyGroup>
<ItemGroup>
<None Include="N.png" Pack="true" PackagePath="" Visible="false" />
<None Include="README.md" Pack="true" PackagePath=""/>
<None Include="README.md" Pack="true" PackagePath="" />
</ItemGroup>
<Target Name="DownloadMissingContent" BeforeTargets="GenerateNuspec">
<DownloadFile SourceUrl="https://nlog-project.org/N.png" DestinationFolder="$(MSBuildThisFileDirectory)" />
</Target>
<ItemGroup>
<PackageReference Include="NLog" Version="5.1.0" />
<PackageReference Include="NLog" Version="5.1.1" />
<PackageReference Include="Microsoft.SourceLink.GitHub" Version="1.1.1" PrivateAssets="All" />
</ItemGroup>
<ItemGroup>
Expand Down
8 changes: 7 additions & 1 deletion src/NLog.Web/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ Supported platforms:

- .NET 3.5 - 4.8

Registration of NLog.Web in the NLog.config File
Registration of NLog.Web in the NLog.config file:

```xml
<!-- enable ASP.NET layout renderers -->
Expand All @@ -28,6 +28,12 @@ Registration of NLog.Web in the NLog.config File
</extensions>
```

Registration of NLog.Web can also be performed with fluent setup:

```csharp
NLog.LogManager.Setup().RegisterNLogWeb();
```

Useful Links

- [Home Page](https://nlog-project.org/)
Expand Down

0 comments on commit c6c75ee

Please sign in to comment.