Skip to content
This repository has been archived by the owner. It is now read-only.
Permalink
Browse files

Support for ASP.NET 5 / DNX (451)

Summary:
Converts everything over to be compatible with DNX. The only implementation difference is that using the application config has been abandoned in favor of providing the log key and API key directly when using `AddLoggr`; the file config method is dated and gets in the way of some other things.

A couple features within Loggr had to leave since they weren't easily available in DNX, at least without more dependencies. The Loggr .NET library source is now included since their library doesn't support DNX. Shouldn't be a big loss.

Test Plan: Existing console project, now available at `/sample`. Note the config parameters directly in the extension method now.

Reviewers: kspearrin

Reviewed By: kspearrin

Differential Revision: https://devportal.imobile3.com/D15142
  • Loading branch information...
withinfocus committed Dec 21, 2015
1 parent 4c52ff1 commit f9fdee5aed0d5e4e7568d6dce04dd49c38ad5c9c
Showing with 1,893 additions and 229 deletions.
  1. +0 −17 Loggr.Extensions.Logging.Console/App.config
  2. +0 −84 Loggr.Extensions.Logging.Console/Loggr.Extensions.Logging.Console.csproj
  3. +0 −7 Loggr.Extensions.Logging.Console/packages.config
  4. +23 −10 Loggr.Extensions.Logging.sln
  5. +0 −76 Loggr.Extensions.Logging/Loggr.Extensions.Logging.csproj
  6. +0 −18 Loggr.Extensions.Logging/Loggr.Extensions.Logging.nuspec
  7. +0 −7 Loggr.Extensions.Logging/packages.config
  8. +1 −1 README.md
  9. +6 −0 global.json
  10. +20 −0 sample/Loggr.Extensions.Logging.Console/Loggr.Extensions.Logging.Console.xproj
  11. +1 −1 { → sample}/Loggr.Extensions.Logging.Console/Program.cs
  12. 0 { → sample}/Loggr.Extensions.Logging.Console/Properties/AssemblyInfo.cs
  13. +28 −0 sample/Loggr.Extensions.Logging.Console/project.json
  14. +21 −0 src/Loggr.Extensions.Logging/Loggr.Extensions.Logging.xproj
  15. +185 −0 src/Loggr.Extensions.Logging/Loggr/Event.cs
  16. +98 −0 src/Loggr.Extensions.Logging/Loggr/Events.cs
  17. +459 −0 src/Loggr.Extensions.Logging/Loggr/FluentEvent.cs
  18. +28 −0 src/Loggr.Extensions.Logging/Loggr/HttpClient.cs
  19. +21 −0 src/Loggr.Extensions.Logging/Loggr/IFluentEvent.cs
  20. +11 −0 src/Loggr.Extensions.Logging/Loggr/IHttpClient.cs
  21. +421 −0 src/Loggr.Extensions.Logging/Loggr/LogClient.cs
  22. +64 −0 src/Loggr.Extensions.Logging/Loggr/Users.cs
  23. +128 −0 src/Loggr.Extensions.Logging/Loggr/Utility/Configuration.cs
  24. +84 −0 src/Loggr.Extensions.Logging/Loggr/Utility/ExceptionFormatter.cs
  25. +210 −0 src/Loggr.Extensions.Logging/Loggr/Utility/ObjectDumper.cs
  26. +18 −0 src/Loggr.Extensions.Logging/Loggr/Utility/Settings.cs
  27. +40 −0 src/Loggr.Extensions.Logging/Loggr/Utility/Tags.cs
  28. 0 { → src}/Loggr.Extensions.Logging/LoggrLogger.cs
  29. +6 −6 { → src}/Loggr.Extensions.Logging/LoggrLoggerFactoryExtensions.cs
  30. +2 −2 { → src}/Loggr.Extensions.Logging/LoggrLoggerProvider.cs
  31. 0 { → src}/Loggr.Extensions.Logging/Properties/AssemblyInfo.cs
  32. +18 −0 src/Loggr.Extensions.Logging/project.json

This file was deleted.

This file was deleted.

This file was deleted.

@@ -3,26 +3,39 @@ Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio 14
VisualStudioVersion = 14.0.24720.0
MinimumVisualStudioVersion = 10.0.40219.1
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Loggr.Extensions.Logging", "Loggr.Extensions.Logging\Loggr.Extensions.Logging.csproj", "{F652DD68-9FB2-4E65-836D-AC0E498A8AB5}"
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "src", "src", "{AC04B4F5-7A1F-4A0F-9DA3-4655802419B7}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Loggr.Extensions.Logging.Console", "Loggr.Extensions.Logging.Console\Loggr.Extensions.Logging.Console.csproj", "{E0F88D6B-D4AD-4882-A7F9-42BA77A37FAB}"
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution Items", "{9ACCAE35-1C70-4FB0-9C04-8FE6919BF921}"
ProjectSection(SolutionItems) = preProject
global.json = global.json
EndProjectSection
EndProject
Project("{8BB2217D-0F2D-49D1-97BC-3654ED321F3B}") = "Loggr.Extensions.Logging", "src\Loggr.Extensions.Logging\Loggr.Extensions.Logging.xproj", "{0AF6CB38-184B-4895-985F-35D9C4FAC02A}"
EndProject
Project("{8BB2217D-0F2D-49D1-97BC-3654ED321F3B}") = "Loggr.Extensions.Logging.Console", "sample\Loggr.Extensions.Logging.Console\Loggr.Extensions.Logging.Console.xproj", "{E88C4A16-6B32-4E31-A23C-4AFBCFA0BB5D}"
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "sample", "sample", "{D7C5CA2B-2074-4C21-8334-8A05A3344ECF}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
Release|Any CPU = Release|Any CPU
EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution
{F652DD68-9FB2-4E65-836D-AC0E498A8AB5}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{F652DD68-9FB2-4E65-836D-AC0E498A8AB5}.Debug|Any CPU.Build.0 = Debug|Any CPU
{F652DD68-9FB2-4E65-836D-AC0E498A8AB5}.Release|Any CPU.ActiveCfg = Release|Any CPU
{F652DD68-9FB2-4E65-836D-AC0E498A8AB5}.Release|Any CPU.Build.0 = Release|Any CPU
{E0F88D6B-D4AD-4882-A7F9-42BA77A37FAB}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{E0F88D6B-D4AD-4882-A7F9-42BA77A37FAB}.Debug|Any CPU.Build.0 = Debug|Any CPU
{E0F88D6B-D4AD-4882-A7F9-42BA77A37FAB}.Release|Any CPU.ActiveCfg = Release|Any CPU
{E0F88D6B-D4AD-4882-A7F9-42BA77A37FAB}.Release|Any CPU.Build.0 = Release|Any CPU
{0AF6CB38-184B-4895-985F-35D9C4FAC02A}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{0AF6CB38-184B-4895-985F-35D9C4FAC02A}.Debug|Any CPU.Build.0 = Debug|Any CPU
{0AF6CB38-184B-4895-985F-35D9C4FAC02A}.Release|Any CPU.ActiveCfg = Release|Any CPU
{0AF6CB38-184B-4895-985F-35D9C4FAC02A}.Release|Any CPU.Build.0 = Release|Any CPU
{E88C4A16-6B32-4E31-A23C-4AFBCFA0BB5D}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{E88C4A16-6B32-4E31-A23C-4AFBCFA0BB5D}.Debug|Any CPU.Build.0 = Debug|Any CPU
{E88C4A16-6B32-4E31-A23C-4AFBCFA0BB5D}.Release|Any CPU.ActiveCfg = Release|Any CPU
{E88C4A16-6B32-4E31-A23C-4AFBCFA0BB5D}.Release|Any CPU.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
EndGlobalSection
GlobalSection(NestedProjects) = preSolution
{0AF6CB38-184B-4895-985F-35D9C4FAC02A} = {AC04B4F5-7A1F-4A0F-9DA3-4655802419B7}
{E88C4A16-6B32-4E31-A23C-4AFBCFA0BB5D} = {D7C5CA2B-2074-4C21-8334-8A05A3344ECF}
EndGlobalSection
EndGlobal

This file was deleted.

This file was deleted.

This file was deleted.

@@ -1 +1 @@
Loggr.Extensions.Logging=======================[![Build status](https://ci.appveyor.com/api/projects/status/l3snx3wl42pluf8p/branch/master?svg=true)](https://ci.appveyor.com/project/mbishopim3/loggr-framework-logging/branch/master) [![NuGet Version](http://img.shields.io/nuget/v/Loggr.Extensions.Logging.svg?style=flat)](https://www.nuget.org/packages/Loggr.Extensions.Logging/) Log to [Loggr][0] from [Microsoft.Extensions.Logging][1].Installation------------Loggr.Extensions.Logging installs through NuGet:```PS> Install-Package Loggr.Extensions.Logging```Configure the Loggr provider through code:```c#var factory = new LoggerFactory();var logger = factory.CreateLogger( "MyLog" );factory.AddLoggr();```In the example we create a new `LoggerFactory` and add the Loggr provider using the `AddLoggr` extension method. It is important to still set up your application configuration settings that the Loggr library injects as a new configuration section, specifically the `logKey` and `apiKey`.Usage-----Log messages to Loggr, just as with every other provider:```c#logger.LogInformation( "This is information" );```License / Support=================Copyright 2012-2015 iMobile3, LLC. All rights reserved.Redistribution and use in source and binary forms, with or withoutmodification, is permitted provided that adherence to the followingconditions is maintained. If you do not agree with these terms,please do not use, install, modify or redistribute this software.1. Redistributions of source code must retain the above copyright notice, thislist of conditions and the following disclaimer.2. Redistributions in binary form must reproduce the above copyright notice,this list of conditions and the following disclaimer in the documentationand/or other materials provided with the distribution.THIS SOFTWARE IS PROVIDED BY IMOBILE3, LLC "AS IS" AND ANY EXPRESS ORIMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OFMERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NOEVENT SHALL IMOBILE3, LLC OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT,INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OFLIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCEOR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IFADVISED OF THE POSSIBILITY OF SUCH DAMAGE.[0]: http://loggr.net/[1]: https://github.com/aspnet/Logging
Loggr.Extensions.Logging=======================[![Build status](https://ci.appveyor.com/api/projects/status/l3snx3wl42pluf8p/branch/master?svg=true)](https://ci.appveyor.com/project/mbishopim3/loggr-framework-logging/branch/master) [![NuGet Version](http://img.shields.io/nuget/v/Loggr.Extensions.Logging.svg?style=flat)](https://www.nuget.org/packages/Loggr.Extensions.Logging/) Log to [Loggr][0] from [Microsoft.Extensions.Logging][1].Installation------------Loggr.Extensions.Logging installs through NuGet:```PS> Install-Package Loggr.Extensions.Logging```Configure the Loggr provider through code:```c#var factory = new LoggerFactory();var logger = factory.CreateLogger( "MyLog" );factory.AddLoggr( "logKey", "apiKey" );```In the example we create a new `LoggerFactory` and add the Loggr provider using the `AddLoggr` extension method with a `logKey` and `apiKey` provided by Loggr.Usage-----Log messages to Loggr, just as with every other provider:```c#logger.LogInformation( "This is information" );```This library currently uses the [loggr-dotnet][2] source directly since their NuGet package doesn't support DNX.License / Support=================Copyright 2012-2015 iMobile3, LLC. All rights reserved.Redistribution and use in source and binary forms, with or withoutmodification, is permitted provided that adherence to the followingconditions is maintained. If you do not agree with these terms,please do not use, install, modify or redistribute this software.1. Redistributions of source code must retain the above copyright notice, thislist of conditions and the following disclaimer.2. Redistributions in binary form must reproduce the above copyright notice,this list of conditions and the following disclaimer in the documentationand/or other materials provided with the distribution.THIS SOFTWARE IS PROVIDED BY IMOBILE3, LLC "AS IS" AND ANY EXPRESS ORIMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OFMERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NOEVENT SHALL IMOBILE3, LLC OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT,INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OFLIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCEOR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IFADVISED OF THE POSSIBILITY OF SUCH DAMAGE.[0]: http://loggr.net/[1]: https://github.com/aspnet/Logging[2]: https://github.com/loggr/loggr-dotnet
@@ -0,0 +1,6 @@
{
"projects": [ "src", "test" ],
"sdk": {
"version": "1.0.0-rc1-update1"
}
}

0 comments on commit f9fdee5

Please sign in to comment.
You can’t perform that action at this time.