LemosLogger 1.0.5

There is a newer version of this package available.
See the version list below for details.
dotnet add package LemosLogger --version 1.0.5
NuGet\Install-Package LemosLogger -Version 1.0.5
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="LemosLogger" Version="1.0.5" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add LemosLogger --version 1.0.5
#r "nuget: LemosLogger, 1.0.5"
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
// Install LemosLogger as a Cake Addin
#addin nuget:?package=LemosLogger&version=1.0.5

// Install LemosLogger as a Cake Tool
#tool nuget:?package=LemosLogger&version=1.0.5

LLogger

LemosLogger is a package for creating step-by-step logs in MongoDB.

Package Version Downloads
LemosLogger NuGet Nuget

Dependencies

.NET Standard 2.1

You can check supported frameworks here:

https://docs.microsoft.com/pt-br/dotnet/standard/net-standard

Instalation

This package is available through Nuget Packages: https://www.nuget.org/packages/LemosLogger

Nuget

Install-Package LemosLogger

.NET CLI

dotnet add package LemosLogger
#region  ConfigureDatabase
await LLConnection.ConfigureDatabaseAsync("mongodb://localhost:27017", "Sample");
#endregion

#region Logging
var logger = new LLogger("LLogger");
try
{
    logger.LogFunction("Test", "Dev", "d80f98c6-e126-46da-85b9-9273ce92a098", "Write in console text");
    var text = "Hello, World!";
    logger.LogContent("Writing text", text);
    logger.LogContent("Writing text", text);

    logger.LogFunction("Test2", "Dev", "d80f97c6-e126-46da-85b9-927231392a098", "Write in console text2");
    var text2 = "Hello, World2!";
    logger.LogContent("Writing text2", text2);
    logger.LogContent("Writing text2", text2);
}
catch (Exception ex)
{
    logger.LogError(ex, "Error:");
    throw;
}
finally
{
    await LLogger.SaveLogsAsync(logger);
}
#endregion

#region SearchLogs
var logs = await LLogger.SearchLogsAsync(DateTime.Now.AddHours(-20), DateTime.Now, projectName: "LLoger");
#endregion

Log result

[
  {
    "Id": "e1ef00a3-dcef-46cc-a35f-79b08caa588c",
    "ProjectName": "LLogger",
    "Date": "2022-10-25T20:29:30.669Z",
    "Logs": [
      {
        "LogName": "Test",
        "Environment": "Dev",
        "UniqueId": "d80f98c6-e126-46da-85b9-9273ce92a098",
        "Description": "Write in console text",
        "CreatedAt": "2022-10-25T20:29:30.671Z",
        "Success": true,
        "LogsContent": [
          {
            "Message": "Writing text",
            "Content": "Hello, World!",
            "CreatedAt": "2022-10-25T20:29:30.671Z"
          },
          {
            "Message": "Writing text2",
            "Content": "Hello, World!",
            "CreatedAt": "2022-10-25T20:29:30.671Z"
          }
        ]
      },
      {
        "LogName": "Test2",
        "Environment": "Dev",
        "UniqueId": "d80f98c6-e126-46da-85b9-927231392a098",
        "Description": "Write in console text",
        "CreatedAt": "2022-10-25T20:29:30.671Z",
        "Success": true,
        "LogsContent": [
          {
            "Message": "Writing text",
            "Content": "Hello, World!",
            "CreatedAt": "2022-10-25T20:29:30.671Z"
          },
          {
            "Message": "Writing text2",
            "Content": "Hello, World!",
            "CreatedAt": "2022-10-25T20:29:30.671Z"
          }
        ]
      }
    ]
  }
]
Product Compatible and additional computed target framework versions.
.NET net5.0 was computed.  net5.0-windows was computed.  net6.0 was computed.  net6.0-android was computed.  net6.0-ios was computed.  net6.0-maccatalyst was computed.  net6.0-macos was computed.  net6.0-tvos was computed.  net6.0-windows was computed.  net7.0 was computed.  net7.0-android was computed.  net7.0-ios was computed.  net7.0-maccatalyst was computed.  net7.0-macos was computed.  net7.0-tvos was computed.  net7.0-windows was computed.  net8.0 was computed.  net8.0-android was computed.  net8.0-browser was computed.  net8.0-ios was computed.  net8.0-maccatalyst was computed.  net8.0-macos was computed.  net8.0-tvos was computed.  net8.0-windows was computed. 
.NET Core netcoreapp3.0 was computed.  netcoreapp3.1 was computed. 
.NET Standard netstandard2.1 is compatible. 
MonoAndroid monoandroid was computed. 
MonoMac monomac was computed. 
MonoTouch monotouch was computed. 
Tizen tizen60 was computed. 
Xamarin.iOS xamarinios was computed. 
Xamarin.Mac xamarinmac was computed. 
Xamarin.TVOS xamarintvos was computed. 
Xamarin.WatchOS xamarinwatchos was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last updated
1.0.11 294 12/2/2022
1.0.10 295 12/1/2022
1.0.9 298 11/30/2022
1.0.8 301 11/25/2022
1.0.7 295 11/25/2022
1.0.6 281 11/25/2022
1.0.5 322 11/11/2022
1.0.4 315 11/11/2022
1.0.3 375 10/25/2022