Info
Version: | 1.2021.6 |
Author(s): | SFERA srl |
Last Update: | Monday, November 15, 2021 |
.NET Fiddle: | Create the first Fiddle |
NuGet Url: | https://www.nuget.org/packages/SFERA.Helpers.WEB.JsonLogger |
Install
Install-Package SFERA.Helpers.WEB.JsonLogger
dotnet add package SFERA.Helpers.WEB.JsonLogger
paket add SFERA.Helpers.WEB.JsonLogger
SFERA.Helpers.WEB.JsonLogger Download (Unzip the "nupkg" after downloading)
Dependencies
.NETFramework 4.7
- Microsoft.AspNetCore.Mvc.Core(>= 2.2.5)
- Newtonsoft.Json(>= 12.0.3)
- SFERA.Helpers.VisualBasic(>= 1.2020.24.117)
- Microsoft.AspNetCore.Mvc.Core(>= 2.2.5)
- Newtonsoft.Json(>= 12.0.3)
- SFERA.Helpers.VisualBasic(>= 1.2020.24.117)
- Microsoft.AspNetCore.Mvc.Core(>= 2.2.5)
- Newtonsoft.Json(>= 12.0.3)
- SFERA.Helpers.VisualBasic(>= 1.2020.24.117)
- Microsoft.AspNetCore.Mvc.Core(>= 2.2.5)
- Newtonsoft.Json(>= 12.0.3)
- SFERA.Helpers.VisualBasic(>= 1.2020.24.117)
- Microsoft.AspNetCore.Mvc.Core(>= 2.2.5)
- Newtonsoft.Json(>= 12.0.3)
- SFERA.Helpers.VisualBasic(>= 1.2020.24.117)
- Microsoft.AspNetCore.Mvc.Core(>= 2.2.5)
- Newtonsoft.Json(>= 12.0.3)
- SFERA.Helpers.VisualBasic(>= 1.2020.24.117)
- Microsoft.AspNetCore.Mvc.Core(>= 2.2.5)
- Newtonsoft.Json(>= 12.0.3)
- SFERA.Helpers.VisualBasic(>= 1.2020.24.117)
- Microsoft.AspNetCore.Mvc.Core(>= 2.2.5)
- Newtonsoft.Json(>= 12.0.3)
- SFERA.Helpers.VisualBasic(>= 1.2020.24.117)
- Microsoft.AspNetCore.Mvc.Core(>= 2.2.5)
- Newtonsoft.Json(>= 12.0.3)
- SFERA.Helpers.VisualBasic(>= 1.2020.24.117)
It creates easy to access logs grouped by controller name.
just add this row at beginning of your controller:
SFERA.Helpers.WEB.JsonLogger.Log.LogRequest(ControllerContext: this.ControllerContext, SessionID: Request.Credentials.SessionID, BaseLogFolder: new System.IO.DirectoryInfo(new System.Uri([yourlogdirefctory] + @"\").LocalPath).FullName, Request: [yourIncomingRequestClass];
and this row at end of your controller:
SFERA.Helpers.WEB.JsonLogger.Log.LogResponse(ControllerContext: this.ControllerContext, SessionID: Request.Credentials.SessionID, BaseLogFolder: new System.IO.DirectoryInfo(new System.Uri([yourlogdirefctory] + @"\").LocalPath).FullName, Response: [yourOutgoingRequestClass]);.