{"id":20511293,"url":"https://github.com/intility/intility.logging","last_synced_at":"2026-01-02T15:21:09.084Z","repository":{"id":40320480,"uuid":"377432124","full_name":"intility/Intility.Logging","owner":"intility","description":"Logging packages supporting the starter templates","archived":false,"fork":false,"pushed_at":"2025-03-03T07:28:17.000Z","size":832,"stargazers_count":14,"open_issues_count":0,"forks_count":0,"subscribers_count":6,"default_branch":"main","last_synced_at":"2025-03-27T13:01:53.991Z","etag":null,"topics":["dotnet"],"latest_commit_sha":null,"homepage":"","language":"C#","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/intility.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":"CODEOWNERS","security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2021-06-16T08:54:08.000Z","updated_at":"2025-03-03T07:28:13.000Z","dependencies_parsed_at":"2025-02-21T09:30:03.669Z","dependency_job_id":"9a1d7ed1-e069-44e6-a5f2-3ed5a7b490dd","html_url":"https://github.com/intility/Intility.Logging","commit_stats":null,"previous_names":[],"tags_count":26,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/intility%2FIntility.Logging","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/intility%2FIntility.Logging/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/intility%2FIntility.Logging/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/intility%2FIntility.Logging/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/intility","download_url":"https://codeload.github.com/intility/Intility.Logging/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248794565,"owners_count":21162613,"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":["dotnet"],"created_at":"2024-11-15T20:35:26.919Z","updated_at":"2026-01-02T15:21:09.024Z","avatar_url":"https://github.com/intility.png","language":"C#","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003ch1 align=\"center\"\u003e\n  \u003cimg src=\"https://avatars.githubusercontent.com/u/35199565\" width=\"124px\"/\u003e\u003cbr/\u003e\n  Intility.Logging\n\u003c/h1\u003e\n\n\u003cp align=\"center\"\u003eLogging enhancement for backend projects using \u003cb\u003easpnet\u003c/b\u003e or \u003cb\u003edotnet generic host\u003c/b\u003e\u003cbr/\u003e by providing common infrastructure and sensible defaults.\u003cbr/\u003e\u003cbr/\u003eFocus on \u003cb\u003ewriting\u003c/b\u003e and \u003cb\u003edesigning\u003c/b\u003e business-logic \u003cbr /\u003eand less time worrying about operational concerns.\u003c/p\u003e\n\n\u003cp align=\"center\"\u003e\n\u003ca href=\"https://github.com/Intility/Intility.Logging/actions\"\u003e\n    \u003cimg alt=\"Release workflow\" src=\"https://github.com/Intility/Intility.Logging/actions/workflows/release.yaml/badge.svg\" style=\"max-width:100%;\"\u003e\n\u003c/a\u003e\n\n\u003ca href=\"https://github.com/Intility/Intility.Logging/actions\"\u003e\n    \u003cimg alt=\"Build workflow\" src=\"https://github.com/Intility/Intility.Logging/actions/workflows/build.yaml/badge.svg\" style=\"max-width:100%;\"\u003e\n\u003c/a\u003e\n\n\u003cbr /\u003e\n\n\u003ca href=\"https://www.nuget.org/packages/Intility.Logging.AspNetCore/\"\u003e\n    \u003cimg alt=\"nuget\" src=\"https://img.shields.io/nuget/v/Intility.Logging.AspNetCore?label=Intility.Logging.AspNetCore\" style=\"max-width:100%;\"\u003e\n\u003c/a\u003e\n\n\u003ca href=\"https://www.nuget.org/packages/Intility.Extensions.Logging/\"\u003e\n    \u003cimg alt=\"nuget\" src=\"https://img.shields.io/nuget/v/Intility.Extensions.Logging?label=Intility.Extensions.Logging\" style=\"max-width:100%;\"\u003e\n\u003c/a\u003e\n\n\u003ca href=\"https://www.nuget.org/packages/Intility.Extensions.Logging.Elasticsearch/\"\u003e\n    \u003cimg alt=\"nuget\" src=\"https://img.shields.io/nuget/v/Intility.Extensions.Logging.Elasticsearch?label=Intility.Extensions.Logging.Elasticsearch\" style=\"max-width:100%;\"\u003e\n\u003c/a\u003e\n\n\u003ca href=\"https://www.nuget.org/packages/Intility.Extensions.Logging.Sentry/\"\u003e\n    \u003cimg alt=\"nuget\" src=\"https://img.shields.io/nuget/v/Intility.Extensions.Logging.Sentry?label=Intility.Extensions.Logging.Sentry\" style=\"max-width:100%;\"\u003e\n\u003c/a\u003e\n\u003c/p\u003e\n\n## ⚡️ Quick start\n\nFirst of all this package is already included in the [Intility templates](https://github.com/Intility/templates), but can be installed separately. Installation is done with the `dotnet add package` command or via Visual Studio Package Manager.\n\n```shell\n# install common infrastructure\ndotnet add package Intility.Logging.AspNetCore\n```\n\nTo instrument the runtime with the new logging capabilities you will need to use an extension method on the `IHostBuilder` interface\n\n```csharp\n// Program.cs\npublic static IHostBuilder CreateHostBuilder(string[] args) =\u003e\n    Host.CreateDefaultBuilder(args)\n        .UseIntilityLogging((hostContext, logging) =\u003e\n        {\n            // add default metadata on log events\n            logging.UseDefaultEnrichers();\n        })\n        //...\n```\n\n## ⚙️ Configuration\n\nThe base package inclues a Console sink with a format supporting structured logging. Use configuration section `Serilog` to configure the loglevel override and other supported settings. See [Serilog]() for more information.\n\n```json\n{\n  \"Serilog\": {\n    \"MinimumLevel\": {\n      \"Default\": \"Information\",\n      \"Override\": {\n        \"System\": \"Warning\",\n        \"Microsoft\": \"Warning\",\n        \"Microsoft.Hosting.Lifetime\": \"Information\"\n      }\n    },\n    \"Properties\": {\n      \"Application\": \"MyApp\"\n    }\n  }\n}\n```\n\n## 🛰️ Addition logging destinations\n\nAdditional sinks can be installed separately if needed. Simply register the new sinks to the logging builder after package installation is complete.\n\n```shell\n# install Elasticsearch sink\ndotnet add package Intility.Extensions.Logging.Elasticsearch\n\n# install Sentry sink\ndotnet add package Intility.Extensions.Logging.Sentry\n```\n\n```csharp\n// Program.cs\npublic static IHostBuilder CreateHostBuilder(string[] args) =\u003e\n    Host.CreateDefaultBuilder(args)\n        .UseIntilityLogging((hostContext, logging) =\u003e\n        {\n            logging.UseDefaultEnrichers()\n                .UseElasticsearch()\n                .UseSentry();\n        })\n        //...\n```\n\n```json\n{\n  \"Elasticsearch\": {\n    \"Endpoints\": \"localhost:9200\",\n    \"IndexFormat\": \"my-service-{0:yyyy.MM}\"\n  },\n  \"Sentry\": {\n    \"Dsn\": \"https://examplePublicKey@o0.ingest.sentry.io/0\",\n    \"MaxRequestBodySize\": \"Always\",\n    \"SendDefaultPii\": true,\n    \"MinimumBreadcrumbLevel\": \"Debug\",\n    \"MinimumEventLevel\": \"Warning\",\n    \"AttachStackTrace\": true,\n    \"Debug\": true,\n    \"DiagnosticsLevel\": \"Error\"\n  }\n}\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fintility%2Fintility.logging","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fintility%2Fintility.logging","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fintility%2Fintility.logging/lists"}