{"id":25398016,"url":"https://github.com/k-society/ksociety.log","last_synced_at":"2025-10-30T21:31:03.116Z","repository":{"id":38363438,"uuid":"319273739","full_name":"K-Society/KSociety.Log","owner":"K-Society","description":"Centralized log system.","archived":false,"fork":false,"pushed_at":"2025-02-14T16:18:25.000Z","size":124164,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-02-14T17:26:48.000Z","etag":null,"topics":["log","logger","logging","rabbitmq","serilog","serilog-sink"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/K-Society.png","metadata":{"files":{"readme":"README.MD","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.TXT","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2020-12-07T09:50:55.000Z","updated_at":"2025-01-23T15:18:29.000Z","dependencies_parsed_at":"2023-10-03T16:49:44.257Z","dependency_job_id":"d6cfe050-f20f-4a93-a87b-38d9368779bb","html_url":"https://github.com/K-Society/KSociety.Log","commit_stats":{"total_commits":288,"total_committers":3,"mean_commits":96.0,"dds":0.3368055555555556,"last_synced_commit":"a595ae1f02814311467bad9f5f28d79bba824b3a"},"previous_names":[],"tags_count":74,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/K-Society%2FKSociety.Log","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/K-Society%2FKSociety.Log/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/K-Society%2FKSociety.Log/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/K-Society%2FKSociety.Log/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/K-Society","download_url":"https://codeload.github.com/K-Society/KSociety.Log/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":239065764,"owners_count":19575773,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["log","logger","logging","rabbitmq","serilog","serilog-sink"],"created_at":"2025-02-15T22:32:10.232Z","updated_at":"2025-10-30T21:31:02.301Z","avatar_url":"https://github.com/K-Society.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"[![Logo](https://github.com/K-Society/KSociety.Log/blob/master/docs/K-Society__Logo_vs-negative.png)](https://github.com/K-Society)\n\n[![build status](https://img.shields.io/github/actions/workflow/status/K-Society/KSociety.Log/build.yml?branch=develop)](https://github.com/K-Society/KSociety.Log/actions/workflows/build.yml?query=branch%3Adevelop) [![NuGet](https://img.shields.io/nuget/v/KSociety.Log.Serilog.Sinks.RabbitMq)](https://www.nuget.org/profiles/K-Society)\n![GitHub all releases](https://img.shields.io/github/downloads/K-Society/KSociety.Log/total)\n\n# KSociety.Log - Log System\n\n## Introduction\n\nThis is the README file for KSociety.Log.\nKSociety.Log is a .NET 8.0 centralized log system, to work properly it needs [RabbitMQ](https://github.com/K-Society/KSociety.RabbitMQ.Install/releases).\n\n### Examples\n\n[Here](https://github.com/K-Society/KSociety.Example) you can find several examples.\n\n## For Linux\nCopy KSociety.Log.Srv.Host.service and KSociety.Log.Pre.Web.App.service files to /etc/systemd/system/ directory.\n\n## Port numbers\n- Log Server: 60500\n- Log Presenter: 61000\n\n## Get Packages\n\nYou can get KSociety.Log.Serilog.Sinks.RabbitMq by [grabbing the latest NuGet package](https://www.nuget.org/packages/KSociety.Log.Serilog.Sinks.RabbitMq/).\n\n## Get Started\n\nIf you work in localhost you will need to install the following applications:\n- [RabbitMQ](https://github.com/K-Society/KSociety.RabbitMQ.Install/releases)\n- [KSociety.Log](https://github.com/K-Society/KSociety.Log/releases)\n\nIn your project install KSociety.Log.Serilog.Sinks.RabbitMq nuget package.\nRemember to set the \"Copy to Output Directory\" option of the appsettings.json file to \"Copy if newer\".\\\nAdd the following section in the appsettings.json file of your application:\n\n```json\n\"Serilog\": {\n    \"Using\": [\n      \"KSociety.Log.Serilog.Sinks.RabbitMq\"\n    ],\n    \"MinimumLevel\": {\n      \"Default\": \"Verbose\",\n      \"Override\": {\n        \"Microsoft\": \"Warning\",\n        \"System\": \"Warning\",\n        \"Grpc\": \"Error\",\n        \"ProtoBuf\": \"Error\"\n      }\n    },\n    \"WriteTo\": [\n      {\n        \"Name\": \"Console\",\n        \"Args\": {\n          \"outputTemplate\": \"[{Timestamp:yyyy-mm-dd HH:mm:ss.fff} {Level:u3}] [{MachineName}] [{SourceContext}] {Message}{NewLine:1}{Exception:1}\"\n        }\n      },\n      {\n        \"Name\": \"RabbitMq\",\n        \"Args\": {\n          \"mqHostName\": \"localhost\",\n          \"mqUserName\": \"KSociety\",\n          \"mqPassword\": \"KSociety\",\n          \"brokerName\": \"k-society_log\",\n          \"exchangeType\": \"Direct\",\n          \"exchangeDurable\": false,\n          \"exchangeAutoDelete\": true,\n          \"queueDurable\": false,\n          \"queueExclusive\": false,\n          \"queueAutoDelete\": true,\n          \"batchPostingLimit\": 50,\n          \"period\": \"00:00:02\",\n          \"textFormatter\": \"KSociety.Log.Serilog.Sinks.RabbitMq.Sinks.RabbitMq.Output.LogEventFormatter, KSociety.Log.Serilog.Sinks.RabbitMq\"\n        }\n      }\n    ],\n    \"Enrich\": [\n      \"FromLogContext\",\n      \"WithMachineName\",\n      \"WithProcessId\",\n      \"WithThreadId\"\n    ],\n    \"Properties\": {\n      \"ApplicationName\": \"your application name\"\n    }\n  }\n  ```\n  Add the following lines of code at the beginning of the main:\n\n  ```csharp\n    KSociety.Log.Serilog.Sinks.RabbitMq.ProtoModel.Configuration.ProtoBufConfiguration();\n\n    var configuration = new ConfigurationBuilder()\n        .AddJsonFile(\"appsettings.json\")\n        .Build();\n\n    global::Serilog.Log.Logger = new LoggerConfiguration().ReadFrom.Configuration(configuration).CreateLogger();\n  ```\n\n  All log messages generated by your application will be sent to RabbitMQ and forwarded to the KSociety.Log.Srv.Host service.\\\n  KSociety.Log.Srv.Host service will:\n  - forward the log messages to the web application KSociety.Log.Pre.Web.App for real-time viewing\n  - write the log messages to a file\n\n### 0. Installer\nThe installer.\n\n| GitHub Repository | NuGet | Download |\n| ------------- | ------------- | ------------- |\n\n### 1. Presentation\nThe presentation layer.\n\n| GitHub Repository | NuGet | Download |\n| ------------- | ------------- | ------------- |\n\n### 1.1 Presentation - Web\n| GitHub Repository | NuGet | Download |\n| ------------- | ------------- | ------------- |\n| [KSociety.Log.Pre.Web.App](https://github.com/K-Society/KSociety.Log/tree/master/src/01/01/Web/KSociety.Log.Pre.Web.App) |  |  |\n\n### 2. Service \nThe service layer.\n\n| GitHub Repository | NuGet | Download |\n| ------------- | ------------- | ------------- |\n| [KSociety.Log.Srv.Agent](https://github.com/K-Society/KSociety.Log/tree/master/src/01/02/KSociety.Log.Srv.Agent) | [![NuGet](https://img.shields.io/nuget/v/KSociety.Log.Srv.Agent)](https://www.nuget.org/packages/KSociety.Log.Srv.Agent) | ![NuGet](https://img.shields.io/nuget/dt/KSociety.Log.Srv.Agent) |\n| [KSociety.Log.Srv.Behavior](https://github.com/K-Society/KSociety.Log/tree/master/src/01/02/KSociety.Log.Srv.Behavior) | [![NuGet](https://img.shields.io/nuget/v/KSociety.Log.Srv.Behavior)](https://www.nuget.org/packages/KSociety.Log.Srv.Behavior) | ![NuGet](https://img.shields.io/nuget/dt/KSociety.Log.Srv.Behavior) |\n| [KSociety.Log.Srv.Contract](https://github.com/K-Society/KSociety.Log/tree/master/src/01/02/KSociety.Log.Srv.Contract) | [![NuGet](https://img.shields.io/nuget/v/KSociety.Log.Srv.Contract)](https://www.nuget.org/packages/KSociety.Log.Srv.Contract) | ![NuGet](https://img.shields.io/nuget/dt/KSociety.Log.Srv.Contract) |\n| [KSociety.Log.Srv.Dto](https://github.com/K-Society/KSociety.Log/tree/master/src/01/02/KSociety.Log.Srv.Dto) | [![NuGet](https://img.shields.io/nuget/v/KSociety.Log.Srv.Dto)](https://www.nuget.org/packages/KSociety.Log.Srv.Dto) | ![NuGet](https://img.shields.io/nuget/dt/KSociety.Log.Srv.Dto) |\n\n### 2.1 Service - Host\n\n| GitHub Repository | NuGet | Download |\n| ------------- | ------------- | ------------- |\n| [KSociety.Log.Srv.Host](https://github.com/K-Society/KSociety.Log/tree/master/src/01/02/Host/KSociety.Log.Srv.Host) |  |  |\n\n### 3. Application\nThe application layer.\n\n| GitHub Repository | NuGet | Download |\n| ------------- | ------------- | ------------- |\n| [KSociety.Log.App.Dto](https://github.com/K-Society/KSociety.Log/tree/master/src/01/03/KSociety.Log.App.Dto) | [![NuGet](https://img.shields.io/nuget/v/KSociety.Log.App.Dto)](https://www.nuget.org/packages/KSociety.Log.App.Dto) | ![NuGet](https://img.shields.io/nuget/dt/KSociety.Log.App.Dto) |\n| [KSociety.Log.App.ReqHdlr](https://github.com/K-Society/KSociety.Log/tree/master/src/01/03/KSociety.Log.App.ReqHdlr) | [![NuGet](https://img.shields.io/nuget/v/KSociety.Log.App.ReqHdlr)](https://www.nuget.org/packages/KSociety.Log.App.ReqHdlr) | ![NuGet](https://img.shields.io/nuget/dt/KSociety.Log.App.ReqHdlr) |\n\n### 4. Business\n| GitHub Repository | NuGet | Download |\n| ------------- | ------------- | ------------- |\n| [KSociety.Log.Biz](https://github.com/K-Society/KSociety.Log/tree/master/src/01/04/KSociety.Log.Biz) | [![NuGet](https://img.shields.io/nuget/v/KSociety.Log.Biz)](https://www.nuget.org/packages/KSociety.Log.Biz) | ![NuGet](https://img.shields.io/nuget/dt/KSociety.Log.Biz) |\n| [KSociety.Log.Biz.Event](https://github.com/K-Society/KSociety.Log/tree/master/src/01/04/KSociety.Log.Biz.Event) | [![NuGet](https://img.shields.io/nuget/v/KSociety.Log.Biz.Event)](https://www.nuget.org/packages/KSociety.Log.Biz.Event) | ![NuGet](https://img.shields.io/nuget/dt/KSociety.Log.Biz.Event) |\n\n### Sink\n| GitHub Repository | NuGet | Download |\n| ------------- | ------------- | ------------- |\n| [KSociety.Log.Serilog.Sinks.Grpc](https://github.com/K-Society/KSociety.Log/tree/master/src/01/Sink/KSociety.Log.Serilog.Sinks.Grpc) | [![NuGet](https://img.shields.io/nuget/v/KSociety.Log.Serilog.Sinks.Grpc)](https://www.nuget.org/packages/KSociety.Log.Serilog.Sinks.Grpc) | ![NuGet](https://img.shields.io/nuget/dt/KSociety.Log.Serilog.Sinks.Grpc) |\n| [KSociety.Log.Serilog.Sinks.RabbitMq](https://github.com/K-Society/KSociety.Log/tree/master/src/01/Sink/KSociety.Log.Serilog.Sinks.RabbitMq) | [![NuGet](https://img.shields.io/nuget/v/KSociety.Log.Serilog.Sinks.RabbitMq)](https://www.nuget.org/packages/KSociety.Log.Serilog.Sinks.RabbitMq) | ![NuGet](https://img.shields.io/nuget/dt/KSociety.Log.Serilog.Sinks.RabbitMq) |\n| [KSociety.Log.Serilog.Sinks.SignalR](https://github.com/K-Society/KSociety.Log/tree/master/src/01/Sink/KSociety.Log.Serilog.Sinks.SignalR) | [![NuGet](https://img.shields.io/nuget/v/KSociety.Log.Serilog.Sinks.SignalR)](https://www.nuget.org/packages/KSociety.Log.Serilog.Sinks.SignalR) | ![NuGet](https://img.shields.io/nuget/dt/KSociety.Log.Serilog.Sinks.SignalR) |\n\n## License\nThe project is under Microsoft Reciprocal License [(MS-RL)](http://www.opensource.org/licenses/MS-RL)\n\n## Dependencies\n\nList of technologies, frameworks and libraries used for implementation:\n\n- [.NET 8](https://dotnet.microsoft.com/download/dotnet/8.0)(platform). Note for Visual Studio users: **VS 2022** is required.\n- [Autofac](https://autofac.org/) (Inversion of Control Container)\n- [protobuf-net](https://github.com/protobuf-net/protobuf-net) (protobuf-net is a contract based serializer for .NET code)\n- [RabbitMQ.Client](https://www.rabbitmq.com/dotnet.html) (The RabbitMQ .NET client is an implementation of an AMQP 0-9-1 client library for C#)\n- [Serilog](https://serilog.net/) (structured logging)\n- [KSociety.Base.App.Shared](https://github.com/K-Society/KSociety.Base/tree/master/src/01/03/KSociety.Base.App.Shared) ()\n- [KSociety.Base.EventBusRabbitMQ](https://github.com/K-Society/KSociety.Base/tree/master/src/01/KSocietyBaseEventBus/KSociety.Base.EventBusRabbitMQ) ()\n- [KSociety.Base.Srv.Agent](https://github.com/K-Society/KSociety.Base/tree/master/src/01/02/KSociety.Base.Srv.Agent) ()\n- [KSociety.Base.Srv.Host.Shared](https://github.com/K-Society/KSociety.Base/tree/master/src/01/02/KSociety.Base.Srv.Shared) ()\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fk-society%2Fksociety.log","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fk-society%2Fksociety.log","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fk-society%2Fksociety.log/lists"}