├── .gitignore ├── CoreSrc ├── StackifyLib.NLog │ ├── Properties │ │ └── AssemblyInfo.cs │ ├── StackifyLib.NLog.xproj │ ├── StackifyTarget.cs │ ├── bin │ │ └── Debug │ │ │ ├── netcoreapp1.0 │ │ │ └── StackifyLib.NLog.deps.json │ │ │ └── netstandard1.5 │ │ │ └── StackifyLib.NLog.deps.json │ ├── obj │ │ └── Debug │ │ │ ├── netcoreapp1.0 │ │ │ ├── .SDKVersion │ │ │ ├── dotnet-compile-csc.rsp │ │ │ ├── dotnet-compile.assemblyinfo.cs │ │ │ └── dotnet-compile.rsp │ │ │ └── netstandard1.5 │ │ │ ├── .SDKVersion │ │ │ ├── dotnet-compile-csc.rsp │ │ │ ├── dotnet-compile.assemblyinfo.cs │ │ │ └── dotnet-compile.rsp │ └── project.json ├── StackifyLib.sln └── StackifyLib │ ├── API.cs │ ├── Config.cs │ ├── Extensions.cs │ ├── Internal │ ├── Logs │ │ ├── ILogClient.cs │ │ ├── LogClient.cs │ │ └── LogQueue.cs │ └── Metrics │ │ └── MetricClient.cs │ ├── Logger.cs │ ├── Metrics.cs │ ├── Models │ ├── EnvironmentDetail.cs │ ├── ErrorItem.cs │ ├── LogMessage.cs │ ├── LogMsgGroup.cs │ ├── MetricsModels.cs │ ├── MonitorModels.cs │ ├── TraceFrame.cs │ └── WebRequestDetail.cs │ ├── ProfileTracer.cs │ ├── Properties │ └── AssemblyInfo.cs │ ├── StackifyError.cs │ ├── StackifyLib.xproj │ ├── StringException.cs │ ├── Utils │ ├── DateExtensions.cs │ ├── ErrorGovernor.cs │ ├── HelperFunctions.cs │ ├── RegistryHelper.cs │ ├── SequentialGuid.cs │ ├── StackifyAPILogger.cs │ ├── StackifyHttpClient.cs │ ├── StringExtensions.cs │ └── UniqueIdGenerator.cs │ ├── Web │ └── RouteResolver.cs │ ├── bin │ └── Debug │ │ └── netstandard1.5 │ │ └── StackifyLib.deps.json │ ├── obj │ └── Debug │ │ ├── net452 │ │ ├── .SDKVersion │ │ ├── dotnet-compile-csc.rsp │ │ ├── dotnet-compile.assemblyinfo.cs │ │ └── dotnet-compile.rsp │ │ ├── netcoreapp1.0 │ │ ├── .SDKVersion │ │ └── dotnet-compile.assemblyinfo.cs │ │ ├── netstandard1.3 │ │ ├── .SDKVersion │ │ └── dotnet-compile.assemblyinfo.cs │ │ └── netstandard1.5 │ │ ├── .SDKVersion │ │ └── dotnet-compile.assemblyinfo.cs │ └── project.json ├── Dlls ├── .gitignore ├── StackifyHttpTracer │ ├── StackifyHttpTracer.nupkg │ └── StackifyPrefixModule.1.0.17.0.nupkg ├── StackifyLib.ELMAH │ ├── StackifyLib.ELMAH.dll │ ├── StackifyLib.Elmah.1.10.0.0.nupkg │ ├── StackifyLib.Elmah.1.11.0.0.nupkg │ ├── StackifyLib.Elmah.1.11.0.1.nupkg │ ├── StackifyLib.Elmah.1.15.0.0.nupkg │ ├── StackifyLib.Elmah.1.16.0.0.nupkg │ ├── StackifyLib.Elmah.1.17.0.0.nupkg │ ├── StackifyLib.Elmah.1.17.1.0.nupkg │ ├── StackifyLib.Elmah.1.17.2.0.nupkg │ ├── StackifyLib.Elmah.MVC.1.10.0.0.nupkg │ ├── StackifyLib.Elmah.MVC.1.11.0.0.nupkg │ ├── StackifyLib.Elmah.MVC.1.11.0.1.nupkg │ ├── StackifyLib.Elmah.MVC.1.15.0.0.nupkg │ ├── StackifyLib.Elmah.MVC.1.16.0.0.nupkg │ ├── StackifyLib.Elmah.MVC.1.17.0.0.nupkg │ ├── StackifyLib.Elmah.MVC.1.17.1.0.nupkg │ ├── StackifyLib.Elmah.MVC.1.17.2.0.nupkg │ ├── StackifyLib.Elmah.MVC.1.18.1.0.nupkg │ └── stackifylib.elmah.mvc.1.13.0.nupkg ├── StackifyLib.log4net.Sitecore │ └── StackifyLib.log4net.dll ├── StackifyLib.log4net.v1_2_10 │ ├── StackifyLib.log4net.dll │ ├── StackifyLib.log4net.v1_2_10.1.10.0.0.nupkg │ ├── StackifyLib.log4net.v1_2_10.1.11.0.0.nupkg │ ├── StackifyLib.log4net.v1_2_10.1.11.0.1.nupkg │ ├── StackifyLib.log4net.v1_2_10.1.15.0.0.nupkg │ ├── StackifyLib.log4net.v1_2_10.1.16.0.0.nupkg │ ├── StackifyLib.log4net.v1_2_10.1.17.0.0.nupkg │ ├── StackifyLib.log4net.v1_2_10.1.17.1.0.nupkg │ ├── StackifyLib.log4net.v1_2_10.1.17.2.0.nupkg │ ├── StackifyLib.log4net.v1_2_10.1.18.1.0.nupkg │ └── stackifylib.log4net.v1_2_10.1.13.0.nupkg ├── StackifyLib.log4net │ ├── StackifyLib.log4net.1.10.0.0.nupkg │ ├── StackifyLib.log4net.1.11.0.0.nupkg │ ├── StackifyLib.log4net.1.11.0.1.nupkg │ ├── StackifyLib.log4net.1.15.0.0.nupkg │ ├── StackifyLib.log4net.1.16.0.0.nupkg │ ├── StackifyLib.log4net.1.17.0.0.nupkg │ ├── StackifyLib.log4net.1.17.1.0.nupkg │ ├── StackifyLib.log4net.1.17.2.0.nupkg │ ├── StackifyLib.log4net.1.18.1.0.nupkg │ ├── StackifyLib.log4net.dll │ └── stackifylib.log4net.1.13.0.nupkg ├── StackifyLib.nLog │ ├── StackifyLib.nLog.1.10.0.0.nupkg │ ├── StackifyLib.nLog.1.11.0.0.nupkg │ ├── StackifyLib.nLog.1.11.0.1.nupkg │ ├── StackifyLib.nLog.1.15.1.nupkg │ ├── StackifyLib.nLog.1.16.0.nupkg │ ├── StackifyLib.nLog.1.17.0.nupkg │ ├── StackifyLib.nLog.1.17.1.nupkg │ ├── StackifyLib.nLog.1.17.2.nupkg │ ├── StackifyLib.nLog.1.18.1.nupkg │ ├── StackifyLib.nLog.dll │ └── stackifylib.nlog.1.15.0.nupkg └── StackifyLib │ ├── StackifyLib.1.10.0.0.nupkg │ ├── StackifyLib.1.11.0.0.nupkg │ ├── StackifyLib.1.15.0.0.nupkg │ ├── StackifyLib.1.16.0.0.nupkg │ ├── StackifyLib.1.17.0.0.nupkg │ ├── StackifyLib.1.18.0.0.nupkg │ ├── StackifyLib.1.20.0.0.nupkg │ ├── StackifyLib.1.21.0.0.nupkg │ ├── StackifyLib.dll │ └── stackifylib.1.14.0.nupkg ├── LICENSE ├── README.md ├── Scripts └── RemoveSignCode.ps1 ├── Src ├── .gitignore ├── CoreWebApp2.2 │ ├── Controllers │ │ └── ValuesController.cs │ ├── CoreWebApp2.2.csproj │ ├── Program.cs │ ├── Properties │ │ └── launchSettings.json │ ├── Startup.cs │ ├── appsettings.Development.json │ └── appsettings.json ├── CoreWebApp22 │ ├── CoreWebApp22.csproj │ ├── Pages │ │ ├── Error.cshtml │ │ ├── Error.cshtml.cs │ │ ├── Index.cshtml │ │ ├── Index.cshtml.cs │ │ ├── Privacy.cshtml │ │ ├── Privacy.cshtml.cs │ │ ├── Shared │ │ │ ├── _CookieConsentPartial.cshtml │ │ │ ├── _Layout.cshtml │ │ │ └── _ValidationScriptsPartial.cshtml │ │ ├── _ViewImports.cshtml │ │ └── _ViewStart.cshtml │ ├── Program.cs │ ├── Properties │ │ └── launchSettings.json │ ├── Startup.cs │ ├── appsettings.Development.json │ ├── appsettings.json │ └── wwwroot │ │ ├── css │ │ └── site.css │ │ ├── favicon.ico │ │ ├── js │ │ └── site.js │ │ └── lib │ │ ├── bootstrap │ │ ├── LICENSE │ │ └── dist │ │ │ ├── css │ │ │ ├── bootstrap-grid.css │ │ │ ├── bootstrap-grid.css.map │ │ │ ├── bootstrap-grid.min.css │ │ │ ├── bootstrap-grid.min.css.map │ │ │ ├── bootstrap-reboot.css │ │ │ ├── bootstrap-reboot.css.map │ │ │ ├── bootstrap-reboot.min.css │ │ │ ├── bootstrap-reboot.min.css.map │ │ │ ├── bootstrap.css │ │ │ ├── bootstrap.css.map │ │ │ ├── bootstrap.min.css │ │ │ └── bootstrap.min.css.map │ │ │ └── js │ │ │ ├── bootstrap.bundle.js │ │ │ ├── bootstrap.bundle.js.map │ │ │ ├── bootstrap.bundle.min.js │ │ │ ├── bootstrap.bundle.min.js.map │ │ │ ├── bootstrap.js │ │ │ ├── bootstrap.js.map │ │ │ ├── bootstrap.min.js │ │ │ └── bootstrap.min.js.map │ │ ├── jquery-validation-unobtrusive │ │ ├── LICENSE.txt │ │ ├── jquery.validate.unobtrusive.js │ │ └── jquery.validate.unobtrusive.min.js │ │ ├── jquery-validation │ │ ├── LICENSE.md │ │ └── dist │ │ │ ├── additional-methods.js │ │ │ ├── additional-methods.min.js │ │ │ ├── jquery.validate.js │ │ │ └── jquery.validate.min.js │ │ └── jquery │ │ ├── LICENSE.txt │ │ └── dist │ │ ├── jquery.js │ │ ├── jquery.min.js │ │ └── jquery.min.map ├── FFWebApp462 │ ├── App_Start │ │ ├── BundleConfig.cs │ │ ├── FilterConfig.cs │ │ ├── RouteConfig.cs │ │ └── WebApiConfig.cs │ ├── Areas │ │ └── HelpPage │ │ │ ├── ApiDescriptionExtensions.cs │ │ │ ├── App_Start │ │ │ └── HelpPageConfig.cs │ │ │ ├── Controllers │ │ │ └── HelpController.cs │ │ │ ├── HelpPage.css │ │ │ ├── HelpPageAreaRegistration.cs │ │ │ ├── HelpPageConfigurationExtensions.cs │ │ │ ├── ModelDescriptions │ │ │ ├── CollectionModelDescription.cs │ │ │ ├── ComplexTypeModelDescription.cs │ │ │ ├── DictionaryModelDescription.cs │ │ │ ├── EnumTypeModelDescription.cs │ │ │ ├── EnumValueDescription.cs │ │ │ ├── IModelDocumentationProvider.cs │ │ │ ├── KeyValuePairModelDescription.cs │ │ │ ├── ModelDescription.cs │ │ │ ├── ModelDescriptionGenerator.cs │ │ │ ├── ModelNameAttribute.cs │ │ │ ├── ModelNameHelper.cs │ │ │ ├── ParameterAnnotation.cs │ │ │ ├── ParameterDescription.cs │ │ │ └── SimpleTypeModelDescription.cs │ │ │ ├── Models │ │ │ └── HelpPageApiModel.cs │ │ │ ├── SampleGeneration │ │ │ ├── HelpPageSampleGenerator.cs │ │ │ ├── HelpPageSampleKey.cs │ │ │ ├── ImageSample.cs │ │ │ ├── InvalidSample.cs │ │ │ ├── ObjectGenerator.cs │ │ │ ├── SampleDirection.cs │ │ │ └── TextSample.cs │ │ │ ├── Views │ │ │ ├── Help │ │ │ │ ├── Api.cshtml │ │ │ │ ├── DisplayTemplates │ │ │ │ │ ├── ApiGroup.cshtml │ │ │ │ │ ├── CollectionModelDescription.cshtml │ │ │ │ │ ├── ComplexTypeModelDescription.cshtml │ │ │ │ │ ├── DictionaryModelDescription.cshtml │ │ │ │ │ ├── EnumTypeModelDescription.cshtml │ │ │ │ │ ├── HelpPageApiModel.cshtml │ │ │ │ │ ├── ImageSample.cshtml │ │ │ │ │ ├── InvalidSample.cshtml │ │ │ │ │ ├── KeyValuePairModelDescription.cshtml │ │ │ │ │ ├── ModelDescriptionLink.cshtml │ │ │ │ │ ├── Parameters.cshtml │ │ │ │ │ ├── Samples.cshtml │ │ │ │ │ ├── SimpleTypeModelDescription.cshtml │ │ │ │ │ └── TextSample.cshtml │ │ │ │ ├── Index.cshtml │ │ │ │ └── ResourceModel.cshtml │ │ │ ├── Shared │ │ │ │ └── _Layout.cshtml │ │ │ ├── Web.config │ │ │ └── _ViewStart.cshtml │ │ │ └── XmlDocumentationProvider.cs │ ├── Controllers │ │ └── ValuesController.cs │ ├── FFWebApp462.csproj │ ├── Global.asax │ ├── Global.asax.cs │ ├── Models │ │ └── ValueModel.cs │ ├── Properties │ │ └── AssemblyInfo.cs │ ├── Views │ │ ├── Shared │ │ │ ├── Error.cshtml │ │ │ └── _Layout.cshtml │ │ ├── Web.config │ │ └── _ViewStart.cshtml │ ├── Web.Debug.config │ ├── Web.Release.config │ ├── Web.config │ ├── favicon.ico │ ├── log4net.config │ └── packages.config ├── FullFrameworkWebApp │ ├── App_Start │ │ ├── BundleConfig.cs │ │ ├── FilterConfig.cs │ │ └── RouteConfig.cs │ ├── Content │ │ ├── Site.css │ │ ├── bootstrap-theme.css │ │ ├── bootstrap-theme.css.map │ │ ├── bootstrap-theme.min.css │ │ ├── bootstrap-theme.min.css.map │ │ ├── bootstrap.css │ │ ├── bootstrap.css.map │ │ ├── bootstrap.min.css │ │ └── bootstrap.min.css.map │ ├── Controllers │ │ └── HomeController.cs │ ├── FullFrameworkWebApp.csproj │ ├── Global.asax │ ├── Global.asax.cs │ ├── Properties │ │ └── AssemblyInfo.cs │ ├── Scripts │ │ ├── bootstrap.js │ │ ├── bootstrap.min.js │ │ ├── jquery-3.4.1.intellisense.js │ │ ├── jquery-3.4.1.js │ │ ├── jquery-3.4.1.min.js │ │ ├── jquery-3.4.1.min.map │ │ ├── jquery-3.4.1.slim.js │ │ ├── jquery-3.4.1.slim.min.js │ │ ├── jquery-3.4.1.slim.min.map │ │ ├── jquery.validate-vsdoc.js │ │ ├── jquery.validate.js │ │ ├── jquery.validate.min.js │ │ ├── jquery.validate.unobtrusive.js │ │ ├── jquery.validate.unobtrusive.min.js │ │ └── modernizr-2.8.3.js │ ├── Stackify.json │ ├── Views │ │ ├── Home │ │ │ ├── About.cshtml │ │ │ ├── Contact.cshtml │ │ │ └── Index.cshtml │ │ ├── Shared │ │ │ ├── Error.cshtml │ │ │ └── _Layout.cshtml │ │ ├── Web.config │ │ └── _ViewStart.cshtml │ ├── Web.Debug.config │ ├── Web.Release.config │ ├── Web.config │ ├── favicon.ico │ ├── fonts │ │ ├── glyphicons-halflings-regular.eot │ │ ├── glyphicons-halflings-regular.svg │ │ ├── glyphicons-halflings-regular.ttf │ │ ├── glyphicons-halflings-regular.woff │ │ └── glyphicons-halflings-regular.woff2 │ └── packages.config ├── NLog.Targets.Stackify │ ├── NLog.Targets.Stackify.csproj │ ├── Properties │ │ └── AssemblyInfo.cs │ └── StackifyTarget.cs ├── NLog.Web.Stackify │ ├── NLog.Web.Stackify.csproj │ └── StackifyHttpLayoutRenderer.cs ├── Package.bat ├── StackifyLib.AspNetCore │ ├── Configure.cs │ ├── Extensions.cs │ ├── Properties │ │ └── AssemblyInfo.cs │ ├── StackifyLib.AspNetCore.csproj │ └── WebRequestDetailMapper.cs ├── StackifyLib.CoreLogger │ ├── LoggingExtensions.cs │ ├── Properties │ │ └── AssemblyInfo.cs │ ├── StackifyLib.CoreLogger.csproj │ ├── StackifyLogger.cs │ └── StackifyLoggerProvider.cs ├── StackifyLib.ELMAH │ ├── Properties │ │ └── AssemblyInfo.cs │ ├── StackifyErrorLog.cs │ ├── StackifyLib.ELMAH.csproj │ └── packages.config ├── StackifyLib.NoWeb │ ├── Properties │ │ └── AssemblyInfo.cs │ ├── StackifyLib.NoWeb.csproj │ └── packages.config ├── StackifyLib.StackifyTraceListener │ ├── Properties │ │ └── AssemblyInfo.cs │ ├── StackifyLib.StackifyTraceListener.csproj │ └── StackifyTraceListener.cs ├── StackifyLib.log4net.Sitecore │ ├── Fody.targets │ ├── FodyWeavers.xml │ ├── Log4NetExtensions.cs │ ├── Properties │ │ └── AssemblyInfo.cs │ ├── StackifyAppender.cs │ ├── StackifyLib.log4net.Sitecore.csproj │ └── packages.config ├── StackifyLib.log4net.Tests │ ├── Properties │ │ └── AssemblyInfo.cs │ ├── StackifyAppenderTest.cs │ ├── StackifyLib.log4net.Tests.csproj │ └── packages.config ├── StackifyLib.log4net.v1_2_10 │ ├── ExceptionAppender.cs │ ├── Log4NetExtensions.cs │ ├── Properties │ │ └── AssemblyInfo.cs │ ├── StackifyAppender.cs │ ├── StackifyLib.log4net.v1_2_10.csproj │ └── packages.config ├── StackifyLib.log4net │ ├── ExceptionAppender.cs │ ├── Log4NetExtensions.cs │ ├── Properties │ │ └── AssemblyInfo.cs │ ├── StackifyAppender.cs │ ├── StackifyLib.log4net.csproj │ └── packages.config ├── StackifyLib.nLog │ └── StackifyLib.nLog.csproj ├── StackifyLib │ ├── API.cs │ ├── Config.cs │ ├── Extensions.cs │ ├── Internal │ │ ├── Logs │ │ │ ├── ILogClient.cs │ │ │ ├── LogClient.cs │ │ │ └── LogQueue.cs │ │ └── Metrics │ │ │ └── MetricClient.cs │ ├── Logger.cs │ ├── Metrics.cs │ ├── Models │ │ ├── AzureConfig.cs │ │ ├── EnvironmentDetail.cs │ │ ├── ErrorItem.cs │ │ ├── LogMessage.cs │ │ ├── LogMsgGroup.cs │ │ ├── MetricsModels.cs │ │ ├── MonitorModels.cs │ │ ├── TraceFrame.cs │ │ └── WebRequestDetail.cs │ ├── ProfileTracer.cs │ ├── Properties │ │ └── AssemblyInfo.cs │ ├── StackifyError.cs │ ├── StackifyLib.csproj │ ├── StringException.cs │ ├── Utils │ │ ├── AsyncTracer.cs │ │ ├── DateExtensions.cs │ │ ├── ErrorGovernor.cs │ │ ├── EtwEventListener.cs │ │ ├── HelperFunctions.cs │ │ ├── HighPrecisionTime.cs │ │ ├── HttpClient.cs │ │ ├── PrefixOrAPM.cs │ │ ├── RegistryHelper.cs │ │ ├── SequentialGuid.cs │ │ ├── ServerConfigHelper.cs │ │ ├── StackifyAPILogger.cs │ │ ├── StringExtensions.cs │ │ └── UniqueIdGenerator.cs │ └── Web │ │ ├── ErrorLoggerHttpModule.cs │ │ ├── RealUserMonitoring.cs │ │ └── RouteResolver.cs ├── StackifyLibCore.sln └── packages │ └── repositories.config ├── appveyor.yml ├── azure-pipelines.yml ├── build.ps1 ├── log4netinstalled.md ├── samples ├── CoreConsoleApp │ ├── CoreConsoleApp.csproj │ ├── NLog.config │ ├── Program.cs │ ├── Properties │ │ ├── AssemblyInfo.cs │ │ └── launchSettings.json │ ├── Stackify-empty.json │ ├── Stackify.Production.json │ ├── Stackify.json │ ├── appsettings.json │ └── log4net.config └── CoreWebApp │ ├── .vs │ └── CoreWebApp │ │ └── config │ │ └── applicationhost.config │ ├── ApplicationLogging.cs │ ├── Controllers │ ├── SomeOtherClass.cs │ └── ValuesController.cs │ ├── CoreWebApp.csproj │ ├── Models │ └── ValueModel.cs │ ├── NLog.config │ ├── Program.cs │ ├── Project_Readme.html │ ├── Properties │ └── launchSettings.json │ ├── Stackify.Development.json │ ├── Stackify.Production.json │ ├── Stackify.json │ ├── Startup.cs │ ├── appsettings.json │ └── web.config ├── templates └── build-and-pack.yml └── test └── StackifyLib.UnitTests ├── ConfigJSON_Tests.cs ├── Fixtures └── JsonConfig │ ├── Stackify-Empty.json │ ├── Stackify-Invalid-Format.json │ ├── Stackify-Invalid-Property-Type.json │ ├── Stackify-With-Comment.json │ └── Stackify.json ├── JsonSerialization_Tests.cs ├── Models ├── EnvironmentDetail_Tests.cs └── ErrorItem_Tests.cs └── StackifyLib.UnitTests.csproj /.gitignore: -------------------------------------------------------------------------------- 1 | #Ignore thumbnails created by Windows 2 | Thumbs.db 3 | 4 | #Ignore files built by Visual Studio 5 | *.obj 6 | *.exe 7 | *.pdb 8 | *.user 9 | *.aps 10 | *.pch 11 | *.vspscc 12 | *_i.c 13 | *_p.c 14 | *.ncb 15 | *.suo 16 | *.tlb 17 | *.tlh 18 | *.bak 19 | *.cache 20 | *.ilk 21 | *.log 22 | *.dll 23 | *.lib 24 | *.sbr 25 | .idea/ 26 | _ReSharper.Caches/ 27 | packages/ 28 | *.lock.json 29 | 30 | **/bin/* 31 | **/obj/* 32 | BuildOutput/ 33 | *.pfx 34 | *.snk 35 | /.vs -------------------------------------------------------------------------------- /CoreSrc/StackifyLib.NLog/Properties/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | using System.Reflection; 2 | using System.Runtime.CompilerServices; 3 | using System.Runtime.InteropServices; 4 | 5 | // General Information about an assembly is controlled through the following 6 | // set of attributes. Change these attribute values to modify the information 7 | // associated with an assembly. 8 | [assembly: AssemblyConfiguration("")] 9 | [assembly: AssemblyCompany("")] 10 | [assembly: AssemblyProduct("StackifyLib.NLog")] 11 | [assembly: AssemblyTrademark("")] 12 | 13 | // Setting ComVisible to false makes the types in this assembly not visible 14 | // to COM components. If you need to access a type in this assembly from 15 | // COM, set the ComVisible attribute to true on that type. 16 | [assembly: ComVisible(false)] 17 | 18 | // The following GUID is for the ID of the typelib if this project is exposed to COM 19 | [assembly: Guid("55cc4568-242f-40d7-9bd3-23c4f502c161")] 20 | -------------------------------------------------------------------------------- /CoreSrc/StackifyLib.NLog/StackifyLib.NLog.xproj: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 14.0 5 | $(MSBuildExtensionsPath32)\Microsoft\VisualStudio\v$(VisualStudioVersion) 6 | 7 | 8 | 9 | 10 | 55cc4568-242f-40d7-9bd3-23c4f502c161 11 | StackifyLib.NLog 12 | .\obj 13 | .\bin\ 14 | v4.5.2 15 | 16 | 17 | 18 | 2.0 19 | 20 | 21 | 22 | -------------------------------------------------------------------------------- /CoreSrc/StackifyLib.NLog/obj/Debug/netcoreapp1.0/.SDKVersion: -------------------------------------------------------------------------------- 1 | 37f00f24e961efa4b06c380a7b944e54cc6f8515 2 | 1.0.0-rc2-002416 3 | 4 | win10-x64 -------------------------------------------------------------------------------- /CoreSrc/StackifyLib.NLog/obj/Debug/netcoreapp1.0/dotnet-compile.assemblyinfo.cs: -------------------------------------------------------------------------------- 1 | // This file has been auto generated. 2 | [assembly:System.Reflection.AssemblyFileVersionAttribute("1.0.0.0")] 3 | [assembly:System.Reflection.AssemblyVersionAttribute("1.0.0.0")] 4 | [assembly:System.Reflection.AssemblyInformationalVersionAttribute("1.0.0")] 5 | [assembly:System.Runtime.Versioning.TargetFrameworkAttribute(".NETCoreApp,Version=v1.0")] -------------------------------------------------------------------------------- /CoreSrc/StackifyLib.NLog/obj/Debug/netstandard1.5/.SDKVersion: -------------------------------------------------------------------------------- 1 | 37f00f24e961efa4b06c380a7b944e54cc6f8515 2 | 1.0.0-rc2-002416 3 | 4 | win10-x64 -------------------------------------------------------------------------------- /CoreSrc/StackifyLib.NLog/obj/Debug/netstandard1.5/dotnet-compile.assemblyinfo.cs: -------------------------------------------------------------------------------- 1 | // This file has been auto generated. 2 | [assembly:System.Reflection.AssemblyFileVersionAttribute("1.0.0.0")] 3 | [assembly:System.Reflection.AssemblyVersionAttribute("1.0.0.0")] 4 | [assembly:System.Reflection.AssemblyInformationalVersionAttribute("1.0.0")] 5 | [assembly:System.Runtime.Versioning.TargetFrameworkAttribute(".NETStandard,Version=v1.5")] -------------------------------------------------------------------------------- /CoreSrc/StackifyLib.NLog/project.json: -------------------------------------------------------------------------------- 1 | { 2 | "version": "1.0.0-*", 3 | 4 | "dependencies": { 5 | "NETStandard.Library": "1.5.0-rc2-24027", 6 | "StackifyLib": "1.0.0-*", 7 | "NLog": "4.4.0-beta9" 8 | 9 | }, 10 | 11 | "frameworks": { 12 | "netstandard1.5": { 13 | "imports": "dnxcore50" 14 | }, 15 | "netcoreapp1.0": { 16 | "imports": [ 17 | "dotnet5.6", 18 | "dnxcore50", 19 | "portable-net45+win8" 20 | ] 21 | } 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /CoreSrc/StackifyLib.sln: -------------------------------------------------------------------------------- 1 |  2 | Microsoft Visual Studio Solution File, Format Version 12.00 3 | # Visual Studio 14 4 | VisualStudioVersion = 14.0.25123.0 5 | MinimumVisualStudioVersion = 10.0.40219.1 6 | Project("{8BB2217D-0F2D-49D1-97BC-3654ED321F3B}") = "StackifyLib", "StackifyLib\StackifyLib.xproj", "{E1A20789-60A0-4C04-8FD8-C6213329CA2C}" 7 | EndProject 8 | Project("{8BB2217D-0F2D-49D1-97BC-3654ED321F3B}") = "StackifyLib.NLog", "StackifyLib.NLog\StackifyLib.NLog.xproj", "{55CC4568-242F-40D7-9BD3-23C4F502C161}" 9 | EndProject 10 | Global 11 | GlobalSection(SolutionConfigurationPlatforms) = preSolution 12 | Debug|Any CPU = Debug|Any CPU 13 | Release|Any CPU = Release|Any CPU 14 | EndGlobalSection 15 | GlobalSection(ProjectConfigurationPlatforms) = postSolution 16 | {E1A20789-60A0-4C04-8FD8-C6213329CA2C}.Debug|Any CPU.ActiveCfg = Debug|Any CPU 17 | {E1A20789-60A0-4C04-8FD8-C6213329CA2C}.Debug|Any CPU.Build.0 = Debug|Any CPU 18 | {E1A20789-60A0-4C04-8FD8-C6213329CA2C}.Release|Any CPU.ActiveCfg = Release|Any CPU 19 | {E1A20789-60A0-4C04-8FD8-C6213329CA2C}.Release|Any CPU.Build.0 = Release|Any CPU 20 | {55CC4568-242F-40D7-9BD3-23C4F502C161}.Debug|Any CPU.ActiveCfg = Debug|Any CPU 21 | {55CC4568-242F-40D7-9BD3-23C4F502C161}.Debug|Any CPU.Build.0 = Debug|Any CPU 22 | {55CC4568-242F-40D7-9BD3-23C4F502C161}.Release|Any CPU.ActiveCfg = Release|Any CPU 23 | {55CC4568-242F-40D7-9BD3-23C4F502C161}.Release|Any CPU.Build.0 = Release|Any CPU 24 | EndGlobalSection 25 | GlobalSection(SolutionProperties) = preSolution 26 | HideSolutionNode = FALSE 27 | EndGlobalSection 28 | EndGlobal 29 | -------------------------------------------------------------------------------- /CoreSrc/StackifyLib/Extensions.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections; 3 | using System.Collections.Generic; 4 | using System.ComponentModel; 5 | using System.Diagnostics; 6 | using System.Linq; 7 | using System.Text; 8 | using System.Threading.Tasks; 9 | 10 | namespace StackifyLib 11 | { 12 | public static class Extensions 13 | { 14 | public static void SendToStackify(this Exception ex) 15 | { 16 | try 17 | { 18 | StackifyLib.StackifyError.New(ex).SendToStackify(); 19 | } 20 | catch (Exception e) 21 | { 22 | Debug.WriteLine("Error submitting error to Stackify " + e.ToString()); 23 | throw; 24 | } 25 | } 26 | 27 | public static StackifyLib.StackifyError NewStackifyError(this Exception ex) 28 | { 29 | try 30 | { 31 | return StackifyLib.StackifyError.New(ex); 32 | } 33 | catch (Exception e) 34 | { 35 | Debug.WriteLine("Error submitting error to Stackify " + e.ToString()); 36 | throw; 37 | } 38 | } 39 | } 40 | } 41 | -------------------------------------------------------------------------------- /CoreSrc/StackifyLib/Internal/Logs/ILogClient.cs: -------------------------------------------------------------------------------- 1 | using StackifyLib.Models; 2 | using StackifyLib.Utils; 3 | 4 | namespace StackifyLib.Internal.Logs 5 | { 6 | public interface ILogClient 7 | { 8 | bool CanQueue(); 9 | bool CanSend(); 10 | bool CanUpload(); 11 | void Close(); 12 | bool ErrorShouldBeSent(StackifyError error); 13 | AppIdentityInfo GetIdentity(); 14 | bool IsAuthorized(); 15 | void PauseUpload(bool isPaused); 16 | void QueueMessage(LogMsg msg); 17 | } 18 | } -------------------------------------------------------------------------------- /CoreSrc/StackifyLib/Models/LogMessage.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | using Newtonsoft.Json; 6 | 7 | namespace StackifyLib.Models 8 | { 9 | 10 | /// 11 | /// Helper class for logging a message and object both 12 | /// 13 | public class LogMessage 14 | { 15 | public object json { get; set; } 16 | public string message { get; set; } 17 | 18 | public override string ToString() 19 | { 20 | if (json != null) 21 | { 22 | return message + " " + JsonConvert.SerializeObject(json, new JsonSerializerSettings{ReferenceLoopHandling = ReferenceLoopHandling.Serialize}); 23 | } 24 | else 25 | { 26 | return message; 27 | } 28 | } 29 | } 30 | } 31 | -------------------------------------------------------------------------------- /CoreSrc/StackifyLib/Models/MonitorModels.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | 6 | namespace StackifyLib.Models 7 | { 8 | public class Device 9 | { 10 | public int Id { get; set; } 11 | public string Name { get; set; } 12 | public string Alias { get; set; } 13 | public string Env { get; set; } 14 | public int? EnvId { get; set; } 15 | public string Loc { get; set; } 16 | public int? LocId { get; set; } 17 | public string Alerts { get; set; } 18 | } 19 | 20 | public class Monitor 21 | { 22 | public int Id { get; set; } 23 | public short? MonitorTypeId { get; set; } 24 | public bool? IsHeading { get; set; } 25 | public string Desc { get; set; } 26 | public int? SortOrder { get; set; } 27 | public DateTime? LastCheck { get; set; } 28 | public string Status { get; set; } 29 | public string SparkLine { get; set; } 30 | public int? CurrentSevId { get; set; } 31 | public int? AlertingSevId { get; set; } 32 | public int? MonitorRelationId { get; set; } 33 | } 34 | 35 | public class MonitorMetric 36 | { 37 | public List Metrics { get; set; } 38 | public float? Min { get; set; } 39 | public float? Max { get; set; } 40 | public float? Avg { get; set; } 41 | public string MonitorDesc { get; set; } 42 | public string Units { get; set; } 43 | public int? MonitorTypeId { get; set; } 44 | 45 | public class Metric 46 | { 47 | public DateTime Dt { get; set; } 48 | public double? Val { get; set; } 49 | } 50 | } 51 | } 52 | -------------------------------------------------------------------------------- /CoreSrc/StackifyLib/Models/TraceFrame.cs: -------------------------------------------------------------------------------- 1 |  2 | using System.Runtime.Serialization; 3 | using Newtonsoft.Json; 4 | 5 | namespace StackifyLib.Models 6 | { 7 | public class TraceFrame 8 | { 9 | [JsonProperty] 10 | public int? LineNum { get; set; } 11 | [JsonProperty] 12 | public string Method { get; set; } 13 | [JsonProperty] 14 | public string CodeFileName { get; set; } 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /CoreSrc/StackifyLib/Properties/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | using System.Reflection; 2 | using System.Runtime.CompilerServices; 3 | using System.Runtime.InteropServices; 4 | 5 | // General Information about an assembly is controlled through the following 6 | // set of attributes. Change these attribute values to modify the information 7 | // associated with an assembly. 8 | [assembly: AssemblyConfiguration("")] 9 | [assembly: AssemblyCompany("")] 10 | [assembly: AssemblyProduct("StackifyLib")] 11 | [assembly: AssemblyTrademark("")] 12 | 13 | // Setting ComVisible to false makes the types in this assembly not visible 14 | // to COM components. If you need to access a type in this assembly from 15 | // COM, set the ComVisible attribute to true on that type. 16 | [assembly: ComVisible(false)] 17 | 18 | // The following GUID is for the ID of the typelib if this project is exposed to COM 19 | [assembly: Guid("e1a20789-60a0-4c04-8fd8-c6213329ca2c")] 20 | -------------------------------------------------------------------------------- /CoreSrc/StackifyLib/StackifyLib.xproj: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 14.0 5 | $(MSBuildExtensionsPath32)\Microsoft\VisualStudio\v$(VisualStudioVersion) 6 | 7 | 8 | 9 | 10 | e1a20789-60a0-4c04-8fd8-c6213329ca2c 11 | StackifyLib 12 | .\obj 13 | .\bin\ 14 | v4.5.2 15 | 16 | 17 | 18 | 2.0 19 | 20 | 21 | 22 | -------------------------------------------------------------------------------- /CoreSrc/StackifyLib/StringException.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections; 3 | using System.Collections.Generic; 4 | using System.Diagnostics; 5 | using System.Linq; 6 | using System.Reflection; 7 | using System.Text; 8 | using System.Threading.Tasks; 9 | using StackifyLib.Models; 10 | 11 | namespace StackifyLib 12 | { 13 | /// 14 | /// Used when someone logs an error but only logs a string with no exception 15 | /// 16 | public class StringException : Exception 17 | { 18 | public StringException(string message) 19 | : base(message) 20 | { 21 | 22 | } 23 | 24 | //Used to hold the stack trace for the exception and we have to manually figure it out 25 | public List TraceFrames { get; set; } 26 | } 27 | } 28 | 29 | /* 30 | * Example usage from log4net appender 31 | * 32 | StringException stringEx = new StringException(loggingEvent.RenderedMessage); 33 | stringEx.TraceFrames = new List(); 34 | 35 | 36 | stringEx.TraceFrames = StackifyLib.Logger.GetCurrentStackTrace(loggingEvent.LoggerName); 37 | 38 | if (stringEx.TraceFrames.Any()) 39 | { 40 | var first = stringEx.TraceFrames.First(); 41 | 42 | msg.SrcMethod = first.Method; 43 | msg.SrcLine = first.LineNum; 44 | } 45 | 46 | //Make error out of log message 47 | error = StackifyError.New(stringEx); 48 | 49 | 50 | */ -------------------------------------------------------------------------------- /CoreSrc/StackifyLib/Utils/DateExtensions.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | 6 | namespace StackifyLib.Utils 7 | { 8 | internal static class DateExtensions 9 | { 10 | public static DateTime Round(this DateTime date, TimeSpan span) 11 | { 12 | long ticks = (date.Ticks + (span.Ticks / 2) + 1) / span.Ticks; 13 | return new DateTime(ticks * span.Ticks, date.Kind); 14 | } 15 | public static DateTime Floor(this DateTime date, TimeSpan span) 16 | { 17 | long ticks = (date.Ticks / span.Ticks); 18 | return new DateTime(ticks * span.Ticks, date.Kind); 19 | } 20 | public static DateTime Ceil(this DateTime date, TimeSpan span) 21 | { 22 | long ticks = (date.Ticks + span.Ticks - 1) / span.Ticks; 23 | return new DateTime(ticks * span.Ticks, date.Kind); 24 | } 25 | 26 | /// 27 | /// Calculates the Unix epoch for the date 28 | /// 29 | /// The Unix epoch 30 | public static long ToUnixEpoch(this DateTime date) 31 | { 32 | return (date.Ticks - 621355968000000000) / 10000000; 33 | } 34 | 35 | /// 36 | /// Calculates the Unix epoch minutes for the date 37 | /// 38 | /// The Unix epoch minutes 39 | public static long ToUnixEpochMinutes(this DateTime date) 40 | { 41 | return date.ToUnixEpoch() / 60; 42 | } 43 | } 44 | } 45 | -------------------------------------------------------------------------------- /CoreSrc/StackifyLib/Utils/RegistryHelper.cs: -------------------------------------------------------------------------------- 1 | //using System; 2 | //using System.Collections.Generic; 3 | //using System.Linq; 4 | //using System.Text; 5 | //using Microsoft.Win32; 6 | 7 | //namespace StackifyLib.Utils 8 | //{ 9 | // public static class RegistryHelper 10 | // { 11 | // public static RegistryKey GetRegistryKey(string keyPath, bool writeable = false) 12 | // { 13 | // RegistryKey localMachineRegistry 14 | // = RegistryKey.OpenBaseKey(RegistryHive.LocalMachine, 15 | // Environment.Is64BitOperatingSystem 16 | // ? RegistryView.Registry64 17 | // : RegistryView.Registry32); 18 | 19 | // return string.IsNullOrEmpty(keyPath) 20 | // ? localMachineRegistry 21 | // : localMachineRegistry.OpenSubKey(keyPath, writeable); 22 | // } 23 | 24 | // public static object GetRegistryValue(string keyPath, string keyName) 25 | // { 26 | // RegistryKey registry = GetRegistryKey(keyPath); 27 | // return registry.GetValue(keyName); 28 | // } 29 | // } 30 | //} 31 | -------------------------------------------------------------------------------- /CoreSrc/StackifyLib/Utils/SequentialGuid.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Runtime.InteropServices; 5 | using System.Text; 6 | 7 | namespace StackifyLib.Utils 8 | { 9 | public static class SequentialGuid 10 | { 11 | [DllImport("rpcrt4.dll", SetLastError = true)] 12 | private static extern int UuidCreateSequential(out Guid guid); 13 | 14 | public static Guid NewGuid() 15 | { 16 | const int RPC_S_OK = 0; 17 | 18 | Guid guid; 19 | int result = UuidCreateSequential(out guid); 20 | if (result == RPC_S_OK) 21 | { 22 | return guid; 23 | } 24 | 25 | return Guid.NewGuid(); 26 | } 27 | } 28 | } 29 | -------------------------------------------------------------------------------- /CoreSrc/StackifyLib/Utils/StringExtensions.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Security.Cryptography; 5 | using System.Text; 6 | 7 | namespace StackifyLib.Utils 8 | { 9 | /// 10 | /// String extension methods 11 | /// 12 | internal static class StringExtensions 13 | { 14 | /// 15 | /// Calculates the MD5 hash of the string 16 | /// 17 | /// The MD5 hash of the string as a hex string 18 | public static string ToMD5Hash(this string input) 19 | { 20 | // step 1, calculate MD5 hash from input 21 | MD5 md5 = System.Security.Cryptography.MD5.Create(); 22 | byte[] inputBytes = System.Text.Encoding.ASCII.GetBytes(input); 23 | byte[] hash = md5.ComputeHash(inputBytes); 24 | 25 | // step 2, convert byte array to hex string 26 | StringBuilder sb = new StringBuilder(); 27 | for (int i = 0; i < hash.Length; i++) 28 | { 29 | sb.Append(hash[i].ToString("X2")); 30 | } 31 | return sb.ToString(); 32 | } 33 | } 34 | } 35 | -------------------------------------------------------------------------------- /CoreSrc/StackifyLib/obj/Debug/net452/.SDKVersion: -------------------------------------------------------------------------------- 1 | 37f00f24e961efa4b06c380a7b944e54cc6f8515 2 | 1.0.0-rc2-002416 3 | 4 | win10-x64 -------------------------------------------------------------------------------- /CoreSrc/StackifyLib/obj/Debug/net452/dotnet-compile.assemblyinfo.cs: -------------------------------------------------------------------------------- 1 | // This file has been auto generated. 2 | [assembly:System.Reflection.AssemblyFileVersionAttribute("1.0.0.0")] 3 | [assembly:System.Reflection.AssemblyVersionAttribute("1.0.0.0")] 4 | [assembly:System.Reflection.AssemblyInformationalVersionAttribute("1.0.0")] 5 | [assembly:System.Runtime.Versioning.TargetFrameworkAttribute(".NETFramework,Version=v4.5.2")] -------------------------------------------------------------------------------- /CoreSrc/StackifyLib/obj/Debug/netcoreapp1.0/.SDKVersion: -------------------------------------------------------------------------------- 1 | 37f00f24e961efa4b06c380a7b944e54cc6f8515 2 | 1.0.0-rc2-002416 3 | 4 | win10-x64 -------------------------------------------------------------------------------- /CoreSrc/StackifyLib/obj/Debug/netcoreapp1.0/dotnet-compile.assemblyinfo.cs: -------------------------------------------------------------------------------- 1 | // This file has been auto generated. 2 | [assembly:System.Reflection.AssemblyFileVersionAttribute("1.0.0.0")] 3 | [assembly:System.Reflection.AssemblyVersionAttribute("1.0.0.0")] 4 | [assembly:System.Reflection.AssemblyInformationalVersionAttribute("1.0.0")] 5 | [assembly:System.Runtime.Versioning.TargetFrameworkAttribute(".NETCoreApp,Version=v1.0")] -------------------------------------------------------------------------------- /CoreSrc/StackifyLib/obj/Debug/netstandard1.3/.SDKVersion: -------------------------------------------------------------------------------- 1 | 37f00f24e961efa4b06c380a7b944e54cc6f8515 2 | 1.0.0-rc2-002416 3 | 4 | win10-x64 -------------------------------------------------------------------------------- /CoreSrc/StackifyLib/obj/Debug/netstandard1.3/dotnet-compile.assemblyinfo.cs: -------------------------------------------------------------------------------- 1 | // This file has been auto generated. 2 | [assembly:System.Reflection.AssemblyFileVersionAttribute("1.0.0.0")] 3 | [assembly:System.Reflection.AssemblyVersionAttribute("1.0.0.0")] 4 | [assembly:System.Reflection.AssemblyInformationalVersionAttribute("1.0.0")] 5 | [assembly:System.Runtime.Versioning.TargetFrameworkAttribute(".NETStandard,Version=v1.3")] -------------------------------------------------------------------------------- /CoreSrc/StackifyLib/obj/Debug/netstandard1.5/.SDKVersion: -------------------------------------------------------------------------------- 1 | 37f00f24e961efa4b06c380a7b944e54cc6f8515 2 | 1.0.0-rc2-002416 3 | 4 | win10-x64 -------------------------------------------------------------------------------- /CoreSrc/StackifyLib/obj/Debug/netstandard1.5/dotnet-compile.assemblyinfo.cs: -------------------------------------------------------------------------------- 1 | // This file has been auto generated. 2 | [assembly:System.Reflection.AssemblyFileVersionAttribute("1.0.0.0")] 3 | [assembly:System.Reflection.AssemblyVersionAttribute("1.0.0.0")] 4 | [assembly:System.Reflection.AssemblyInformationalVersionAttribute("1.0.0")] 5 | [assembly:System.Runtime.Versioning.TargetFrameworkAttribute(".NETStandard,Version=v1.5")] -------------------------------------------------------------------------------- /CoreSrc/StackifyLib/project.json: -------------------------------------------------------------------------------- 1 | { 2 | "version": "1.0.0-*", 3 | 4 | "dependencies": { 5 | "NETStandard.Library": "1.5.0-rc2-24027", 6 | "Newtonsoft.Json": "8.0.3", 7 | "System.Diagnostics.StackTrace": "4.0.1-rc2-24027", 8 | "System.Diagnostics.Process": "4.1.0-rc2-24027", 9 | "System.Net.Requests": "4.0.11-rc2-24027", 10 | "System.Security.Cryptography.Algorithms": "4.1.0-rc2-24027", 11 | "System.Dynamic.Runtime": "4.0.11-rc2-24027", 12 | "System.Runtime.Extensions": "4.1.0-rc2-24027", 13 | "System.Reflection": "4.1.0-rc2-24027", 14 | "System.Reflection.TypeExtensions": "4.1.0-rc2-24027" 15 | }, 16 | 17 | "frameworks": { 18 | "netstandard1.3": { 19 | "imports": "dnxcore50" 20 | }, 21 | "netstandard1.6": { 22 | "imports": "dnxcore50" 23 | }, 24 | "netcoreapp1.0": { 25 | "imports": [ 26 | "dotnet5.6", 27 | "dnxcore50", 28 | "portable-net45+win8" 29 | ] 30 | } 31 | } 32 | } 33 | -------------------------------------------------------------------------------- /Dlls/.gitignore: -------------------------------------------------------------------------------- 1 | !* -------------------------------------------------------------------------------- /Dlls/StackifyHttpTracer/StackifyHttpTracer.nupkg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stackify/stackify-api-dotnet/43f462adc665788e342d01bb8f5261a59636ea0d/Dlls/StackifyHttpTracer/StackifyHttpTracer.nupkg -------------------------------------------------------------------------------- /Dlls/StackifyHttpTracer/StackifyPrefixModule.1.0.17.0.nupkg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stackify/stackify-api-dotnet/43f462adc665788e342d01bb8f5261a59636ea0d/Dlls/StackifyHttpTracer/StackifyPrefixModule.1.0.17.0.nupkg -------------------------------------------------------------------------------- /Dlls/StackifyLib.ELMAH/StackifyLib.ELMAH.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stackify/stackify-api-dotnet/43f462adc665788e342d01bb8f5261a59636ea0d/Dlls/StackifyLib.ELMAH/StackifyLib.ELMAH.dll -------------------------------------------------------------------------------- /Dlls/StackifyLib.ELMAH/StackifyLib.Elmah.1.10.0.0.nupkg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stackify/stackify-api-dotnet/43f462adc665788e342d01bb8f5261a59636ea0d/Dlls/StackifyLib.ELMAH/StackifyLib.Elmah.1.10.0.0.nupkg -------------------------------------------------------------------------------- /Dlls/StackifyLib.ELMAH/StackifyLib.Elmah.1.11.0.0.nupkg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stackify/stackify-api-dotnet/43f462adc665788e342d01bb8f5261a59636ea0d/Dlls/StackifyLib.ELMAH/StackifyLib.Elmah.1.11.0.0.nupkg -------------------------------------------------------------------------------- /Dlls/StackifyLib.ELMAH/StackifyLib.Elmah.1.11.0.1.nupkg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stackify/stackify-api-dotnet/43f462adc665788e342d01bb8f5261a59636ea0d/Dlls/StackifyLib.ELMAH/StackifyLib.Elmah.1.11.0.1.nupkg -------------------------------------------------------------------------------- /Dlls/StackifyLib.ELMAH/StackifyLib.Elmah.1.15.0.0.nupkg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stackify/stackify-api-dotnet/43f462adc665788e342d01bb8f5261a59636ea0d/Dlls/StackifyLib.ELMAH/StackifyLib.Elmah.1.15.0.0.nupkg -------------------------------------------------------------------------------- /Dlls/StackifyLib.ELMAH/StackifyLib.Elmah.1.16.0.0.nupkg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stackify/stackify-api-dotnet/43f462adc665788e342d01bb8f5261a59636ea0d/Dlls/StackifyLib.ELMAH/StackifyLib.Elmah.1.16.0.0.nupkg -------------------------------------------------------------------------------- /Dlls/StackifyLib.ELMAH/StackifyLib.Elmah.1.17.0.0.nupkg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stackify/stackify-api-dotnet/43f462adc665788e342d01bb8f5261a59636ea0d/Dlls/StackifyLib.ELMAH/StackifyLib.Elmah.1.17.0.0.nupkg -------------------------------------------------------------------------------- /Dlls/StackifyLib.ELMAH/StackifyLib.Elmah.1.17.1.0.nupkg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stackify/stackify-api-dotnet/43f462adc665788e342d01bb8f5261a59636ea0d/Dlls/StackifyLib.ELMAH/StackifyLib.Elmah.1.17.1.0.nupkg -------------------------------------------------------------------------------- /Dlls/StackifyLib.ELMAH/StackifyLib.Elmah.1.17.2.0.nupkg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stackify/stackify-api-dotnet/43f462adc665788e342d01bb8f5261a59636ea0d/Dlls/StackifyLib.ELMAH/StackifyLib.Elmah.1.17.2.0.nupkg -------------------------------------------------------------------------------- /Dlls/StackifyLib.ELMAH/StackifyLib.Elmah.MVC.1.10.0.0.nupkg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stackify/stackify-api-dotnet/43f462adc665788e342d01bb8f5261a59636ea0d/Dlls/StackifyLib.ELMAH/StackifyLib.Elmah.MVC.1.10.0.0.nupkg -------------------------------------------------------------------------------- /Dlls/StackifyLib.ELMAH/StackifyLib.Elmah.MVC.1.11.0.0.nupkg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stackify/stackify-api-dotnet/43f462adc665788e342d01bb8f5261a59636ea0d/Dlls/StackifyLib.ELMAH/StackifyLib.Elmah.MVC.1.11.0.0.nupkg -------------------------------------------------------------------------------- /Dlls/StackifyLib.ELMAH/StackifyLib.Elmah.MVC.1.11.0.1.nupkg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stackify/stackify-api-dotnet/43f462adc665788e342d01bb8f5261a59636ea0d/Dlls/StackifyLib.ELMAH/StackifyLib.Elmah.MVC.1.11.0.1.nupkg -------------------------------------------------------------------------------- /Dlls/StackifyLib.ELMAH/StackifyLib.Elmah.MVC.1.15.0.0.nupkg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stackify/stackify-api-dotnet/43f462adc665788e342d01bb8f5261a59636ea0d/Dlls/StackifyLib.ELMAH/StackifyLib.Elmah.MVC.1.15.0.0.nupkg -------------------------------------------------------------------------------- /Dlls/StackifyLib.ELMAH/StackifyLib.Elmah.MVC.1.16.0.0.nupkg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stackify/stackify-api-dotnet/43f462adc665788e342d01bb8f5261a59636ea0d/Dlls/StackifyLib.ELMAH/StackifyLib.Elmah.MVC.1.16.0.0.nupkg -------------------------------------------------------------------------------- /Dlls/StackifyLib.ELMAH/StackifyLib.Elmah.MVC.1.17.0.0.nupkg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stackify/stackify-api-dotnet/43f462adc665788e342d01bb8f5261a59636ea0d/Dlls/StackifyLib.ELMAH/StackifyLib.Elmah.MVC.1.17.0.0.nupkg -------------------------------------------------------------------------------- /Dlls/StackifyLib.ELMAH/StackifyLib.Elmah.MVC.1.17.1.0.nupkg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stackify/stackify-api-dotnet/43f462adc665788e342d01bb8f5261a59636ea0d/Dlls/StackifyLib.ELMAH/StackifyLib.Elmah.MVC.1.17.1.0.nupkg -------------------------------------------------------------------------------- /Dlls/StackifyLib.ELMAH/StackifyLib.Elmah.MVC.1.17.2.0.nupkg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stackify/stackify-api-dotnet/43f462adc665788e342d01bb8f5261a59636ea0d/Dlls/StackifyLib.ELMAH/StackifyLib.Elmah.MVC.1.17.2.0.nupkg -------------------------------------------------------------------------------- /Dlls/StackifyLib.ELMAH/StackifyLib.Elmah.MVC.1.18.1.0.nupkg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stackify/stackify-api-dotnet/43f462adc665788e342d01bb8f5261a59636ea0d/Dlls/StackifyLib.ELMAH/StackifyLib.Elmah.MVC.1.18.1.0.nupkg -------------------------------------------------------------------------------- /Dlls/StackifyLib.ELMAH/stackifylib.elmah.mvc.1.13.0.nupkg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stackify/stackify-api-dotnet/43f462adc665788e342d01bb8f5261a59636ea0d/Dlls/StackifyLib.ELMAH/stackifylib.elmah.mvc.1.13.0.nupkg -------------------------------------------------------------------------------- /Dlls/StackifyLib.log4net.Sitecore/StackifyLib.log4net.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stackify/stackify-api-dotnet/43f462adc665788e342d01bb8f5261a59636ea0d/Dlls/StackifyLib.log4net.Sitecore/StackifyLib.log4net.dll -------------------------------------------------------------------------------- /Dlls/StackifyLib.log4net.v1_2_10/StackifyLib.log4net.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stackify/stackify-api-dotnet/43f462adc665788e342d01bb8f5261a59636ea0d/Dlls/StackifyLib.log4net.v1_2_10/StackifyLib.log4net.dll -------------------------------------------------------------------------------- /Dlls/StackifyLib.log4net.v1_2_10/StackifyLib.log4net.v1_2_10.1.10.0.0.nupkg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stackify/stackify-api-dotnet/43f462adc665788e342d01bb8f5261a59636ea0d/Dlls/StackifyLib.log4net.v1_2_10/StackifyLib.log4net.v1_2_10.1.10.0.0.nupkg -------------------------------------------------------------------------------- /Dlls/StackifyLib.log4net.v1_2_10/StackifyLib.log4net.v1_2_10.1.11.0.0.nupkg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stackify/stackify-api-dotnet/43f462adc665788e342d01bb8f5261a59636ea0d/Dlls/StackifyLib.log4net.v1_2_10/StackifyLib.log4net.v1_2_10.1.11.0.0.nupkg -------------------------------------------------------------------------------- /Dlls/StackifyLib.log4net.v1_2_10/StackifyLib.log4net.v1_2_10.1.11.0.1.nupkg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stackify/stackify-api-dotnet/43f462adc665788e342d01bb8f5261a59636ea0d/Dlls/StackifyLib.log4net.v1_2_10/StackifyLib.log4net.v1_2_10.1.11.0.1.nupkg -------------------------------------------------------------------------------- /Dlls/StackifyLib.log4net.v1_2_10/StackifyLib.log4net.v1_2_10.1.15.0.0.nupkg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stackify/stackify-api-dotnet/43f462adc665788e342d01bb8f5261a59636ea0d/Dlls/StackifyLib.log4net.v1_2_10/StackifyLib.log4net.v1_2_10.1.15.0.0.nupkg -------------------------------------------------------------------------------- /Dlls/StackifyLib.log4net.v1_2_10/StackifyLib.log4net.v1_2_10.1.16.0.0.nupkg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stackify/stackify-api-dotnet/43f462adc665788e342d01bb8f5261a59636ea0d/Dlls/StackifyLib.log4net.v1_2_10/StackifyLib.log4net.v1_2_10.1.16.0.0.nupkg -------------------------------------------------------------------------------- /Dlls/StackifyLib.log4net.v1_2_10/StackifyLib.log4net.v1_2_10.1.17.0.0.nupkg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stackify/stackify-api-dotnet/43f462adc665788e342d01bb8f5261a59636ea0d/Dlls/StackifyLib.log4net.v1_2_10/StackifyLib.log4net.v1_2_10.1.17.0.0.nupkg -------------------------------------------------------------------------------- /Dlls/StackifyLib.log4net.v1_2_10/StackifyLib.log4net.v1_2_10.1.17.1.0.nupkg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stackify/stackify-api-dotnet/43f462adc665788e342d01bb8f5261a59636ea0d/Dlls/StackifyLib.log4net.v1_2_10/StackifyLib.log4net.v1_2_10.1.17.1.0.nupkg -------------------------------------------------------------------------------- /Dlls/StackifyLib.log4net.v1_2_10/StackifyLib.log4net.v1_2_10.1.17.2.0.nupkg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stackify/stackify-api-dotnet/43f462adc665788e342d01bb8f5261a59636ea0d/Dlls/StackifyLib.log4net.v1_2_10/StackifyLib.log4net.v1_2_10.1.17.2.0.nupkg -------------------------------------------------------------------------------- /Dlls/StackifyLib.log4net.v1_2_10/StackifyLib.log4net.v1_2_10.1.18.1.0.nupkg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stackify/stackify-api-dotnet/43f462adc665788e342d01bb8f5261a59636ea0d/Dlls/StackifyLib.log4net.v1_2_10/StackifyLib.log4net.v1_2_10.1.18.1.0.nupkg -------------------------------------------------------------------------------- /Dlls/StackifyLib.log4net.v1_2_10/stackifylib.log4net.v1_2_10.1.13.0.nupkg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stackify/stackify-api-dotnet/43f462adc665788e342d01bb8f5261a59636ea0d/Dlls/StackifyLib.log4net.v1_2_10/stackifylib.log4net.v1_2_10.1.13.0.nupkg -------------------------------------------------------------------------------- /Dlls/StackifyLib.log4net/StackifyLib.log4net.1.10.0.0.nupkg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stackify/stackify-api-dotnet/43f462adc665788e342d01bb8f5261a59636ea0d/Dlls/StackifyLib.log4net/StackifyLib.log4net.1.10.0.0.nupkg -------------------------------------------------------------------------------- /Dlls/StackifyLib.log4net/StackifyLib.log4net.1.11.0.0.nupkg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stackify/stackify-api-dotnet/43f462adc665788e342d01bb8f5261a59636ea0d/Dlls/StackifyLib.log4net/StackifyLib.log4net.1.11.0.0.nupkg -------------------------------------------------------------------------------- /Dlls/StackifyLib.log4net/StackifyLib.log4net.1.11.0.1.nupkg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stackify/stackify-api-dotnet/43f462adc665788e342d01bb8f5261a59636ea0d/Dlls/StackifyLib.log4net/StackifyLib.log4net.1.11.0.1.nupkg -------------------------------------------------------------------------------- /Dlls/StackifyLib.log4net/StackifyLib.log4net.1.15.0.0.nupkg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stackify/stackify-api-dotnet/43f462adc665788e342d01bb8f5261a59636ea0d/Dlls/StackifyLib.log4net/StackifyLib.log4net.1.15.0.0.nupkg -------------------------------------------------------------------------------- /Dlls/StackifyLib.log4net/StackifyLib.log4net.1.16.0.0.nupkg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stackify/stackify-api-dotnet/43f462adc665788e342d01bb8f5261a59636ea0d/Dlls/StackifyLib.log4net/StackifyLib.log4net.1.16.0.0.nupkg -------------------------------------------------------------------------------- /Dlls/StackifyLib.log4net/StackifyLib.log4net.1.17.0.0.nupkg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stackify/stackify-api-dotnet/43f462adc665788e342d01bb8f5261a59636ea0d/Dlls/StackifyLib.log4net/StackifyLib.log4net.1.17.0.0.nupkg -------------------------------------------------------------------------------- /Dlls/StackifyLib.log4net/StackifyLib.log4net.1.17.1.0.nupkg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stackify/stackify-api-dotnet/43f462adc665788e342d01bb8f5261a59636ea0d/Dlls/StackifyLib.log4net/StackifyLib.log4net.1.17.1.0.nupkg -------------------------------------------------------------------------------- /Dlls/StackifyLib.log4net/StackifyLib.log4net.1.17.2.0.nupkg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stackify/stackify-api-dotnet/43f462adc665788e342d01bb8f5261a59636ea0d/Dlls/StackifyLib.log4net/StackifyLib.log4net.1.17.2.0.nupkg -------------------------------------------------------------------------------- /Dlls/StackifyLib.log4net/StackifyLib.log4net.1.18.1.0.nupkg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stackify/stackify-api-dotnet/43f462adc665788e342d01bb8f5261a59636ea0d/Dlls/StackifyLib.log4net/StackifyLib.log4net.1.18.1.0.nupkg -------------------------------------------------------------------------------- /Dlls/StackifyLib.log4net/StackifyLib.log4net.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stackify/stackify-api-dotnet/43f462adc665788e342d01bb8f5261a59636ea0d/Dlls/StackifyLib.log4net/StackifyLib.log4net.dll -------------------------------------------------------------------------------- /Dlls/StackifyLib.log4net/stackifylib.log4net.1.13.0.nupkg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stackify/stackify-api-dotnet/43f462adc665788e342d01bb8f5261a59636ea0d/Dlls/StackifyLib.log4net/stackifylib.log4net.1.13.0.nupkg -------------------------------------------------------------------------------- /Dlls/StackifyLib.nLog/StackifyLib.nLog.1.10.0.0.nupkg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stackify/stackify-api-dotnet/43f462adc665788e342d01bb8f5261a59636ea0d/Dlls/StackifyLib.nLog/StackifyLib.nLog.1.10.0.0.nupkg -------------------------------------------------------------------------------- /Dlls/StackifyLib.nLog/StackifyLib.nLog.1.11.0.0.nupkg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stackify/stackify-api-dotnet/43f462adc665788e342d01bb8f5261a59636ea0d/Dlls/StackifyLib.nLog/StackifyLib.nLog.1.11.0.0.nupkg -------------------------------------------------------------------------------- /Dlls/StackifyLib.nLog/StackifyLib.nLog.1.11.0.1.nupkg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stackify/stackify-api-dotnet/43f462adc665788e342d01bb8f5261a59636ea0d/Dlls/StackifyLib.nLog/StackifyLib.nLog.1.11.0.1.nupkg -------------------------------------------------------------------------------- /Dlls/StackifyLib.nLog/StackifyLib.nLog.1.15.1.nupkg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stackify/stackify-api-dotnet/43f462adc665788e342d01bb8f5261a59636ea0d/Dlls/StackifyLib.nLog/StackifyLib.nLog.1.15.1.nupkg -------------------------------------------------------------------------------- /Dlls/StackifyLib.nLog/StackifyLib.nLog.1.16.0.nupkg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stackify/stackify-api-dotnet/43f462adc665788e342d01bb8f5261a59636ea0d/Dlls/StackifyLib.nLog/StackifyLib.nLog.1.16.0.nupkg -------------------------------------------------------------------------------- /Dlls/StackifyLib.nLog/StackifyLib.nLog.1.17.0.nupkg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stackify/stackify-api-dotnet/43f462adc665788e342d01bb8f5261a59636ea0d/Dlls/StackifyLib.nLog/StackifyLib.nLog.1.17.0.nupkg -------------------------------------------------------------------------------- /Dlls/StackifyLib.nLog/StackifyLib.nLog.1.17.1.nupkg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stackify/stackify-api-dotnet/43f462adc665788e342d01bb8f5261a59636ea0d/Dlls/StackifyLib.nLog/StackifyLib.nLog.1.17.1.nupkg -------------------------------------------------------------------------------- /Dlls/StackifyLib.nLog/StackifyLib.nLog.1.17.2.nupkg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stackify/stackify-api-dotnet/43f462adc665788e342d01bb8f5261a59636ea0d/Dlls/StackifyLib.nLog/StackifyLib.nLog.1.17.2.nupkg -------------------------------------------------------------------------------- /Dlls/StackifyLib.nLog/StackifyLib.nLog.1.18.1.nupkg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stackify/stackify-api-dotnet/43f462adc665788e342d01bb8f5261a59636ea0d/Dlls/StackifyLib.nLog/StackifyLib.nLog.1.18.1.nupkg -------------------------------------------------------------------------------- /Dlls/StackifyLib.nLog/StackifyLib.nLog.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stackify/stackify-api-dotnet/43f462adc665788e342d01bb8f5261a59636ea0d/Dlls/StackifyLib.nLog/StackifyLib.nLog.dll -------------------------------------------------------------------------------- /Dlls/StackifyLib.nLog/stackifylib.nlog.1.15.0.nupkg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stackify/stackify-api-dotnet/43f462adc665788e342d01bb8f5261a59636ea0d/Dlls/StackifyLib.nLog/stackifylib.nlog.1.15.0.nupkg -------------------------------------------------------------------------------- /Dlls/StackifyLib/StackifyLib.1.10.0.0.nupkg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stackify/stackify-api-dotnet/43f462adc665788e342d01bb8f5261a59636ea0d/Dlls/StackifyLib/StackifyLib.1.10.0.0.nupkg -------------------------------------------------------------------------------- /Dlls/StackifyLib/StackifyLib.1.11.0.0.nupkg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stackify/stackify-api-dotnet/43f462adc665788e342d01bb8f5261a59636ea0d/Dlls/StackifyLib/StackifyLib.1.11.0.0.nupkg -------------------------------------------------------------------------------- /Dlls/StackifyLib/StackifyLib.1.15.0.0.nupkg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stackify/stackify-api-dotnet/43f462adc665788e342d01bb8f5261a59636ea0d/Dlls/StackifyLib/StackifyLib.1.15.0.0.nupkg -------------------------------------------------------------------------------- /Dlls/StackifyLib/StackifyLib.1.16.0.0.nupkg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stackify/stackify-api-dotnet/43f462adc665788e342d01bb8f5261a59636ea0d/Dlls/StackifyLib/StackifyLib.1.16.0.0.nupkg -------------------------------------------------------------------------------- /Dlls/StackifyLib/StackifyLib.1.17.0.0.nupkg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stackify/stackify-api-dotnet/43f462adc665788e342d01bb8f5261a59636ea0d/Dlls/StackifyLib/StackifyLib.1.17.0.0.nupkg -------------------------------------------------------------------------------- /Dlls/StackifyLib/StackifyLib.1.18.0.0.nupkg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stackify/stackify-api-dotnet/43f462adc665788e342d01bb8f5261a59636ea0d/Dlls/StackifyLib/StackifyLib.1.18.0.0.nupkg -------------------------------------------------------------------------------- /Dlls/StackifyLib/StackifyLib.1.20.0.0.nupkg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stackify/stackify-api-dotnet/43f462adc665788e342d01bb8f5261a59636ea0d/Dlls/StackifyLib/StackifyLib.1.20.0.0.nupkg -------------------------------------------------------------------------------- /Dlls/StackifyLib/StackifyLib.1.21.0.0.nupkg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stackify/stackify-api-dotnet/43f462adc665788e342d01bb8f5261a59636ea0d/Dlls/StackifyLib/StackifyLib.1.21.0.0.nupkg -------------------------------------------------------------------------------- /Dlls/StackifyLib/StackifyLib.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stackify/stackify-api-dotnet/43f462adc665788e342d01bb8f5261a59636ea0d/Dlls/StackifyLib/StackifyLib.dll -------------------------------------------------------------------------------- /Dlls/StackifyLib/stackifylib.1.14.0.nupkg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stackify/stackify-api-dotnet/43f462adc665788e342d01bb8f5261a59636ea0d/Dlls/StackifyLib/stackifylib.1.14.0.nupkg -------------------------------------------------------------------------------- /Scripts/RemoveSignCode.ps1: -------------------------------------------------------------------------------- 1 | function Remove-SignCode { 2 | param ( 3 | $ASMFile 4 | ) 5 | Set-Content -Path $ASMFile -Value (Get-Content -Path $ASMFile | Select-String -Pattern AssemblyKeyFileAttribute -NotMatch ) 6 | } 7 | 8 | $files = @(Get-ChildItem -Path . -Directory -Filter Stackify*) 9 | 10 | foreach ($file in $files) { 11 | $asmInfo = Get-ChildItem -Path $file/Properties/AssemblyInfo.cs 12 | Remove-SignCode -ASMFile $asmInfo 13 | } -------------------------------------------------------------------------------- /Src/CoreWebApp2.2/Controllers/ValuesController.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Threading.Tasks; 5 | using Microsoft.AspNetCore.Mvc; 6 | 7 | namespace CoreWebApp2._2.Controllers 8 | { 9 | [Route("api/[controller]")] 10 | [ApiController] 11 | public class ValuesController : ControllerBase 12 | { 13 | // GET api/values 14 | [HttpGet] 15 | public ActionResult> Get() 16 | { 17 | return new string[] { "value1", "value2" }; 18 | } 19 | 20 | // GET api/values/5 21 | [HttpGet("{id}")] 22 | public ActionResult Get(int id) 23 | { 24 | return "value"; 25 | } 26 | 27 | // POST api/values 28 | [HttpPost] 29 | public void Post([FromBody] string value) 30 | { 31 | } 32 | 33 | // PUT api/values/5 34 | [HttpPut("{id}")] 35 | public void Put(int id, [FromBody] string value) 36 | { 37 | } 38 | 39 | // DELETE api/values/5 40 | [HttpDelete("{id}")] 41 | public void Delete(int id) 42 | { 43 | } 44 | } 45 | } 46 | -------------------------------------------------------------------------------- /Src/CoreWebApp2.2/CoreWebApp2.2.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | netcoreapp2.2 5 | InProcess 6 | CoreWebApp2._2 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | -------------------------------------------------------------------------------- /Src/CoreWebApp2.2/Program.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.IO; 4 | using System.Linq; 5 | using System.Threading.Tasks; 6 | using Microsoft.AspNetCore; 7 | using Microsoft.AspNetCore.Hosting; 8 | using Microsoft.Extensions.Configuration; 9 | using Microsoft.Extensions.Logging; 10 | 11 | namespace CoreWebApp2._2 12 | { 13 | public class Program 14 | { 15 | public static void Main(string[] args) 16 | { 17 | CreateWebHostBuilder(args).Build().Run(); 18 | } 19 | 20 | public static IWebHostBuilder CreateWebHostBuilder(string[] args) => 21 | WebHost.CreateDefaultBuilder(args) 22 | .UseStartup(); 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /Src/CoreWebApp2.2/Properties/launchSettings.json: -------------------------------------------------------------------------------- 1 | { 2 | "$schema": "http://json.schemastore.org/launchsettings.json", 3 | "iisSettings": { 4 | "windowsAuthentication": false, 5 | "anonymousAuthentication": true, 6 | "iisExpress": { 7 | "applicationUrl": "http://localhost:51874", 8 | "sslPort": 44382 9 | } 10 | }, 11 | "profiles": { 12 | "IIS Express": { 13 | "commandName": "IISExpress", 14 | "launchBrowser": true, 15 | "launchUrl": "api/values", 16 | "environmentVariables": { 17 | "ASPNETCORE_ENVIRONMENT": "Development" 18 | } 19 | }, 20 | "CoreWebApp2._2": { 21 | "commandName": "Project", 22 | "launchBrowser": true, 23 | "launchUrl": "api/values", 24 | "applicationUrl": "https://localhost:5001;http://localhost:5000", 25 | "environmentVariables": { 26 | "ASPNETCORE_ENVIRONMENT": "Development" 27 | } 28 | } 29 | } 30 | } -------------------------------------------------------------------------------- /Src/CoreWebApp2.2/Startup.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Threading.Tasks; 5 | using Microsoft.AspNetCore.Builder; 6 | using Microsoft.AspNetCore.Hosting; 7 | using Microsoft.AspNetCore.HttpsPolicy; 8 | using Microsoft.AspNetCore.Mvc; 9 | using Microsoft.Extensions.Configuration; 10 | using Microsoft.Extensions.DependencyInjection; 11 | using Microsoft.Extensions.Logging; 12 | using Microsoft.Extensions.Options; 13 | 14 | namespace CoreWebApp2._2 15 | { 16 | public class Startup 17 | { 18 | public Startup(IConfiguration configuration) 19 | { 20 | Configuration = configuration; 21 | } 22 | 23 | public IConfiguration Configuration { get; } 24 | 25 | // This method gets called by the runtime. Use this method to add services to the container. 26 | public void ConfigureServices(IServiceCollection services) 27 | { 28 | services.AddMvc().SetCompatibilityVersion(CompatibilityVersion.Version_2_2); 29 | } 30 | 31 | // This method gets called by the runtime. Use this method to configure the HTTP request pipeline. 32 | public void Configure(IApplicationBuilder app, IHostingEnvironment env) 33 | { 34 | if (env.IsDevelopment()) 35 | { 36 | app.UseDeveloperExceptionPage(); 37 | } 38 | else 39 | { 40 | // The default HSTS value is 30 days. You may want to change this for production scenarios, see https://aka.ms/aspnetcore-hsts. 41 | app.UseHsts(); 42 | } 43 | 44 | app.UseHttpsRedirection(); 45 | app.UseMvc(); 46 | } 47 | } 48 | } 49 | -------------------------------------------------------------------------------- /Src/CoreWebApp2.2/appsettings.Development.json: -------------------------------------------------------------------------------- 1 | { 2 | "Logging": { 3 | "LogLevel": { 4 | "Default": "Debug", 5 | "System": "Information", 6 | "Microsoft": "Information" 7 | } 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /Src/CoreWebApp2.2/appsettings.json: -------------------------------------------------------------------------------- 1 | { 2 | "Logging": { 3 | "LogLevel": { 4 | "Default": "Warning" 5 | } 6 | }, 7 | "AllowedHosts": "*" 8 | } 9 | -------------------------------------------------------------------------------- /Src/CoreWebApp22/CoreWebApp22.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | netcoreapp2.2 5 | InProcess 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | -------------------------------------------------------------------------------- /Src/CoreWebApp22/Pages/Error.cshtml: -------------------------------------------------------------------------------- 1 | @page 2 | @model ErrorModel 3 | @{ 4 | ViewData["Title"] = "Error"; 5 | } 6 | 7 |

Error.

8 |

An error occurred while processing your request.

9 | 10 | @if (Model.ShowRequestId) 11 | { 12 |

13 | Request ID: @Model.RequestId 14 |

15 | } 16 | 17 |

Development Mode

18 |

19 | Swapping to the Development environment displays detailed information about the error that occurred. 20 |

21 |

22 | The Development environment shouldn't be enabled for deployed applications. 23 | It can result in displaying sensitive information from exceptions to end users. 24 | For local debugging, enable the Development environment by setting the ASPNETCORE_ENVIRONMENT environment variable to Development 25 | and restarting the app. 26 |

27 | -------------------------------------------------------------------------------- /Src/CoreWebApp22/Pages/Error.cshtml.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Diagnostics; 4 | using System.Linq; 5 | using System.Threading.Tasks; 6 | using Microsoft.AspNetCore.Mvc; 7 | using Microsoft.AspNetCore.Mvc.RazorPages; 8 | 9 | namespace CoreWebApp22.Pages 10 | { 11 | [ResponseCache(Duration = 0, Location = ResponseCacheLocation.None, NoStore = true)] 12 | public class ErrorModel : PageModel 13 | { 14 | public string RequestId { get; set; } 15 | 16 | public bool ShowRequestId => !string.IsNullOrEmpty(RequestId); 17 | 18 | public void OnGet() 19 | { 20 | RequestId = Activity.Current?.Id ?? HttpContext.TraceIdentifier; 21 | } 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /Src/CoreWebApp22/Pages/Index.cshtml: -------------------------------------------------------------------------------- 1 | @page 2 | @model IndexModel 3 | @{ 4 | ViewData["Title"] = "Home page"; 5 | } 6 | 7 |
8 |

Welcome

9 |

Learn about building Web apps with ASP.NET Core.

10 |
11 | -------------------------------------------------------------------------------- /Src/CoreWebApp22/Pages/Index.cshtml.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Threading.Tasks; 5 | using Microsoft.AspNetCore.Mvc; 6 | using Microsoft.AspNetCore.Mvc.RazorPages; 7 | 8 | namespace CoreWebApp22.Pages 9 | { 10 | public class IndexModel : PageModel 11 | { 12 | public void OnGet() 13 | { 14 | 15 | } 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /Src/CoreWebApp22/Pages/Privacy.cshtml: -------------------------------------------------------------------------------- 1 | @page 2 | @model PrivacyModel 3 | @{ 4 | ViewData["Title"] = "Privacy Policy"; 5 | } 6 |

@ViewData["Title"]

7 | 8 |

Use this page to detail your site's privacy policy.

9 | -------------------------------------------------------------------------------- /Src/CoreWebApp22/Pages/Privacy.cshtml.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Threading.Tasks; 5 | using Microsoft.AspNetCore.Mvc; 6 | using Microsoft.AspNetCore.Mvc.RazorPages; 7 | 8 | namespace CoreWebApp22.Pages 9 | { 10 | public class PrivacyModel : PageModel 11 | { 12 | public void OnGet() 13 | { 14 | } 15 | } 16 | } -------------------------------------------------------------------------------- /Src/CoreWebApp22/Pages/Shared/_CookieConsentPartial.cshtml: -------------------------------------------------------------------------------- 1 | @using Microsoft.AspNetCore.Http.Features 2 | 3 | @{ 4 | var consentFeature = Context.Features.Get(); 5 | var showBanner = !consentFeature?.CanTrack ?? false; 6 | var cookieString = consentFeature?.CreateConsentCookie(); 7 | } 8 | 9 | @if (showBanner) 10 | { 11 | 17 | 25 | } 26 | -------------------------------------------------------------------------------- /Src/CoreWebApp22/Pages/Shared/_ValidationScriptsPartial.cshtml: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 12 | 18 | 19 | -------------------------------------------------------------------------------- /Src/CoreWebApp22/Pages/_ViewImports.cshtml: -------------------------------------------------------------------------------- 1 | @using CoreWebApp22 2 | @namespace CoreWebApp22.Pages 3 | @addTagHelper *, Microsoft.AspNetCore.Mvc.TagHelpers 4 | -------------------------------------------------------------------------------- /Src/CoreWebApp22/Pages/_ViewStart.cshtml: -------------------------------------------------------------------------------- 1 | @{ 2 | Layout = "_Layout"; 3 | } 4 | -------------------------------------------------------------------------------- /Src/CoreWebApp22/Program.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.IO; 4 | using System.Linq; 5 | using System.Threading.Tasks; 6 | using Microsoft.AspNetCore; 7 | using Microsoft.AspNetCore.Hosting; 8 | using Microsoft.Extensions.Configuration; 9 | using Microsoft.Extensions.Logging; 10 | 11 | namespace CoreWebApp22 12 | { 13 | public class Program 14 | { 15 | public static void Main(string[] args) 16 | { 17 | CreateWebHostBuilder(args).Build().Run(); 18 | } 19 | 20 | public static IWebHostBuilder CreateWebHostBuilder(string[] args) => 21 | WebHost.CreateDefaultBuilder(args) 22 | .UseStartup(); 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /Src/CoreWebApp22/Properties/launchSettings.json: -------------------------------------------------------------------------------- 1 | { 2 | "iisSettings": { 3 | "windowsAuthentication": false, 4 | "anonymousAuthentication": true, 5 | "iisExpress": { 6 | "applicationUrl": "http://localhost:51834", 7 | "sslPort": 44318 8 | } 9 | }, 10 | "profiles": { 11 | "IIS Express": { 12 | "commandName": "IISExpress", 13 | "launchBrowser": true, 14 | "environmentVariables": { 15 | "ASPNETCORE_ENVIRONMENT": "Development" 16 | } 17 | }, 18 | "CoreWebApp22": { 19 | "commandName": "Project", 20 | "launchBrowser": true, 21 | "applicationUrl": "https://localhost:5001;http://localhost:5000", 22 | "environmentVariables": { 23 | "ASPNETCORE_ENVIRONMENT": "Development" 24 | } 25 | } 26 | } 27 | } -------------------------------------------------------------------------------- /Src/CoreWebApp22/appsettings.Development.json: -------------------------------------------------------------------------------- 1 | { 2 | "Logging": { 3 | "LogLevel": { 4 | "Default": "Debug", 5 | "System": "Information", 6 | "Microsoft": "Information" 7 | } 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /Src/CoreWebApp22/appsettings.json: -------------------------------------------------------------------------------- 1 | { 2 | "Logging": { 3 | "LogLevel": { 4 | "Default": "Warning" 5 | } 6 | }, 7 | "AllowedHosts": "*" 8 | } 9 | -------------------------------------------------------------------------------- /Src/CoreWebApp22/wwwroot/css/site.css: -------------------------------------------------------------------------------- 1 | /* Please see documentation at https://docs.microsoft.com/aspnet/core/client-side/bundling-and-minification 2 | for details on configuring this project to bundle and minify static web assets. */ 3 | 4 | a.navbar-brand { 5 | white-space: normal; 6 | text-align: center; 7 | word-break: break-all; 8 | } 9 | 10 | /* Sticky footer styles 11 | -------------------------------------------------- */ 12 | html { 13 | font-size: 14px; 14 | } 15 | @media (min-width: 768px) { 16 | html { 17 | font-size: 16px; 18 | } 19 | } 20 | 21 | .border-top { 22 | border-top: 1px solid #e5e5e5; 23 | } 24 | .border-bottom { 25 | border-bottom: 1px solid #e5e5e5; 26 | } 27 | 28 | .box-shadow { 29 | box-shadow: 0 .25rem .75rem rgba(0, 0, 0, .05); 30 | } 31 | 32 | button.accept-policy { 33 | font-size: 1rem; 34 | line-height: inherit; 35 | } 36 | 37 | /* Sticky footer styles 38 | -------------------------------------------------- */ 39 | html { 40 | position: relative; 41 | min-height: 100%; 42 | } 43 | 44 | body { 45 | /* Margin bottom by footer height */ 46 | margin-bottom: 60px; 47 | } 48 | .footer { 49 | position: absolute; 50 | bottom: 0; 51 | width: 100%; 52 | white-space: nowrap; 53 | /* Set the fixed height of the footer here */ 54 | height: 60px; 55 | line-height: 60px; /* Vertically center the text there */ 56 | } 57 | -------------------------------------------------------------------------------- /Src/CoreWebApp22/wwwroot/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stackify/stackify-api-dotnet/43f462adc665788e342d01bb8f5261a59636ea0d/Src/CoreWebApp22/wwwroot/favicon.ico -------------------------------------------------------------------------------- /Src/CoreWebApp22/wwwroot/js/site.js: -------------------------------------------------------------------------------- 1 | // Please see documentation at https://docs.microsoft.com/aspnet/core/client-side/bundling-and-minification 2 | // for details on configuring this project to bundle and minify static web assets. 3 | 4 | // Write your Javascript code. 5 | -------------------------------------------------------------------------------- /Src/CoreWebApp22/wwwroot/lib/bootstrap/LICENSE: -------------------------------------------------------------------------------- 1 | The MIT License (MIT) 2 | 3 | Copyright (c) 2011-2018 Twitter, Inc. 4 | Copyright (c) 2011-2018 The Bootstrap Authors 5 | 6 | Permission is hereby granted, free of charge, to any person obtaining a copy 7 | of this software and associated documentation files (the "Software"), to deal 8 | in the Software without restriction, including without limitation the rights 9 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 10 | copies of the Software, and to permit persons to whom the Software is 11 | furnished to do so, subject to the following conditions: 12 | 13 | The above copyright notice and this permission notice shall be included in 14 | all copies or substantial portions of the Software. 15 | 16 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 17 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 18 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 19 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 20 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 21 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 22 | THE SOFTWARE. 23 | -------------------------------------------------------------------------------- /Src/CoreWebApp22/wwwroot/lib/jquery-validation-unobtrusive/LICENSE.txt: -------------------------------------------------------------------------------- 1 | Copyright (c) .NET Foundation. All rights reserved. 2 | 3 | Licensed under the Apache License, Version 2.0 (the "License"); you may not use 4 | these files except in compliance with the License. You may obtain a copy of the 5 | License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, software distributed 10 | under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR 11 | CONDITIONS OF ANY KIND, either express or implied. See the License for the 12 | specific language governing permissions and limitations under the License. 13 | -------------------------------------------------------------------------------- /Src/CoreWebApp22/wwwroot/lib/jquery-validation/LICENSE.md: -------------------------------------------------------------------------------- 1 | The MIT License (MIT) 2 | ===================== 3 | 4 | Copyright Jörn Zaefferer 5 | 6 | Permission is hereby granted, free of charge, to any person obtaining a copy 7 | of this software and associated documentation files (the "Software"), to deal 8 | in the Software without restriction, including without limitation the rights 9 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 10 | copies of the Software, and to permit persons to whom the Software is 11 | furnished to do so, subject to the following conditions: 12 | 13 | The above copyright notice and this permission notice shall be included in 14 | all copies or substantial portions of the Software. 15 | 16 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 17 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 18 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 19 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 20 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 21 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 22 | THE SOFTWARE. 23 | -------------------------------------------------------------------------------- /Src/CoreWebApp22/wwwroot/lib/jquery/LICENSE.txt: -------------------------------------------------------------------------------- 1 | Copyright JS Foundation and other contributors, https://js.foundation/ 2 | 3 | This software consists of voluntary contributions made by many 4 | individuals. For exact contribution history, see the revision history 5 | available at https://github.com/jquery/jquery 6 | 7 | The following license applies to all parts of this software except as 8 | documented below: 9 | 10 | ==== 11 | 12 | Permission is hereby granted, free of charge, to any person obtaining 13 | a copy of this software and associated documentation files (the 14 | "Software"), to deal in the Software without restriction, including 15 | without limitation the rights to use, copy, modify, merge, publish, 16 | distribute, sublicense, and/or sell copies of the Software, and to 17 | permit persons to whom the Software is furnished to do so, subject to 18 | the following conditions: 19 | 20 | The above copyright notice and this permission notice shall be 21 | included in all copies or substantial portions of the Software. 22 | 23 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, 24 | EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF 25 | MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND 26 | NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE 27 | LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION 28 | OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION 29 | WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 30 | 31 | ==== 32 | 33 | All files located in the node_modules and external directories are 34 | externally maintained libraries used by this software which have their 35 | own licenses; we recommend you read them, as their terms may differ from 36 | the terms above. 37 | -------------------------------------------------------------------------------- /Src/FFWebApp462/App_Start/BundleConfig.cs: -------------------------------------------------------------------------------- 1 | using System.Web; 2 | using System.Web.Optimization; 3 | 4 | namespace FFWebApp462 5 | { 6 | public class BundleConfig 7 | { 8 | // For more information on bundling, visit https://go.microsoft.com/fwlink/?LinkId=301862 9 | public static void RegisterBundles(BundleCollection bundles) 10 | { 11 | } 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /Src/FFWebApp462/App_Start/FilterConfig.cs: -------------------------------------------------------------------------------- 1 | using System.Web; 2 | using System.Web.Mvc; 3 | 4 | namespace FFWebApp462 5 | { 6 | public class FilterConfig 7 | { 8 | public static void RegisterGlobalFilters(GlobalFilterCollection filters) 9 | { 10 | filters.Add(new HandleErrorAttribute()); 11 | } 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /Src/FFWebApp462/App_Start/RouteConfig.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Web; 5 | using System.Web.Mvc; 6 | using System.Web.Routing; 7 | 8 | namespace FFWebApp462 9 | { 10 | public class RouteConfig 11 | { 12 | public static void RegisterRoutes(RouteCollection routes) 13 | { 14 | routes.IgnoreRoute("{resource}.axd/{*pathInfo}"); 15 | 16 | routes.MapRoute( 17 | name: "Default", 18 | url: "api/{controller}/{action}/{id}", 19 | defaults: new { controller = "Values", action = "Get", id = UrlParameter.Optional } 20 | ); 21 | } 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /Src/FFWebApp462/App_Start/WebApiConfig.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Web.Http; 5 | 6 | namespace FFWebApp462 7 | { 8 | public static class WebApiConfig 9 | { 10 | public static void Register(HttpConfiguration config) 11 | { 12 | // Web API configuration and services 13 | 14 | // Web API routes 15 | config.MapHttpAttributeRoutes(); 16 | 17 | config.Routes.MapHttpRoute( 18 | name: "DefaultApi", 19 | routeTemplate: "api/{controller}/{action}/{id}", 20 | defaults: new { id = RouteParameter.Optional } 21 | ); 22 | } 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /Src/FFWebApp462/Areas/HelpPage/ApiDescriptionExtensions.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Text; 3 | using System.Web; 4 | using System.Web.Http.Description; 5 | 6 | namespace FFWebApp462.Areas.HelpPage 7 | { 8 | public static class ApiDescriptionExtensions 9 | { 10 | /// 11 | /// Generates an URI-friendly ID for the . E.g. "Get-Values-id_name" instead of "GetValues/{id}?name={name}" 12 | /// 13 | /// The . 14 | /// The ID as a string. 15 | public static string GetFriendlyId(this ApiDescription description) 16 | { 17 | string path = description.RelativePath; 18 | string[] urlParts = path.Split('?'); 19 | string localPath = urlParts[0]; 20 | string queryKeyString = null; 21 | if (urlParts.Length > 1) 22 | { 23 | string query = urlParts[1]; 24 | string[] queryKeys = HttpUtility.ParseQueryString(query).AllKeys; 25 | queryKeyString = String.Join("_", queryKeys); 26 | } 27 | 28 | StringBuilder friendlyPath = new StringBuilder(); 29 | friendlyPath.AppendFormat("{0}-{1}", 30 | description.HttpMethod.Method, 31 | localPath.Replace("/", "-").Replace("{", String.Empty).Replace("}", String.Empty)); 32 | if (queryKeyString != null) 33 | { 34 | friendlyPath.AppendFormat("_{0}", queryKeyString.Replace('.', '-')); 35 | } 36 | return friendlyPath.ToString(); 37 | } 38 | } 39 | } -------------------------------------------------------------------------------- /Src/FFWebApp462/Areas/HelpPage/HelpPageAreaRegistration.cs: -------------------------------------------------------------------------------- 1 | using System.Web.Http; 2 | using System.Web.Mvc; 3 | 4 | namespace FFWebApp462.Areas.HelpPage 5 | { 6 | public class HelpPageAreaRegistration : AreaRegistration 7 | { 8 | public override string AreaName 9 | { 10 | get 11 | { 12 | return "HelpPage"; 13 | } 14 | } 15 | 16 | public override void RegisterArea(AreaRegistrationContext context) 17 | { 18 | context.MapRoute( 19 | "HelpPage_Default", 20 | "Help/{action}/{apiId}", 21 | new { controller = "Help", action = "Index", apiId = UrlParameter.Optional }); 22 | 23 | HelpPageConfig.Register(GlobalConfiguration.Configuration); 24 | } 25 | } 26 | } -------------------------------------------------------------------------------- /Src/FFWebApp462/Areas/HelpPage/ModelDescriptions/CollectionModelDescription.cs: -------------------------------------------------------------------------------- 1 | namespace FFWebApp462.Areas.HelpPage.ModelDescriptions 2 | { 3 | public class CollectionModelDescription : ModelDescription 4 | { 5 | public ModelDescription ElementDescription { get; set; } 6 | } 7 | } -------------------------------------------------------------------------------- /Src/FFWebApp462/Areas/HelpPage/ModelDescriptions/ComplexTypeModelDescription.cs: -------------------------------------------------------------------------------- 1 | using System.Collections.ObjectModel; 2 | 3 | namespace FFWebApp462.Areas.HelpPage.ModelDescriptions 4 | { 5 | public class ComplexTypeModelDescription : ModelDescription 6 | { 7 | public ComplexTypeModelDescription() 8 | { 9 | Properties = new Collection(); 10 | } 11 | 12 | public Collection Properties { get; private set; } 13 | } 14 | } -------------------------------------------------------------------------------- /Src/FFWebApp462/Areas/HelpPage/ModelDescriptions/DictionaryModelDescription.cs: -------------------------------------------------------------------------------- 1 | namespace FFWebApp462.Areas.HelpPage.ModelDescriptions 2 | { 3 | public class DictionaryModelDescription : KeyValuePairModelDescription 4 | { 5 | } 6 | } -------------------------------------------------------------------------------- /Src/FFWebApp462/Areas/HelpPage/ModelDescriptions/EnumTypeModelDescription.cs: -------------------------------------------------------------------------------- 1 | using System.Collections.Generic; 2 | using System.Collections.ObjectModel; 3 | 4 | namespace FFWebApp462.Areas.HelpPage.ModelDescriptions 5 | { 6 | public class EnumTypeModelDescription : ModelDescription 7 | { 8 | public EnumTypeModelDescription() 9 | { 10 | Values = new Collection(); 11 | } 12 | 13 | public Collection Values { get; private set; } 14 | } 15 | } -------------------------------------------------------------------------------- /Src/FFWebApp462/Areas/HelpPage/ModelDescriptions/EnumValueDescription.cs: -------------------------------------------------------------------------------- 1 | namespace FFWebApp462.Areas.HelpPage.ModelDescriptions 2 | { 3 | public class EnumValueDescription 4 | { 5 | public string Documentation { get; set; } 6 | 7 | public string Name { get; set; } 8 | 9 | public string Value { get; set; } 10 | } 11 | } -------------------------------------------------------------------------------- /Src/FFWebApp462/Areas/HelpPage/ModelDescriptions/IModelDocumentationProvider.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Reflection; 3 | 4 | namespace FFWebApp462.Areas.HelpPage.ModelDescriptions 5 | { 6 | public interface IModelDocumentationProvider 7 | { 8 | string GetDocumentation(MemberInfo member); 9 | 10 | string GetDocumentation(Type type); 11 | } 12 | } -------------------------------------------------------------------------------- /Src/FFWebApp462/Areas/HelpPage/ModelDescriptions/KeyValuePairModelDescription.cs: -------------------------------------------------------------------------------- 1 | namespace FFWebApp462.Areas.HelpPage.ModelDescriptions 2 | { 3 | public class KeyValuePairModelDescription : ModelDescription 4 | { 5 | public ModelDescription KeyModelDescription { get; set; } 6 | 7 | public ModelDescription ValueModelDescription { get; set; } 8 | } 9 | } -------------------------------------------------------------------------------- /Src/FFWebApp462/Areas/HelpPage/ModelDescriptions/ModelDescription.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | 3 | namespace FFWebApp462.Areas.HelpPage.ModelDescriptions 4 | { 5 | /// 6 | /// Describes a type model. 7 | /// 8 | public abstract class ModelDescription 9 | { 10 | public string Documentation { get; set; } 11 | 12 | public Type ModelType { get; set; } 13 | 14 | public string Name { get; set; } 15 | } 16 | } -------------------------------------------------------------------------------- /Src/FFWebApp462/Areas/HelpPage/ModelDescriptions/ModelNameAttribute.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | 3 | namespace FFWebApp462.Areas.HelpPage.ModelDescriptions 4 | { 5 | /// 6 | /// Use this attribute to change the name of the generated for a type. 7 | /// 8 | [AttributeUsage(AttributeTargets.Class | AttributeTargets.Struct | AttributeTargets.Enum, AllowMultiple = false, Inherited = false)] 9 | public sealed class ModelNameAttribute : Attribute 10 | { 11 | public ModelNameAttribute(string name) 12 | { 13 | Name = name; 14 | } 15 | 16 | public string Name { get; private set; } 17 | } 18 | } -------------------------------------------------------------------------------- /Src/FFWebApp462/Areas/HelpPage/ModelDescriptions/ModelNameHelper.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Globalization; 3 | using System.Linq; 4 | using System.Reflection; 5 | 6 | namespace FFWebApp462.Areas.HelpPage.ModelDescriptions 7 | { 8 | internal static class ModelNameHelper 9 | { 10 | // Modify this to provide custom model name mapping. 11 | public static string GetModelName(Type type) 12 | { 13 | ModelNameAttribute modelNameAttribute = type.GetCustomAttribute(); 14 | if (modelNameAttribute != null && !String.IsNullOrEmpty(modelNameAttribute.Name)) 15 | { 16 | return modelNameAttribute.Name; 17 | } 18 | 19 | string modelName = type.Name; 20 | if (type.IsGenericType) 21 | { 22 | // Format the generic type name to something like: GenericOfAgurment1AndArgument2 23 | Type genericType = type.GetGenericTypeDefinition(); 24 | Type[] genericArguments = type.GetGenericArguments(); 25 | string genericTypeName = genericType.Name; 26 | 27 | // Trim the generic parameter counts from the name 28 | genericTypeName = genericTypeName.Substring(0, genericTypeName.IndexOf('`')); 29 | string[] argumentTypeNames = genericArguments.Select(t => GetModelName(t)).ToArray(); 30 | modelName = String.Format(CultureInfo.InvariantCulture, "{0}Of{1}", genericTypeName, String.Join("And", argumentTypeNames)); 31 | } 32 | 33 | return modelName; 34 | } 35 | } 36 | } -------------------------------------------------------------------------------- /Src/FFWebApp462/Areas/HelpPage/ModelDescriptions/ParameterAnnotation.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | 3 | namespace FFWebApp462.Areas.HelpPage.ModelDescriptions 4 | { 5 | public class ParameterAnnotation 6 | { 7 | public Attribute AnnotationAttribute { get; set; } 8 | 9 | public string Documentation { get; set; } 10 | } 11 | } -------------------------------------------------------------------------------- /Src/FFWebApp462/Areas/HelpPage/ModelDescriptions/ParameterDescription.cs: -------------------------------------------------------------------------------- 1 | using System.Collections.Generic; 2 | using System.Collections.ObjectModel; 3 | 4 | namespace FFWebApp462.Areas.HelpPage.ModelDescriptions 5 | { 6 | public class ParameterDescription 7 | { 8 | public ParameterDescription() 9 | { 10 | Annotations = new Collection(); 11 | } 12 | 13 | public Collection Annotations { get; private set; } 14 | 15 | public string Documentation { get; set; } 16 | 17 | public string Name { get; set; } 18 | 19 | public ModelDescription TypeDescription { get; set; } 20 | } 21 | } -------------------------------------------------------------------------------- /Src/FFWebApp462/Areas/HelpPage/ModelDescriptions/SimpleTypeModelDescription.cs: -------------------------------------------------------------------------------- 1 | namespace FFWebApp462.Areas.HelpPage.ModelDescriptions 2 | { 3 | public class SimpleTypeModelDescription : ModelDescription 4 | { 5 | } 6 | } -------------------------------------------------------------------------------- /Src/FFWebApp462/Areas/HelpPage/SampleGeneration/ImageSample.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | 3 | namespace FFWebApp462.Areas.HelpPage 4 | { 5 | /// 6 | /// This represents an image sample on the help page. There's a display template named ImageSample associated with this class. 7 | /// 8 | public class ImageSample 9 | { 10 | /// 11 | /// Initializes a new instance of the class. 12 | /// 13 | /// The URL of an image. 14 | public ImageSample(string src) 15 | { 16 | if (src == null) 17 | { 18 | throw new ArgumentNullException("src"); 19 | } 20 | Src = src; 21 | } 22 | 23 | public string Src { get; private set; } 24 | 25 | public override bool Equals(object obj) 26 | { 27 | ImageSample other = obj as ImageSample; 28 | return other != null && Src == other.Src; 29 | } 30 | 31 | public override int GetHashCode() 32 | { 33 | return Src.GetHashCode(); 34 | } 35 | 36 | public override string ToString() 37 | { 38 | return Src; 39 | } 40 | } 41 | } -------------------------------------------------------------------------------- /Src/FFWebApp462/Areas/HelpPage/SampleGeneration/InvalidSample.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | 3 | namespace FFWebApp462.Areas.HelpPage 4 | { 5 | /// 6 | /// This represents an invalid sample on the help page. There's a display template named InvalidSample associated with this class. 7 | /// 8 | public class InvalidSample 9 | { 10 | public InvalidSample(string errorMessage) 11 | { 12 | if (errorMessage == null) 13 | { 14 | throw new ArgumentNullException("errorMessage"); 15 | } 16 | ErrorMessage = errorMessage; 17 | } 18 | 19 | public string ErrorMessage { get; private set; } 20 | 21 | public override bool Equals(object obj) 22 | { 23 | InvalidSample other = obj as InvalidSample; 24 | return other != null && ErrorMessage == other.ErrorMessage; 25 | } 26 | 27 | public override int GetHashCode() 28 | { 29 | return ErrorMessage.GetHashCode(); 30 | } 31 | 32 | public override string ToString() 33 | { 34 | return ErrorMessage; 35 | } 36 | } 37 | } -------------------------------------------------------------------------------- /Src/FFWebApp462/Areas/HelpPage/SampleGeneration/SampleDirection.cs: -------------------------------------------------------------------------------- 1 | namespace FFWebApp462.Areas.HelpPage 2 | { 3 | /// 4 | /// Indicates whether the sample is used for request or response 5 | /// 6 | public enum SampleDirection 7 | { 8 | Request = 0, 9 | Response 10 | } 11 | } -------------------------------------------------------------------------------- /Src/FFWebApp462/Areas/HelpPage/SampleGeneration/TextSample.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | 3 | namespace FFWebApp462.Areas.HelpPage 4 | { 5 | /// 6 | /// This represents a preformatted text sample on the help page. There's a display template named TextSample associated with this class. 7 | /// 8 | public class TextSample 9 | { 10 | public TextSample(string text) 11 | { 12 | if (text == null) 13 | { 14 | throw new ArgumentNullException("text"); 15 | } 16 | Text = text; 17 | } 18 | 19 | public string Text { get; private set; } 20 | 21 | public override bool Equals(object obj) 22 | { 23 | TextSample other = obj as TextSample; 24 | return other != null && Text == other.Text; 25 | } 26 | 27 | public override int GetHashCode() 28 | { 29 | return Text.GetHashCode(); 30 | } 31 | 32 | public override string ToString() 33 | { 34 | return Text; 35 | } 36 | } 37 | } -------------------------------------------------------------------------------- /Src/FFWebApp462/Areas/HelpPage/Views/Help/Api.cshtml: -------------------------------------------------------------------------------- 1 | @using System.Web.Http 2 | @using FFWebApp462.Areas.HelpPage.Models 3 | @model HelpPageApiModel 4 | 5 | @{ 6 | var description = Model.ApiDescription; 7 | ViewBag.Title = description.HttpMethod.Method + " " + description.RelativePath; 8 | } 9 | 10 | 11 |
12 | 19 |
20 | @Html.DisplayForModel() 21 |
22 |
23 | -------------------------------------------------------------------------------- /Src/FFWebApp462/Areas/HelpPage/Views/Help/DisplayTemplates/ApiGroup.cshtml: -------------------------------------------------------------------------------- 1 | @using System.Web.Http 2 | @using System.Web.Http.Controllers 3 | @using System.Web.Http.Description 4 | @using FFWebApp462.Areas.HelpPage 5 | @using FFWebApp462.Areas.HelpPage.Models 6 | @model IGrouping 7 | 8 | @{ 9 | var controllerDocumentation = ViewBag.DocumentationProvider != null ? 10 | ViewBag.DocumentationProvider.GetDocumentation(Model.Key) : 11 | null; 12 | } 13 | 14 |

@Model.Key.ControllerName

15 | @if (!String.IsNullOrEmpty(controllerDocumentation)) 16 | { 17 |

@controllerDocumentation

18 | } 19 | 20 | 21 | 22 | 23 | 24 | @foreach (var api in Model) 25 | { 26 | 27 | 28 | 38 | 39 | } 40 | 41 |
APIDescription
@api.HttpMethod.Method @api.RelativePath 29 | @if (api.Documentation != null) 30 | { 31 |

@api.Documentation

32 | } 33 | else 34 | { 35 |

No documentation available.

36 | } 37 |
-------------------------------------------------------------------------------- /Src/FFWebApp462/Areas/HelpPage/Views/Help/DisplayTemplates/CollectionModelDescription.cshtml: -------------------------------------------------------------------------------- 1 | @using FFWebApp462.Areas.HelpPage.ModelDescriptions 2 | @model CollectionModelDescription 3 | @if (Model.ElementDescription is ComplexTypeModelDescription) 4 | { 5 | @Html.DisplayFor(m => m.ElementDescription) 6 | } -------------------------------------------------------------------------------- /Src/FFWebApp462/Areas/HelpPage/Views/Help/DisplayTemplates/ComplexTypeModelDescription.cshtml: -------------------------------------------------------------------------------- 1 | @using FFWebApp462.Areas.HelpPage.ModelDescriptions 2 | @model ComplexTypeModelDescription 3 | @Html.DisplayFor(m => m.Properties, "Parameters") -------------------------------------------------------------------------------- /Src/FFWebApp462/Areas/HelpPage/Views/Help/DisplayTemplates/DictionaryModelDescription.cshtml: -------------------------------------------------------------------------------- 1 | @using FFWebApp462.Areas.HelpPage.ModelDescriptions 2 | @model DictionaryModelDescription 3 | Dictionary of @Html.DisplayFor(m => Model.KeyModelDescription.ModelType, "ModelDescriptionLink", new { modelDescription = Model.KeyModelDescription }) [key] 4 | and @Html.DisplayFor(m => Model.ValueModelDescription.ModelType, "ModelDescriptionLink", new { modelDescription = Model.ValueModelDescription }) [value] -------------------------------------------------------------------------------- /Src/FFWebApp462/Areas/HelpPage/Views/Help/DisplayTemplates/EnumTypeModelDescription.cshtml: -------------------------------------------------------------------------------- 1 | @using FFWebApp462.Areas.HelpPage.ModelDescriptions 2 | @model EnumTypeModelDescription 3 | 4 |

Possible enumeration values:

5 | 6 | 7 | 8 | 9 | 10 | 11 | @foreach (EnumValueDescription value in Model.Values) 12 | { 13 | 14 | 15 | 18 | 21 | 22 | } 23 | 24 |
NameValueDescription
@value.Name 16 |

@value.Value

17 |
19 |

@value.Documentation

20 |
-------------------------------------------------------------------------------- /Src/FFWebApp462/Areas/HelpPage/Views/Help/DisplayTemplates/HelpPageApiModel.cshtml: -------------------------------------------------------------------------------- 1 | @using System.Web.Http 2 | @using System.Web.Http.Description 3 | @using FFWebApp462.Areas.HelpPage.Models 4 | @using FFWebApp462.Areas.HelpPage.ModelDescriptions 5 | @model HelpPageApiModel 6 | 7 | @{ 8 | ApiDescription description = Model.ApiDescription; 9 | } 10 |

@description.HttpMethod.Method @description.RelativePath

11 |
12 |

@description.Documentation

13 | 14 |

Request Information

15 | 16 |

URI Parameters

17 | @Html.DisplayFor(m => m.UriParameters, "Parameters") 18 | 19 |

Body Parameters

20 | 21 |

@Model.RequestDocumentation

22 | 23 | @if (Model.RequestModelDescription != null) 24 | { 25 | @Html.DisplayFor(m => m.RequestModelDescription.ModelType, "ModelDescriptionLink", new { modelDescription = Model.RequestModelDescription }) 26 | if (Model.RequestBodyParameters != null) 27 | { 28 | @Html.DisplayFor(m => m.RequestBodyParameters, "Parameters") 29 | } 30 | } 31 | else 32 | { 33 |

None.

34 | } 35 | 36 | @if (Model.SampleRequests.Count > 0) 37 | { 38 |

Request Formats

39 | @Html.DisplayFor(m => m.SampleRequests, "Samples") 40 | } 41 | 42 |

Response Information

43 | 44 |

Resource Description

45 | 46 |

@description.ResponseDescription.Documentation

47 | 48 | @if (Model.ResourceDescription != null) 49 | { 50 | @Html.DisplayFor(m => m.ResourceDescription.ModelType, "ModelDescriptionLink", new { modelDescription = Model.ResourceDescription }) 51 | if (Model.ResourceProperties != null) 52 | { 53 | @Html.DisplayFor(m => m.ResourceProperties, "Parameters") 54 | } 55 | } 56 | else 57 | { 58 |

None.

59 | } 60 | 61 | @if (Model.SampleResponses.Count > 0) 62 | { 63 |

Response Formats

64 | @Html.DisplayFor(m => m.SampleResponses, "Samples") 65 | } 66 | 67 |
-------------------------------------------------------------------------------- /Src/FFWebApp462/Areas/HelpPage/Views/Help/DisplayTemplates/ImageSample.cshtml: -------------------------------------------------------------------------------- 1 | @using FFWebApp462.Areas.HelpPage 2 | @model ImageSample 3 | 4 | -------------------------------------------------------------------------------- /Src/FFWebApp462/Areas/HelpPage/Views/Help/DisplayTemplates/InvalidSample.cshtml: -------------------------------------------------------------------------------- 1 | @using FFWebApp462.Areas.HelpPage 2 | @model InvalidSample 3 | 4 | @if (HttpContext.Current.IsDebuggingEnabled) 5 | { 6 |
7 |

@Model.ErrorMessage

8 |
9 | } 10 | else 11 | { 12 |

Sample not available.

13 | } -------------------------------------------------------------------------------- /Src/FFWebApp462/Areas/HelpPage/Views/Help/DisplayTemplates/KeyValuePairModelDescription.cshtml: -------------------------------------------------------------------------------- 1 | @using FFWebApp462.Areas.HelpPage.ModelDescriptions 2 | @model KeyValuePairModelDescription 3 | Pair of @Html.DisplayFor(m => Model.KeyModelDescription.ModelType, "ModelDescriptionLink", new { modelDescription = Model.KeyModelDescription }) [key] 4 | and @Html.DisplayFor(m => Model.ValueModelDescription.ModelType, "ModelDescriptionLink", new { modelDescription = Model.ValueModelDescription }) [value] -------------------------------------------------------------------------------- /Src/FFWebApp462/Areas/HelpPage/Views/Help/DisplayTemplates/ModelDescriptionLink.cshtml: -------------------------------------------------------------------------------- 1 | @using FFWebApp462.Areas.HelpPage.ModelDescriptions 2 | @model Type 3 | @{ 4 | ModelDescription modelDescription = ViewBag.modelDescription; 5 | if (modelDescription is ComplexTypeModelDescription || modelDescription is EnumTypeModelDescription) 6 | { 7 | if (Model == typeof(Object)) 8 | { 9 | @:Object 10 | } 11 | else 12 | { 13 | @Html.ActionLink(modelDescription.Name, "ResourceModel", "Help", new { modelName = modelDescription.Name }, null) 14 | } 15 | } 16 | else if (modelDescription is CollectionModelDescription) 17 | { 18 | var collectionDescription = modelDescription as CollectionModelDescription; 19 | var elementDescription = collectionDescription.ElementDescription; 20 | @:Collection of @Html.DisplayFor(m => elementDescription.ModelType, "ModelDescriptionLink", new { modelDescription = elementDescription }) 21 | } 22 | else 23 | { 24 | @Html.DisplayFor(m => modelDescription) 25 | } 26 | } -------------------------------------------------------------------------------- /Src/FFWebApp462/Areas/HelpPage/Views/Help/DisplayTemplates/Parameters.cshtml: -------------------------------------------------------------------------------- 1 | @using System.Collections.Generic 2 | @using System.Collections.ObjectModel 3 | @using System.Web.Http.Description 4 | @using System.Threading 5 | @using FFWebApp462.Areas.HelpPage.ModelDescriptions 6 | @model IList 7 | 8 | @if (Model.Count > 0) 9 | { 10 | 11 | 12 | 13 | 14 | 15 | @foreach (ParameterDescription parameter in Model) 16 | { 17 | ModelDescription modelDescription = parameter.TypeDescription; 18 | 19 | 20 | 23 | 26 | 39 | 40 | } 41 | 42 |
NameDescriptionTypeAdditional information
@parameter.Name 21 |

@parameter.Documentation

22 |
24 | @Html.DisplayFor(m => modelDescription.ModelType, "ModelDescriptionLink", new { modelDescription = modelDescription }) 25 | 27 | @if (parameter.Annotations.Count > 0) 28 | { 29 | foreach (var annotation in parameter.Annotations) 30 | { 31 |

@annotation.Documentation

32 | } 33 | } 34 | else 35 | { 36 |

None.

37 | } 38 |
43 | } 44 | else 45 | { 46 |

None.

47 | } 48 | 49 | -------------------------------------------------------------------------------- /Src/FFWebApp462/Areas/HelpPage/Views/Help/DisplayTemplates/Samples.cshtml: -------------------------------------------------------------------------------- 1 | @using System.Net.Http.Headers 2 | @model Dictionary 3 | 4 | @{ 5 | // Group the samples into a single tab if they are the same. 6 | Dictionary samples = Model.GroupBy(pair => pair.Value).ToDictionary( 7 | pair => String.Join(", ", pair.Select(m => m.Key.ToString()).ToArray()), 8 | pair => pair.Key); 9 | var mediaTypes = samples.Keys; 10 | } 11 |
12 | @foreach (var mediaType in mediaTypes) 13 | { 14 |

@mediaType

15 |
16 | Sample: 17 | @{ 18 | var sample = samples[mediaType]; 19 | if (sample == null) 20 | { 21 |

Sample not available.

22 | } 23 | else 24 | { 25 | @Html.DisplayFor(s => sample); 26 | } 27 | } 28 |
29 | } 30 |
-------------------------------------------------------------------------------- /Src/FFWebApp462/Areas/HelpPage/Views/Help/DisplayTemplates/SimpleTypeModelDescription.cshtml: -------------------------------------------------------------------------------- 1 | @using FFWebApp462.Areas.HelpPage.ModelDescriptions 2 | @model SimpleTypeModelDescription 3 | @Model.Documentation -------------------------------------------------------------------------------- /Src/FFWebApp462/Areas/HelpPage/Views/Help/DisplayTemplates/TextSample.cshtml: -------------------------------------------------------------------------------- 1 | @using FFWebApp462.Areas.HelpPage 2 | @model TextSample 3 | 4 |
5 | @Model.Text
6 | 
-------------------------------------------------------------------------------- /Src/FFWebApp462/Areas/HelpPage/Views/Help/Index.cshtml: -------------------------------------------------------------------------------- 1 | @using System.Web.Http 2 | @using System.Web.Http.Controllers 3 | @using System.Web.Http.Description 4 | @using System.Collections.ObjectModel 5 | @using FFWebApp462.Areas.HelpPage.Models 6 | @model Collection 7 | 8 | @{ 9 | ViewBag.Title = "ASP.NET Web API Help Page"; 10 | 11 | // Group APIs by controller 12 | ILookup apiGroups = Model.ToLookup(api => api.ActionDescriptor.ControllerDescriptor); 13 | } 14 | 15 | 16 |
17 |
18 |
19 |

@ViewBag.Title

20 |
21 |
22 |
23 |
24 | 32 |
33 | @foreach (var group in apiGroups) 34 | { 35 | @Html.DisplayFor(m => group, "ApiGroup") 36 | } 37 |
38 |
39 | -------------------------------------------------------------------------------- /Src/FFWebApp462/Areas/HelpPage/Views/Help/ResourceModel.cshtml: -------------------------------------------------------------------------------- 1 | @using System.Web.Http 2 | @using FFWebApp462.Areas.HelpPage.ModelDescriptions 3 | @model ModelDescription 4 | 5 | 6 |
7 | 14 |

@Model.Name

15 |

@Model.Documentation

16 |
17 | @Html.DisplayFor(m => Model) 18 |
19 |
20 | -------------------------------------------------------------------------------- /Src/FFWebApp462/Areas/HelpPage/Views/Shared/_Layout.cshtml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | @ViewBag.Title 7 | @RenderSection("scripts", required: false) 8 | 9 | 10 | @RenderBody() 11 | 12 | -------------------------------------------------------------------------------- /Src/FFWebApp462/Areas/HelpPage/Views/Web.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 |
7 |
8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | -------------------------------------------------------------------------------- /Src/FFWebApp462/Areas/HelpPage/Views/_ViewStart.cshtml: -------------------------------------------------------------------------------- 1 | @{ 2 | // Change the Layout path below to blend the look and feel of the help page with your existing web pages 3 | Layout = "~/Views/Shared/_Layout.cshtml"; 4 | } -------------------------------------------------------------------------------- /Src/FFWebApp462/Controllers/ValuesController.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Net; 5 | using System.Net.Http; 6 | using System.Web.Http; 7 | using FFWebApp462.Models; 8 | using log4net; 9 | using StackifyLib; 10 | 11 | namespace FFWebApp462.Controllers 12 | { 13 | public class ValuesController : ApiController 14 | { 15 | private static ILog _log4NetLogger = LogManager.GetLogger(typeof(ValuesController)); 16 | 17 | // GET api/values 18 | public IEnumerable Get() 19 | { 20 | return new string[] { "value1", "value2" }; 21 | } 22 | 23 | public IEnumerable GetLog4Net() 24 | { 25 | _log4NetLogger.Debug("Log4Net Test Debug", new {clientId = 20}); 26 | _log4NetLogger.Info("Log4Net Test Info", new { clientId = 20 }); 27 | _log4NetLogger.Error("Log4Net Test Error", new { clientId = 20 }); 28 | _log4NetLogger.Fatal("Log4Net Test Fatal", new { clientId = 20 }); 29 | 30 | _log4NetLogger.Info(new {client = 99}); 31 | 32 | return new string[] { "value3", "value4" }; 33 | } 34 | 35 | // GET api/values/5 36 | public string Get(int id) 37 | { 38 | return "value"; 39 | } 40 | 41 | // POST api/values 42 | public void Post(ValueModel value) 43 | { 44 | var test = value.Value; 45 | 46 | StackifyLib.Logger.QueueException(new Exception("FF462 Failure")); 47 | } 48 | 49 | // PUT api/values/5 50 | public void Put(int id, [FromBody]string value) 51 | { 52 | } 53 | 54 | // DELETE api/values/5 55 | public void Delete(int id) 56 | { 57 | } 58 | } 59 | } 60 | -------------------------------------------------------------------------------- /Src/FFWebApp462/Global.asax: -------------------------------------------------------------------------------- 1 | <%@ Application Codebehind="Global.asax.cs" Inherits="FFWebApp462.WebApiApplication" Language="C#" %> 2 | -------------------------------------------------------------------------------- /Src/FFWebApp462/Global.asax.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Diagnostics; 4 | using System.IO; 5 | using System.Linq; 6 | using System.Web; 7 | using System.Web.Http; 8 | using System.Web.Mvc; 9 | using System.Web.Optimization; 10 | using System.Web.Routing; 11 | using log4net.Config; 12 | 13 | namespace FFWebApp462 14 | { 15 | public class WebApiApplication : System.Web.HttpApplication 16 | { 17 | protected void Application_Start() 18 | { 19 | AreaRegistration.RegisterAllAreas(); 20 | GlobalConfiguration.Configure(WebApiConfig.Register); 21 | FilterConfig.RegisterGlobalFilters(GlobalFilters.Filters); 22 | RouteConfig.RegisterRoutes(RouteTable.Routes); 23 | BundleConfig.RegisterBundles(BundleTable.Bundles); 24 | 25 | var test2 = new FileInfo(@"C:\Dev\stackify-api-dotnet\Src\FFWebApp462\log4net.config"); 26 | 27 | var test = XmlConfigurator.Configure(test2); 28 | 29 | StackifyLib.Utils.StackifyAPILogger.LogEnabled = true; 30 | StackifyLib.Utils.StackifyAPILogger.OnLogMessage += StackifyAPILogger_OnLogMessage; 31 | } 32 | 33 | static void StackifyAPILogger_OnLogMessage(string data) 34 | { 35 | Debug.WriteLine(data); 36 | } 37 | } 38 | } 39 | -------------------------------------------------------------------------------- /Src/FFWebApp462/Models/ValueModel.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Web; 5 | 6 | namespace FFWebApp462.Models 7 | { 8 | public class ValueModel 9 | { 10 | public string Value { get; set; } 11 | } 12 | } -------------------------------------------------------------------------------- /Src/FFWebApp462/Properties/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | using System.Reflection; 2 | using System.Runtime.CompilerServices; 3 | using System.Runtime.InteropServices; 4 | 5 | // General Information about an assembly is controlled through the following 6 | // set of attributes. Change these attribute values to modify the information 7 | // associated with an assembly. 8 | [assembly: AssemblyTitle("FFWebApp462")] 9 | [assembly: AssemblyDescription("")] 10 | [assembly: AssemblyConfiguration("")] 11 | [assembly: AssemblyCompany("")] 12 | [assembly: AssemblyProduct("FFWebApp462")] 13 | [assembly: AssemblyCopyright("Copyright © 2019")] 14 | [assembly: AssemblyTrademark("")] 15 | [assembly: AssemblyCulture("")] 16 | 17 | // Setting ComVisible to false makes the types in this assembly not visible 18 | // to COM components. If you need to access a type in this assembly from 19 | // COM, set the ComVisible attribute to true on that type. 20 | [assembly: ComVisible(false)] 21 | 22 | // The following GUID is for the ID of the typelib if this project is exposed to COM 23 | [assembly: Guid("f4e6237a-d65d-46c9-a496-f977177b3dd0")] 24 | 25 | // Version information for an assembly consists of the following four values: 26 | // 27 | // Major Version 28 | // Minor Version 29 | // Build Number 30 | // Revision 31 | // 32 | // You can specify all the values or you can default the Revision and Build Numbers 33 | // by using the '*' as shown below: 34 | [assembly: AssemblyVersion("1.0.0.0")] 35 | [assembly: AssemblyFileVersion("1.0.0.0")] 36 | -------------------------------------------------------------------------------- /Src/FFWebApp462/Views/Shared/Error.cshtml: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | Error 6 | 7 | 8 |
9 |

Error.

10 |

An error occurred while processing your request.

11 |
12 | 13 | 14 | -------------------------------------------------------------------------------- /Src/FFWebApp462/Views/Shared/_Layout.cshtml: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | @ViewBag.Title 7 | @Styles.Render("~/Content/css") 8 | @Scripts.Render("~/bundles/modernizr") 9 | 10 | 11 | 29 |
30 | @RenderBody() 31 |
32 |
33 |

© @DateTime.Now.Year - My ASP.NET Application

34 |
35 |
36 | 37 | @Scripts.Render("~/bundles/jquery") 38 | @Scripts.Render("~/bundles/bootstrap") 39 | @RenderSection("scripts", required: false) 40 | 41 | 42 | -------------------------------------------------------------------------------- /Src/FFWebApp462/Views/Web.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 |
7 |
8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | -------------------------------------------------------------------------------- /Src/FFWebApp462/Views/_ViewStart.cshtml: -------------------------------------------------------------------------------- 1 | @{ 2 | Layout = "~/Views/Shared/_Layout.cshtml"; 3 | } 4 | -------------------------------------------------------------------------------- /Src/FFWebApp462/Web.Debug.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 17 | 18 | 29 | 30 | 31 | -------------------------------------------------------------------------------- /Src/FFWebApp462/Web.Release.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 17 | 18 | 19 | 30 | 31 | 32 | -------------------------------------------------------------------------------- /Src/FFWebApp462/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stackify/stackify-api-dotnet/43f462adc665788e342d01bb8f5261a59636ea0d/Src/FFWebApp462/favicon.ico -------------------------------------------------------------------------------- /Src/FFWebApp462/log4net.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | -------------------------------------------------------------------------------- /Src/FFWebApp462/packages.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | -------------------------------------------------------------------------------- /Src/FullFrameworkWebApp/App_Start/BundleConfig.cs: -------------------------------------------------------------------------------- 1 | using System.Web; 2 | using System.Web.Optimization; 3 | 4 | namespace FullFrameworkWebApp 5 | { 6 | public class BundleConfig 7 | { 8 | // For more information on bundling, visit https://go.microsoft.com/fwlink/?LinkId=301862 9 | public static void RegisterBundles(BundleCollection bundles) 10 | { 11 | bundles.Add(new ScriptBundle("~/bundles/jquery").Include( 12 | "~/Scripts/jquery-{version}.js")); 13 | 14 | bundles.Add(new ScriptBundle("~/bundles/jqueryval").Include( 15 | "~/Scripts/jquery.validate*")); 16 | 17 | // Use the development version of Modernizr to develop with and learn from. Then, when you're 18 | // ready for production, use the build tool at https://modernizr.com to pick only the tests you need. 19 | bundles.Add(new ScriptBundle("~/bundles/modernizr").Include( 20 | "~/Scripts/modernizr-*")); 21 | 22 | bundles.Add(new ScriptBundle("~/bundles/bootstrap").Include( 23 | "~/Scripts/bootstrap.js")); 24 | 25 | bundles.Add(new StyleBundle("~/Content/css").Include( 26 | "~/Content/bootstrap.css", 27 | "~/Content/site.css")); 28 | } 29 | } 30 | } 31 | -------------------------------------------------------------------------------- /Src/FullFrameworkWebApp/App_Start/FilterConfig.cs: -------------------------------------------------------------------------------- 1 | using System.Web; 2 | using System.Web.Mvc; 3 | 4 | namespace FullFrameworkWebApp 5 | { 6 | public class FilterConfig 7 | { 8 | public static void RegisterGlobalFilters(GlobalFilterCollection filters) 9 | { 10 | filters.Add(new HandleErrorAttribute()); 11 | } 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /Src/FullFrameworkWebApp/App_Start/RouteConfig.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Web; 5 | using System.Web.Mvc; 6 | using System.Web.Routing; 7 | 8 | namespace FullFrameworkWebApp 9 | { 10 | public class RouteConfig 11 | { 12 | public static void RegisterRoutes(RouteCollection routes) 13 | { 14 | routes.IgnoreRoute("{resource}.axd/{*pathInfo}"); 15 | 16 | routes.MapRoute( 17 | name: "Default", 18 | url: "{controller}/{action}/{id}", 19 | defaults: new { controller = "Home", action = "Index", id = UrlParameter.Optional } 20 | ); 21 | } 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /Src/FullFrameworkWebApp/Content/Site.css: -------------------------------------------------------------------------------- 1 | body { 2 | padding-top: 50px; 3 | padding-bottom: 20px; 4 | } 5 | 6 | /* Set padding to keep content from hitting the edges */ 7 | .body-content { 8 | padding-left: 15px; 9 | padding-right: 15px; 10 | } 11 | 12 | /* Override the default bootstrap behavior where horizontal description lists 13 | will truncate terms that are too long to fit in the left column 14 | */ 15 | .dl-horizontal dt { 16 | white-space: normal; 17 | } 18 | 19 | /* Set width on the form input elements since they're 100% wide by default */ 20 | input, 21 | select, 22 | textarea { 23 | max-width: 280px; 24 | } 25 | -------------------------------------------------------------------------------- /Src/FullFrameworkWebApp/Global.asax: -------------------------------------------------------------------------------- 1 | <%@ Application Codebehind="Global.asax.cs" Inherits="FullFrameworkWebApp.MvcApplication" Language="C#" %> 2 | -------------------------------------------------------------------------------- /Src/FullFrameworkWebApp/Global.asax.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Web; 5 | using System.Web.Mvc; 6 | using System.Web.Optimization; 7 | using System.Web.Routing; 8 | 9 | namespace FullFrameworkWebApp 10 | { 11 | public class MvcApplication : System.Web.HttpApplication 12 | { 13 | protected void Application_Start() 14 | { 15 | AreaRegistration.RegisterAllAreas(); 16 | FilterConfig.RegisterGlobalFilters(GlobalFilters.Filters); 17 | RouteConfig.RegisterRoutes(RouteTable.Routes); 18 | BundleConfig.RegisterBundles(BundleTable.Bundles); 19 | } 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /Src/FullFrameworkWebApp/Properties/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | using System.Reflection; 2 | using System.Runtime.CompilerServices; 3 | using System.Runtime.InteropServices; 4 | 5 | // General Information about an assembly is controlled through the following 6 | // set of attributes. Change these attribute values to modify the information 7 | // associated with an assembly. 8 | [assembly: AssemblyTitle("FullFrameworkWebApp")] 9 | [assembly: AssemblyDescription("")] 10 | [assembly: AssemblyConfiguration("")] 11 | [assembly: AssemblyCompany("")] 12 | [assembly: AssemblyProduct("FullFrameworkWebApp")] 13 | [assembly: AssemblyCopyright("Copyright © 2021")] 14 | [assembly: AssemblyTrademark("")] 15 | [assembly: AssemblyCulture("")] 16 | 17 | // Setting ComVisible to false makes the types in this assembly not visible 18 | // to COM components. If you need to access a type in this assembly from 19 | // COM, set the ComVisible attribute to true on that type. 20 | [assembly: ComVisible(false)] 21 | 22 | // The following GUID is for the ID of the typelib if this project is exposed to COM 23 | [assembly: Guid("96e9aa86-5206-455c-a415-2a1abec67015")] 24 | 25 | // Version information for an assembly consists of the following four values: 26 | // 27 | // Major Version 28 | // Minor Version 29 | // Build Number 30 | // Revision 31 | // 32 | // You can specify all the values or you can default the Revision and Build Numbers 33 | // by using the '*' as shown below: 34 | [assembly: AssemblyVersion("1.0.0.0")] 35 | [assembly: AssemblyFileVersion("1.0.0.0")] 36 | -------------------------------------------------------------------------------- /Src/FullFrameworkWebApp/Stackify.json: -------------------------------------------------------------------------------- 1 | { 2 | "AppName": "FullFrameworkWebAppTestJson", 3 | "Environment": "TestingJson", 4 | "ApiKey": "" 5 | } 6 | -------------------------------------------------------------------------------- /Src/FullFrameworkWebApp/Views/Home/About.cshtml: -------------------------------------------------------------------------------- 1 | @{ 2 | ViewBag.Title = "About"; 3 | } 4 |

@ViewBag.Title.

5 |

@ViewBag.Message

6 | 7 |

Use this area to provide additional information.

8 | -------------------------------------------------------------------------------- /Src/FullFrameworkWebApp/Views/Home/Contact.cshtml: -------------------------------------------------------------------------------- 1 | @{ 2 | ViewBag.Title = "Contact"; 3 | } 4 |

@ViewBag.Title.

5 |

@ViewBag.Message

6 | 7 |
8 | One Microsoft Way
9 | Redmond, WA 98052-6399
10 | P: 11 | 425.555.0100 12 |
13 | 14 |
15 | Support: Support@example.com
16 | Marketing: Marketing@example.com 17 |
-------------------------------------------------------------------------------- /Src/FullFrameworkWebApp/Views/Home/Index.cshtml: -------------------------------------------------------------------------------- 1 | @{ 2 | ViewBag.Title = "Home Page"; 3 | } 4 | 5 |
6 |

ASP.NET

7 |

ASP.NET is a free web framework for building great Web sites and Web applications using HTML, CSS and JavaScript.

8 |

Learn more »

9 |
10 | 11 |
12 |
13 |

Getting started

14 |

15 | ASP.NET MVC gives you a powerful, patterns-based way to build dynamic websites that 16 | enables a clean separation of concerns and gives you full control over markup 17 | for enjoyable, agile development. 18 |

19 |

Learn more »

20 |
21 |
22 |

Get more libraries

23 |

NuGet is a free Visual Studio extension that makes it easy to add, remove, and update libraries and tools in Visual Studio projects.

24 |

Learn more »

25 |
26 |
27 |

Web Hosting

28 |

You can easily find a web hosting company that offers the right mix of features and price for your applications.

29 |

Learn more »

30 |
31 |

@ViewBag.AppName

32 |

@ViewBag.Environment

33 |

@ViewBag.ApiKey

34 |
-------------------------------------------------------------------------------- /Src/FullFrameworkWebApp/Views/Shared/Error.cshtml: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | Error 6 | 7 | 8 |
9 |

Error.

10 |

An error occurred while processing your request.

11 |
12 | 13 | 14 | -------------------------------------------------------------------------------- /Src/FullFrameworkWebApp/Views/Shared/_Layout.cshtml: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | @ViewBag.Title - My ASP.NET Application 7 | @Styles.Render("~/Content/css") 8 | @Scripts.Render("~/bundles/modernizr") 9 | 10 | 11 | 30 |
31 | @RenderBody() 32 |
33 |
34 |

© @DateTime.Now.Year - My ASP.NET Application

35 |
36 |
37 | 38 | @Scripts.Render("~/bundles/jquery") 39 | @Scripts.Render("~/bundles/bootstrap") 40 | @RenderSection("scripts", required: false) 41 | 42 | 43 | -------------------------------------------------------------------------------- /Src/FullFrameworkWebApp/Views/Web.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 |
7 |
8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | -------------------------------------------------------------------------------- /Src/FullFrameworkWebApp/Views/_ViewStart.cshtml: -------------------------------------------------------------------------------- 1 | @{ 2 | Layout = "~/Views/Shared/_Layout.cshtml"; 3 | } 4 | -------------------------------------------------------------------------------- /Src/FullFrameworkWebApp/Web.Debug.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 17 | 18 | 29 | 30 | 31 | -------------------------------------------------------------------------------- /Src/FullFrameworkWebApp/Web.Release.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 17 | 18 | 19 | 30 | 31 | 32 | -------------------------------------------------------------------------------- /Src/FullFrameworkWebApp/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stackify/stackify-api-dotnet/43f462adc665788e342d01bb8f5261a59636ea0d/Src/FullFrameworkWebApp/favicon.ico -------------------------------------------------------------------------------- /Src/FullFrameworkWebApp/fonts/glyphicons-halflings-regular.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stackify/stackify-api-dotnet/43f462adc665788e342d01bb8f5261a59636ea0d/Src/FullFrameworkWebApp/fonts/glyphicons-halflings-regular.eot -------------------------------------------------------------------------------- /Src/FullFrameworkWebApp/fonts/glyphicons-halflings-regular.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stackify/stackify-api-dotnet/43f462adc665788e342d01bb8f5261a59636ea0d/Src/FullFrameworkWebApp/fonts/glyphicons-halflings-regular.ttf -------------------------------------------------------------------------------- /Src/FullFrameworkWebApp/fonts/glyphicons-halflings-regular.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stackify/stackify-api-dotnet/43f462adc665788e342d01bb8f5261a59636ea0d/Src/FullFrameworkWebApp/fonts/glyphicons-halflings-regular.woff -------------------------------------------------------------------------------- /Src/FullFrameworkWebApp/fonts/glyphicons-halflings-regular.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/stackify/stackify-api-dotnet/43f462adc665788e342d01bb8f5261a59636ea0d/Src/FullFrameworkWebApp/fonts/glyphicons-halflings-regular.woff2 -------------------------------------------------------------------------------- /Src/FullFrameworkWebApp/packages.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /Src/NLog.Targets.Stackify/Properties/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | using System.Reflection; 2 | using System.Runtime.CompilerServices; 3 | using System.Runtime.InteropServices; 4 | 5 | // General Information about an assembly is controlled through the following 6 | // set of attributes. Change these attribute values to modify the information 7 | // associated with an assembly. 8 | [assembly: AssemblyTitle("NLog.Targets.Stackify")] 9 | [assembly: AssemblyDescription("NLog.Targets.Stackify")] 10 | [assembly: AssemblyConfiguration("")] 11 | [assembly: AssemblyCompany("Stackify")] 12 | [assembly: AssemblyProduct("NLog.Targets.Stackify")] 13 | [assembly: AssemblyCopyright("Copyright © 2015")] 14 | [assembly: AssemblyTrademark("")] 15 | [assembly: AssemblyCulture("")] 16 | //[assembly: AssemblyKeyFile("..\\StackifyLib\\Netreo.snk")] 17 | 18 | // Setting ComVisible to false makes the types in this assembly not visible 19 | // to COM components. If you need to access a type in this assembly from 20 | // COM, set the ComVisible attribute to true on that type. 21 | [assembly: ComVisible(false)] 22 | 23 | // The following GUID is for the ID of the typelib if this project is exposed to COM 24 | [assembly: Guid("d7190bf4-0c3c-4b57-9e9b-8e5811b0cd25")] 25 | 26 | // Version information for an assembly consists of the following four values: 27 | // 28 | // Major Version 29 | // Minor Version 30 | // Build Number 31 | // Revision 32 | // 33 | // You can specify all the values or you can default the Build and Revision Numbers 34 | // by using the '*' as shown below: 35 | // [assembly: AssemblyVersion("1.0.*")] 36 | [assembly: AssemblyVersion("2.1.1.0")] 37 | [assembly: AssemblyFileVersion("2.1.1.0")] 38 | -------------------------------------------------------------------------------- /Src/NLog.Web.Stackify/StackifyHttpLayoutRenderer.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.IO; 3 | using System.Text; 4 | using NLog.Config; 5 | using NLog.LayoutRenderers; 6 | using NLog.Web.LayoutRenderers; 7 | using StackifyLib.Models; 8 | using Newtonsoft.Json; 9 | 10 | namespace NLog.Web.Stackify 11 | { 12 | [LayoutRenderer("stackify-http")] 13 | [ThreadSafe] 14 | public class StackifyHttpLayoutRenderer : AspNetLayoutRendererBase 15 | { 16 | protected override void DoAppend(StringBuilder builder, LogEventInfo logEvent) 17 | { 18 | var httpRequest = HttpContextAccessor.HttpContext; 19 | if (httpRequest != null) 20 | { 21 | #if NETFULL 22 | WebRequestDetail webRequest = new WebRequestDetail(); 23 | webRequest.Load(httpRequest); 24 | 25 | string result = JsonConvert.SerializeObject(webRequest); 26 | builder.Append(result); 27 | #endif 28 | } 29 | } 30 | } 31 | } 32 | -------------------------------------------------------------------------------- /Src/Package.bat: -------------------------------------------------------------------------------- 1 | dotnet pack StackifyLib\StackifyLib.csproj -c Release -o ..\BuildOutput 2 | dotnet pack StackifyLib.AspNetCore\StackifyLib.AspNetCore.csproj -c Release -o ..\BuildOutput 3 | dotnet pack NLog.Targets.Stackify\NLog.Targets.Stackify.csproj -c Release -o ..\BuildOutput 4 | dotnet pack StackifyLib.CoreLogger\StackifyLib.CoreLogger.csproj -c Release -o ..\BuildOutput 5 | dotnet pack StackifyLib.log4net\StackifyLib.log4net.csproj -c Release -o ..\BuildOutput 6 | dotnet pack StackifyLib.StackifyTraceListener\StackifyLib.StackifyTraceListener.csproj -c Release -o ..\BuildOutput 7 | 8 | REM dotnet pack C:\BitBucket\Serilog.Sinks.Stackify\Serilog.Sinks.Stackify\project.json -c Release -o C:\BitBucket\stackify-api-dotnet\BuildOutput -------------------------------------------------------------------------------- /Src/StackifyLib.AspNetCore/Configure.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using StackifyLib.Models; 3 | 4 | namespace StackifyLib.AspNetCore 5 | { 6 | internal class Configure 7 | { 8 | internal static IServiceProvider ServiceProvider { get; set; } 9 | 10 | internal static void SubscribeToWebRequestDetails(IServiceProvider serviceProvider) 11 | { 12 | if (ServiceProvider != null) 13 | { 14 | return; 15 | } 16 | 17 | ServiceProvider = serviceProvider; 18 | 19 | WebRequestDetail.SetWebRequestDetail += WebRequestDetailMapper.WebRequestDetail_SetWebRequestDetail; 20 | } 21 | } 22 | } -------------------------------------------------------------------------------- /Src/StackifyLib.AspNetCore/Extensions.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Diagnostics; 3 | using StackifyLib.AspNetCore; 4 | 5 | namespace StackifyLib 6 | { 7 | public static class Extensions 8 | { 9 | public static void ConfigureStackifyLogging(this Microsoft.AspNetCore.Builder.IApplicationBuilder app, Microsoft.Extensions.Configuration.IConfiguration configuration) 10 | { 11 | try 12 | { 13 | Configure.SubscribeToWebRequestDetails(app.ApplicationServices); 14 | } 15 | catch (Exception ex) 16 | { 17 | Debug.WriteLine($"#Extensions - #AspNetCore - Error Subscribing to WebRequestDetails {ex}"); 18 | StackifyLib.Utils.StackifyAPILogger.Log("#Extensions - #AspNetCore - Error Subscribing to WebRequestDetails", ex); 19 | } 20 | 21 | try 22 | { 23 | if (configuration == null) 24 | { 25 | StackifyLib.Utils.StackifyAPILogger.Log("#Extensions - #AspNetCore - Empty configuration, ignoring"); 26 | return; 27 | } 28 | 29 | StackifyLib.Utils.StackifyAPILogger.Log("#Extensions - #AspNetCore - ConfigureStackifyLogging - Initialize"); 30 | StackifyLib.Config.SetConfiguration(configuration); 31 | StackifyLib.Utils.StackifyAPILogger.Log("#Extensions - #AspNetCore - ConfigureStackifyLogging - Settings Loaded"); 32 | Config.LoadSettings(); 33 | } 34 | catch (Exception ex) 35 | { 36 | Debug.WriteLine($"#Extensions - #AspNetCore - Error in ConfigureStackifyLogging {ex}"); 37 | StackifyLib.Utils.StackifyAPILogger.Log("#Extensions - #AspNetCore - Error in ConfigureStackifyLogging", ex); 38 | } 39 | } 40 | } 41 | } -------------------------------------------------------------------------------- /Src/StackifyLib.AspNetCore/Properties/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | using System.Reflection; 2 | using System.Runtime.CompilerServices; 3 | using System.Runtime.InteropServices; 4 | 5 | // General Information about an assembly is controlled through the following 6 | // set of attributes. Change these attribute values to modify the information 7 | // associated with an assembly. 8 | [assembly: AssemblyConfiguration("")] 9 | [assembly: AssemblyCompany("Stackify")] 10 | [assembly: AssemblyProduct("StackifyLib.AspNetCore")] 11 | [assembly: AssemblyTrademark("")] 12 | //[assembly: AssemblyKeyFile("..\\StackifyLib\\Netreo.snk")] 13 | 14 | // Setting ComVisible to false makes the types in this assembly not visible 15 | // to COM components. If you need to access a type in this assembly from 16 | // COM, set the ComVisible attribute to true on that type. 17 | [assembly: ComVisible(false)] 18 | 19 | // The following GUID is for the ID of the typelib if this project is exposed to COM 20 | [assembly: Guid("e141cde4-501c-4533-8a2e-344522b1991e")] 21 | -------------------------------------------------------------------------------- /Src/StackifyLib.CoreLogger/LoggingExtensions.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using Microsoft.Extensions.Logging; 3 | 4 | namespace StackifyLib.CoreLogger 5 | { 6 | public static class LoggingExtensions 7 | { 8 | public static ILoggerFactory AddStackify(this ILoggerFactory factory, ILogger logger = null, bool dispose = false) 9 | { 10 | if (factory == null) 11 | { 12 | throw new ArgumentNullException("factory"); 13 | } 14 | 15 | factory.AddProvider(new StackifyLoggerProvider()); 16 | return factory; 17 | } 18 | } 19 | } -------------------------------------------------------------------------------- /Src/StackifyLib.CoreLogger/Properties/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | using System.Reflection; 2 | using System.Runtime.CompilerServices; 3 | using System.Runtime.InteropServices; 4 | 5 | // General Information about an assembly is controlled through the following 6 | // set of attributes. Change these attribute values to modify the information 7 | // associated with an assembly. 8 | [assembly: AssemblyConfiguration("")] 9 | [assembly: AssemblyCompany("Stackify")] 10 | [assembly: AssemblyProduct("StackifyLib.CoreLogger")] 11 | [assembly: AssemblyTrademark("")] 12 | //[assembly: AssemblyKeyFile("..\\StackifyLib\\Netreo.snk")] 13 | 14 | // Setting ComVisible to false makes the types in this assembly not visible 15 | // to COM components. If you need to access a type in this assembly from 16 | // COM, set the ComVisible attribute to true on that type. 17 | [assembly: ComVisible(false)] 18 | 19 | // The following GUID is for the ID of the typelib if this project is exposed to COM 20 | [assembly: Guid("cb09d719-f393-413d-b5cd-e0125543ad24")] 21 | -------------------------------------------------------------------------------- /Src/StackifyLib.CoreLogger/StackifyLib.CoreLogger.csproj: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | Stackify .NET Core LoggerFactory 5 | 2.1.0 6 | netstandard2.0;net461;net462 7 | StackifyLib.CoreLogger 8 | StackifyLib.CoreLogger 9 | stackify;metrics;errors;logs 10 | false 11 | false 12 | false 13 | https://github.com/stackify/stackify-api-dotnet/blob/master/LICENSE 14 | https://github.com/stackify/stackify-api-dotnet 15 | https://github.com/stackify/stackify-api-dotnet 16 | git 17 | https://stackify.com/wp-content/uploads/2017/02/stk.png 18 | StackifyLib.CoreLogger 19 | 2.1.1 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | -------------------------------------------------------------------------------- /Src/StackifyLib.CoreLogger/StackifyLogger.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using Microsoft.Extensions.Logging; 3 | using StackifyLib.Models; 4 | 5 | namespace StackifyLib.CoreLogger 6 | { 7 | public class StackifyLogger : Microsoft.Extensions.Logging.ILogger 8 | { 9 | public IDisposable BeginScope(TState state) 10 | { 11 | return null; 12 | } 13 | 14 | public bool IsEnabled(LogLevel logLevel) 15 | { 16 | return true; 17 | } 18 | 19 | public void Log(LogLevel logLevel, EventId eventId, TState state, Exception exception, Func formatter) 20 | { 21 | if (formatter == null) 22 | { 23 | throw new ArgumentNullException("formatter"); 24 | } 25 | 26 | var message = formatter(state, exception); 27 | if (string.IsNullOrEmpty(message)) 28 | { 29 | return; 30 | } 31 | 32 | var msg = new LogMsg 33 | { 34 | Level = logLevel.ToString(), 35 | Msg = message 36 | }; 37 | 38 | StackifyLib.Logger.QueueLogObject(msg, exception); 39 | } 40 | 41 | public void Close() 42 | { 43 | try 44 | { 45 | StackifyLib.Logger.Shutdown(); 46 | } 47 | catch (Exception) 48 | { 49 | // ignored 50 | } 51 | } 52 | } 53 | } -------------------------------------------------------------------------------- /Src/StackifyLib.CoreLogger/StackifyLoggerProvider.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using Microsoft.Extensions.Logging; 3 | 4 | namespace StackifyLib.CoreLogger 5 | { 6 | public class StackifyLoggerProvider : ILoggerProvider 7 | { 8 | private StackifyLogger _stackifyLogger; 9 | 10 | public Microsoft.Extensions.Logging.ILogger CreateLogger(string name) 11 | { 12 | if (_stackifyLogger == null) 13 | { 14 | _stackifyLogger = new StackifyLogger(); 15 | } 16 | 17 | return _stackifyLogger; 18 | } 19 | 20 | public void Dispose() 21 | { 22 | _stackifyLogger?.Close(); 23 | } 24 | } 25 | } -------------------------------------------------------------------------------- /Src/StackifyLib.ELMAH/Properties/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | using System.Reflection; 2 | using System.Runtime.CompilerServices; 3 | using System.Runtime.InteropServices; 4 | 5 | // General Information about an assembly is controlled through the following 6 | // set of attributes. Change these attribute values to modify the information 7 | // associated with an assembly. 8 | [assembly: AssemblyTitle("Stackify.ELMAH")] 9 | [assembly: AssemblyDescription("")] 10 | [assembly: AssemblyConfiguration("")] 11 | [assembly: AssemblyCompany("")] 12 | [assembly: AssemblyProduct("Stackify.ELMAH")] 13 | [assembly: AssemblyCopyright("Copyright © 2015")] 14 | [assembly: AssemblyTrademark("")] 15 | [assembly: AssemblyCulture("")] 16 | //[assembly: AssemblyKeyFile("..\\StackifyLib\\Netreo.snk")] 17 | 18 | // Setting ComVisible to false makes the types in this assembly not visible 19 | // to COM components. If you need to access a type in this assembly from 20 | // COM, set the ComVisible attribute to true on that type. 21 | [assembly: ComVisible(false)] 22 | 23 | // The following GUID is for the ID of the typelib if this project is exposed to COM 24 | [assembly: Guid("1c3a92bc-9fad-4ba0-88ae-d06e4ec69c2e")] 25 | 26 | // Version information for an assembly consists of the following four values: 27 | // 28 | // Major Version 29 | // Minor Version 30 | // Build Number 31 | // Revision 32 | // 33 | // You can specify all the values or you can default the Build and Revision Numbers 34 | // by using the '*' as shown below: 35 | // [assembly: AssemblyVersion("1.0.*")] 36 | [assembly: AssemblyVersion("1.18.1.0")] 37 | [assembly: AssemblyFileVersion("1.18.1.0")] 38 | -------------------------------------------------------------------------------- /Src/StackifyLib.ELMAH/StackifyErrorLog.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | using System.Threading.Tasks; 6 | using Elmah; 7 | using StackifyLib; 8 | using System.Collections; 9 | using StackifyLib.Utils; 10 | 11 | namespace StackifyLib.ELMAH 12 | { 13 | public class StackifyErrorLog : ErrorLog 14 | { 15 | private static readonly ErrorGovernor governor = new ErrorGovernor(); 16 | 17 | public StackifyErrorLog(){} 18 | 19 | public StackifyErrorLog(IDictionary config) 20 | { 21 | } 22 | 23 | public override ErrorLogEntry GetError(string id) 24 | { 25 | throw new NotImplementedException(); 26 | } 27 | 28 | public override int GetErrors(int pageIndex, int pageSize, System.Collections.IList errorEntryList) 29 | { 30 | throw new NotImplementedException(); 31 | } 32 | 33 | public override string Log(Error e) 34 | { 35 | try 36 | { 37 | StackifyError error = StackifyError.New(e.Exception); 38 | 39 | if (governor.ErrorShouldBeSent(error)) 40 | { 41 | error.SendToStackify(); 42 | } 43 | } 44 | catch (Exception ex) 45 | { 46 | System.Diagnostics.Debug.WriteLine(ex); 47 | } 48 | 49 | var newId = Guid.NewGuid(); 50 | return newId.ToString(); 51 | } 52 | 53 | 54 | } 55 | } 56 | -------------------------------------------------------------------------------- /Src/StackifyLib.ELMAH/packages.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | -------------------------------------------------------------------------------- /Src/StackifyLib.NoWeb/Properties/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | using System.Reflection; 2 | using System.Runtime.CompilerServices; 3 | using System.Runtime.InteropServices; 4 | 5 | // General Information about an assembly is controlled through the following 6 | // set of attributes. Change these attribute values to modify the information 7 | // associated with an assembly. 8 | [assembly: AssemblyTitle("StackifyLib.NoWeb")] 9 | [assembly: AssemblyDescription("")] 10 | [assembly: AssemblyConfiguration("")] 11 | [assembly: AssemblyCompany("")] 12 | [assembly: AssemblyProduct("StackifyLib.NoWeb")] 13 | [assembly: AssemblyCopyright("Copyright © 2017")] 14 | [assembly: AssemblyTrademark("")] 15 | [assembly: AssemblyCulture("")] 16 | 17 | // Setting ComVisible to false makes the types in this assembly not visible 18 | // to COM components. If you need to access a type in this assembly from 19 | // COM, set the ComVisible attribute to true on that type. 20 | [assembly: ComVisible(false)] 21 | 22 | // The following GUID is for the ID of the typelib if this project is exposed to COM 23 | [assembly: Guid("e0f58633-c6f1-4e4f-910a-97633d8afcff")] 24 | 25 | // Version information for an assembly consists of the following four values: 26 | // 27 | // Major Version 28 | // Minor Version 29 | // Build Number 30 | // Revision 31 | // 32 | // You can specify all the values or you can default the Build and Revision Numbers 33 | // by using the '*' as shown below: 34 | // [assembly: AssemblyVersion("1.0.*")] 35 | [assembly: AssemblyVersion("1.0.0.0")] 36 | [assembly: AssemblyFileVersion("1.0.0.0")] 37 | -------------------------------------------------------------------------------- /Src/StackifyLib.NoWeb/packages.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | -------------------------------------------------------------------------------- /Src/StackifyLib.StackifyTraceListener/Properties/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | using System.Reflection; 2 | using System.Runtime.CompilerServices; 3 | using System.Runtime.InteropServices; 4 | 5 | // General Information about an assembly is controlled through the following 6 | // set of attributes. Change these attribute values to modify the information 7 | // associated with an assembly. 8 | [assembly: AssemblyConfiguration("")] 9 | [assembly: AssemblyCompany("Stackify")] 10 | [assembly: AssemblyProduct("StackifyLib.StackifyTraceListener")] 11 | [assembly: AssemblyTrademark("")] 12 | //[assembly: AssemblyKeyFile("..\\StackifyLib\\Netreo.snk")] 13 | 14 | // Setting ComVisible to false makes the types in this assembly not visible 15 | // to COM components. If you need to access a type in this assembly from 16 | // COM, set the ComVisible attribute to true on that type. 17 | [assembly: ComVisible(false)] 18 | 19 | // The following GUID is for the ID of the typelib if this project is exposed to COM 20 | [assembly: Guid("28a61379-b316-480f-b45e-c622c42cae8d")] 21 | -------------------------------------------------------------------------------- /Src/StackifyLib.StackifyTraceListener/StackifyLib.StackifyTraceListener.csproj: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 2.0.0 5 | netstandard2.0;net40;net45;net451;net452;net46 6 | StackifyLib.StackifyTraceListener 7 | StackifyLib.StackifyTraceListener 8 | false 9 | false 10 | false 11 | 2.1.0 12 | StackifyLib.StackifyTraceListener 13 | https://github.com/stackify/stackify-api-dotnet/blob/master/LICENSE 14 | https://github.com/stackify/stackify-api-dotnet 15 | https://github.com/stackify/stackify-api-dotnet 16 | git 17 | https://stackify.com/wp-content/uploads/2017/02/stk.png 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | -------------------------------------------------------------------------------- /Src/StackifyLib.log4net.Sitecore/FodyWeavers.xml: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /Src/StackifyLib.log4net.Sitecore/Log4NetExtensions.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using StackifyLib.Models; 3 | using log4net; 4 | 5 | namespace StackifyLib 6 | { 7 | public static class Extensions 8 | { 9 | private static LogMessage GetMessage(string message, object debugData) 10 | { 11 | return new LogMessage() { message = message, json = debugData }; 12 | } 13 | 14 | public static void Debug(this ILog log, string message, object debugData) 15 | { 16 | log.Debug(GetMessage(message, debugData)); 17 | } 18 | 19 | public static void Info(this ILog log, string message, object debugData) 20 | { 21 | log.Info(GetMessage(message, debugData)); 22 | } 23 | 24 | public static void Warn(this ILog log, string message, object debugData) 25 | { 26 | log.Warn(GetMessage(message, debugData)); 27 | } 28 | 29 | public static void Warn(this ILog log, string message, object debugData, Exception exception) 30 | { 31 | log.Warn(GetMessage(message, debugData), exception); 32 | } 33 | 34 | public static void Error(this ILog log, string message, object debugData) 35 | { 36 | log.Error(GetMessage(message, debugData)); 37 | } 38 | 39 | public static void Error(this ILog log, string message, object debugData, Exception exception) 40 | { 41 | log.Error(GetMessage(message, debugData), exception); 42 | } 43 | 44 | public static void Fatal(this ILog log, string message, object debugData) 45 | { 46 | log.Fatal(GetMessage(message, debugData)); 47 | } 48 | 49 | public static void Fatal(this ILog log, string message, object debugData, Exception exception) 50 | { 51 | log.Fatal(GetMessage(message, debugData), exception); 52 | } 53 | } 54 | } 55 | -------------------------------------------------------------------------------- /Src/StackifyLib.log4net.Sitecore/Properties/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | using System.Reflection; 2 | using System.Runtime.CompilerServices; 3 | using System.Runtime.InteropServices; 4 | 5 | // General Information about an assembly is controlled through the following 6 | // set of attributes. Change these attribute values to modify the information 7 | // associated with an assembly. 8 | [assembly: AssemblyTitle("StackifyLib.log4net.Sitecore")] 9 | [assembly: AssemblyDescription("")] 10 | [assembly: AssemblyConfiguration("")] 11 | [assembly: AssemblyCompany("")] 12 | [assembly: AssemblyProduct("StackifyLib.log4net.Sitecore")] 13 | [assembly: AssemblyCopyright("Copyright © 2015")] 14 | [assembly: AssemblyTrademark("")] 15 | [assembly: AssemblyCulture("")] 16 | 17 | // Setting ComVisible to false makes the types in this assembly not visible 18 | // to COM components. If you need to access a type in this assembly from 19 | // COM, set the ComVisible attribute to true on that type. 20 | [assembly: ComVisible(false)] 21 | 22 | // The following GUID is for the ID of the typelib if this project is exposed to COM 23 | [assembly: Guid("2963dd01-d67d-4666-b21a-f0d627629535")] 24 | 25 | // Version information for an assembly consists of the following four values: 26 | // 27 | // Major Version 28 | // Minor Version 29 | // Build Number 30 | // Revision 31 | // 32 | // You can specify all the values or you can default the Build and Revision Numbers 33 | // by using the '*' as shown below: 34 | // [assembly: AssemblyVersion("1.0.*")] 35 | [assembly: AssemblyVersion("1.17.*")] 36 | [assembly: AssemblyFileVersion("1.17.*")] 37 | -------------------------------------------------------------------------------- /Src/StackifyLib.log4net.Sitecore/packages.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | -------------------------------------------------------------------------------- /Src/StackifyLib.log4net.Tests/Properties/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | using System.Reflection; 2 | using System.Runtime.CompilerServices; 3 | using System.Runtime.InteropServices; 4 | 5 | // General Information about an assembly is controlled through the following 6 | // set of attributes. Change these attribute values to modify the information 7 | // associated with an assembly. 8 | [assembly: AssemblyTitle("StackifyLib.log4net.Tests")] 9 | [assembly: AssemblyDescription("")] 10 | [assembly: AssemblyConfiguration("")] 11 | [assembly: AssemblyCompany("")] 12 | [assembly: AssemblyProduct("StackifyLib.log4net.Tests")] 13 | [assembly: AssemblyCopyright("Copyright © 2015")] 14 | [assembly: AssemblyTrademark("")] 15 | [assembly: AssemblyCulture("")] 16 | 17 | // Setting ComVisible to false makes the types in this assembly not visible 18 | // to COM components. If you need to access a type in this assembly from 19 | // COM, set the ComVisible attribute to true on that type. 20 | [assembly: ComVisible(false)] 21 | 22 | // The following GUID is for the ID of the typelib if this project is exposed to COM 23 | [assembly: Guid("18f96933-468e-4104-961e-0c68a5ef2b29")] 24 | 25 | // Version information for an assembly consists of the following four values: 26 | // 27 | // Major Version 28 | // Minor Version 29 | // Build Number 30 | // Revision 31 | // 32 | // You can specify all the values or you can default the Build and Revision Numbers 33 | // by using the '*' as shown below: 34 | // [assembly: AssemblyVersion("1.0.*")] 35 | [assembly: AssemblyVersion("1.0.0.0")] 36 | [assembly: AssemblyFileVersion("1.0.0.0")] 37 | -------------------------------------------------------------------------------- /Src/StackifyLib.log4net.Tests/packages.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | -------------------------------------------------------------------------------- /Src/StackifyLib.log4net.v1_2_10/ExceptionAppender.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | using System.Threading.Tasks; 6 | using log4net.Appender; 7 | using System.Diagnostics; 8 | using log4net.Core; 9 | using Apache_log4net = log4net; 10 | using StackifyLib.Utils; 11 | 12 | namespace StackifyLib.log4net 13 | { 14 | public class ExceptionAppender : StackifyAppender 15 | { 16 | protected override void Append(LoggingEvent loggingEvent) 17 | { 18 | if (Level.Error == loggingEvent.Level || Level.Fatal == loggingEvent.Level) 19 | { 20 | base.Append(loggingEvent); 21 | } 22 | } 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /Src/StackifyLib.log4net.v1_2_10/Log4NetExtensions.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Diagnostics; 4 | using System.Linq; 5 | using System.Text; 6 | using StackifyLib.Models; 7 | using log4net.Core; 8 | using log4net; 9 | using StackifyLib; 10 | 11 | namespace StackifyLib 12 | { 13 | public static class Extensions 14 | { 15 | private static LogMessage GetMessage(string message, object debugData) 16 | { 17 | return new LogMessage() { message = message, json = debugData }; 18 | } 19 | 20 | public static void Debug(this ILog log, string message, object debugData) 21 | { 22 | log.Debug(GetMessage(message, debugData)); 23 | } 24 | 25 | public static void Info(this ILog log, string message, object debugData) 26 | { 27 | log.Info(GetMessage(message, debugData)); 28 | } 29 | 30 | public static void Warn(this ILog log, string message, object debugData) 31 | { 32 | log.Warn(GetMessage(message, debugData)); 33 | } 34 | 35 | public static void Warn(this ILog log, string message, object debugData, Exception exception) 36 | { 37 | log.Warn(GetMessage(message, debugData), exception); 38 | } 39 | 40 | public static void Error(this ILog log, string message, object debugData) 41 | { 42 | log.Error(GetMessage(message, debugData)); 43 | } 44 | 45 | public static void Error(this ILog log, string message, object debugData, Exception exception) 46 | { 47 | log.Error(GetMessage(message, debugData), exception); 48 | } 49 | 50 | public static void Fatal(this ILog log, string message, object debugData) 51 | { 52 | log.Fatal(GetMessage(message, debugData)); 53 | } 54 | 55 | public static void Fatal(this ILog log, string message, object debugData, Exception exception) 56 | { 57 | log.Fatal(GetMessage(message, debugData), exception); 58 | } 59 | } 60 | } 61 | -------------------------------------------------------------------------------- /Src/StackifyLib.log4net.v1_2_10/Properties/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | using System.Reflection; 2 | using System.Runtime.CompilerServices; 3 | using System.Runtime.InteropServices; 4 | 5 | // General Information about an assembly is controlled through the following 6 | // set of attributes. Change these attribute values to modify the information 7 | // associated with an assembly. 8 | [assembly: AssemblyTitle("StackifyLib.log4net")] 9 | [assembly: AssemblyDescription("")] 10 | [assembly: AssemblyConfiguration("")] 11 | [assembly: AssemblyCompany("")] 12 | [assembly: AssemblyProduct("StackifyLib.log4net")] 13 | [assembly: AssemblyCopyright("Copyright © 2015")] 14 | [assembly: AssemblyTrademark("")] 15 | [assembly: AssemblyCulture("")] 16 | 17 | // Setting ComVisible to false makes the types in this assembly not visible 18 | // to COM components. If you need to access a type in this assembly from 19 | // COM, set the ComVisible attribute to true on that type. 20 | [assembly: ComVisible(false)] 21 | 22 | // The following GUID is for the ID of the typelib if this project is exposed to COM 23 | [assembly: Guid("c8bf288e-5e11-4529-ba70-8d3a9063775f")] 24 | 25 | // Version information for an assembly consists of the following four values: 26 | // 27 | // Major Version 28 | // Minor Version 29 | // Build Number 30 | // Revision 31 | // 32 | // You can specify all the values or you can default the Build and Revision Numbers 33 | // by using the '*' as shown below: 34 | // [assembly: AssemblyVersion("1.0.*")] 35 | [assembly: AssemblyVersion("1.18.1.0")] 36 | [assembly: AssemblyFileVersion("1.18.1.0")] 37 | -------------------------------------------------------------------------------- /Src/StackifyLib.log4net.v1_2_10/packages.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | -------------------------------------------------------------------------------- /Src/StackifyLib.log4net/ExceptionAppender.cs: -------------------------------------------------------------------------------- 1 | using log4net.Core; 2 | using Apache_log4net = log4net; 3 | 4 | namespace StackifyLib.log4net 5 | { 6 | public class ExceptionAppender : StackifyAppender 7 | { 8 | protected override void Append(LoggingEvent loggingEvent) 9 | { 10 | if (Level.Error == loggingEvent.Level || Level.Fatal == loggingEvent.Level) 11 | { 12 | base.Append(loggingEvent); 13 | } 14 | } 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /Src/StackifyLib.log4net/Log4NetExtensions.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using StackifyLib.Models; 3 | using log4net; 4 | 5 | namespace StackifyLib 6 | { 7 | public static class Extensions 8 | { 9 | private static LogMessage GetMessage(string message, object debugData) 10 | { 11 | return new LogMessage() { message = message, json = debugData }; 12 | } 13 | 14 | public static void Debug(this ILog log, string message, object debugData) 15 | { 16 | log.Debug(GetMessage(message, debugData)); 17 | } 18 | 19 | public static void Info(this ILog log, string message, object debugData) 20 | { 21 | log.Info(GetMessage(message, debugData)); 22 | } 23 | 24 | public static void Warn(this ILog log, string message, object debugData) 25 | { 26 | log.Warn(GetMessage(message, debugData)); 27 | } 28 | 29 | public static void Warn(this ILog log, string message, object debugData, Exception exception) 30 | { 31 | log.Warn(GetMessage(message, debugData), exception); 32 | } 33 | 34 | public static void Error(this ILog log, string message, object debugData) 35 | { 36 | log.Error(GetMessage(message, debugData)); 37 | } 38 | 39 | public static void Error(this ILog log, string message, object debugData, Exception exception) 40 | { 41 | log.Error(GetMessage(message, debugData), exception); 42 | } 43 | 44 | public static void Fatal(this ILog log, string message, object debugData) 45 | { 46 | log.Fatal(GetMessage(message, debugData)); 47 | } 48 | 49 | public static void Fatal(this ILog log, string message, object debugData, Exception exception) 50 | { 51 | log.Fatal(GetMessage(message, debugData), exception); 52 | } 53 | } 54 | } 55 | -------------------------------------------------------------------------------- /Src/StackifyLib.log4net/Properties/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | using System.Reflection; 2 | using System.Runtime.CompilerServices; 3 | using System.Runtime.InteropServices; 4 | 5 | // General Information about an assembly is controlled through the following 6 | // set of attributes. Change these attribute values to modify the information 7 | // associated with an assembly. 8 | [assembly: AssemblyTitle("StackifyLib.log4net")] 9 | [assembly: AssemblyDescription("StackifyLib.log4net")] 10 | [assembly: AssemblyConfiguration("")] 11 | [assembly: AssemblyCompany("Stackify")] 12 | [assembly: AssemblyProduct("StackifyLib.log4net")] 13 | [assembly: AssemblyCopyright("Copyright © 2015")] 14 | [assembly: AssemblyTrademark("")] 15 | [assembly: AssemblyCulture("")] 16 | //[assembly: AssemblyKeyFile("..\\StackifyLib\\Netreo.snk")] 17 | 18 | // Setting ComVisible to false makes the types in this assembly not visible 19 | // to COM components. If you need to access a type in this assembly from 20 | // COM, set the ComVisible attribute to true on that type. 21 | [assembly: ComVisible(false)] 22 | 23 | // The following GUID is for the ID of the typelib if this project is exposed to COM 24 | [assembly: Guid("2963dd01-d67d-4666-b21a-f0d627629535")] 25 | 26 | // Version information for an assembly consists of the following four values: 27 | // 28 | // Major Version 29 | // Minor Version 30 | // Build Number 31 | // Revision 32 | // 33 | // You can specify all the values or you can default the Build and Revision Numbers 34 | // by using the '*' as shown below: 35 | // [assembly: AssemblyVersion("1.0.*")] 36 | //[assembly: AssemblyVersion("1.18.*")] 37 | //[assembly: AssemblyFileVersion("1.18.*")] 38 | -------------------------------------------------------------------------------- /Src/StackifyLib.log4net/StackifyLib.log4net.csproj: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | Stackify Log4Net Appender 5 | 2.1.7 6 | 7 | netstandard2.0;net40;net45 8 | StackifyLib.log4net 9 | StackifyLib.log4net 10 | stackify;metrics;errors;logs 11 | false 12 | false 13 | false 14 | false 15 | false 16 | false 17 | 2.1.7 18 | https://github.com/stackify/stackify-api-dotnet/blob/master/LICENSE 19 | https://github.com/stackify/stackify-api-dotnet 20 | https://github.com/stackify/stackify-api-dotnet 21 | git 22 | https://stackify.com/wp-content/uploads/2017/02/stk.png 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | NETCORE 33 | 34 | 35 | 36 | NETFULL 37 | 38 | 39 | 40 | -------------------------------------------------------------------------------- /Src/StackifyLib.log4net/packages.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | -------------------------------------------------------------------------------- /Src/StackifyLib/Extensions.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using StackifyLib.Utils; 3 | 4 | namespace StackifyLib 5 | { 6 | public static class Extensions 7 | { 8 | public static void SendToStackify(this Exception ex) 9 | { 10 | try 11 | { 12 | StackifyLib.StackifyError.New(ex).SendToStackify(); 13 | } 14 | catch (Exception e) 15 | { 16 | StackifyAPILogger.Log("#Extensions #SendToStackify failed", e); 17 | throw; 18 | } 19 | } 20 | 21 | public static StackifyLib.StackifyError NewStackifyError(this Exception ex) 22 | { 23 | try 24 | { 25 | return StackifyLib.StackifyError.New(ex); 26 | } 27 | catch (Exception e) 28 | { 29 | StackifyAPILogger.Log("#Extensions #NewStackifyError failed", e); 30 | throw; 31 | } 32 | } 33 | 34 | #if NETCORE || NETCOREX 35 | public static void ConfigureStackifyLogging(this Microsoft.Extensions.Configuration.IConfiguration configuration) 36 | { 37 | StackifyAPILogger.Log("#Extensions - ConfigureStackifyLogging - Initialize"); 38 | Config.SetConfiguration(configuration); 39 | //tell it to load all the settings since we now have the config 40 | Config.LoadSettings(); 41 | StackifyAPILogger.Log("#Extensions - ConfigureStackifyLogging - Settings Loaded"); 42 | } 43 | 44 | public static void ConfigureStackifyLib(this Microsoft.Extensions.Configuration.IConfiguration configuration) 45 | { 46 | StackifyAPILogger.Log("#Extensions - ConfigureStackifyLib - Initialize"); 47 | Config.SetConfiguration(configuration); 48 | //tell it to load all the settings since we now have the config 49 | Config.LoadSettings(); 50 | StackifyAPILogger.Log("#Extensions - ConfigureStackifyLib - Settings Loaded"); 51 | } 52 | #endif 53 | } 54 | } -------------------------------------------------------------------------------- /Src/StackifyLib/Internal/Logs/ILogClient.cs: -------------------------------------------------------------------------------- 1 | using StackifyLib.Models; 2 | using StackifyLib.Utils; 3 | 4 | namespace StackifyLib.Internal.Logs 5 | { 6 | public interface ILogClient 7 | { 8 | bool CanQueue(); 9 | bool CanSend(); 10 | bool CanUpload(); 11 | void Close(); 12 | bool ErrorShouldBeSent(StackifyError error); 13 | AppIdentityInfo GetIdentity(); 14 | bool IsAuthorized(); 15 | void PauseUpload(bool isPaused); 16 | void QueueMessage(LogMsg msg); 17 | } 18 | } -------------------------------------------------------------------------------- /Src/StackifyLib/Models/LogMessage.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | using Newtonsoft.Json; 6 | 7 | namespace StackifyLib.Models 8 | { 9 | 10 | /// 11 | /// Helper class for logging a message and object both 12 | /// 13 | 14 | public class LogMessage 15 | { 16 | public object json { get; set; } 17 | public string message { get; set; } 18 | 19 | public override string ToString() 20 | { 21 | if (json != null) 22 | { 23 | return message + " " + JsonConvert.SerializeObject(json, new JsonSerializerSettings{ReferenceLoopHandling = ReferenceLoopHandling.Serialize}); 24 | } 25 | else 26 | { 27 | return message; 28 | } 29 | } 30 | } 31 | } 32 | -------------------------------------------------------------------------------- /Src/StackifyLib/Models/MonitorModels.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | 6 | namespace StackifyLib.Models 7 | { 8 | public class Device 9 | { 10 | public int Id { get; set; } 11 | public string Name { get; set; } 12 | public string Alias { get; set; } 13 | public string Env { get; set; } 14 | public int? EnvId { get; set; } 15 | public string Loc { get; set; } 16 | public int? LocId { get; set; } 17 | public string Alerts { get; set; } 18 | } 19 | 20 | public class Monitor 21 | { 22 | public int Id { get; set; } 23 | public short? MonitorTypeId { get; set; } 24 | public bool? IsHeading { get; set; } 25 | public string Desc { get; set; } 26 | public int? SortOrder { get; set; } 27 | public DateTime? LastCheck { get; set; } 28 | public string Status { get; set; } 29 | public string SparkLine { get; set; } 30 | public int? CurrentSevId { get; set; } 31 | public int? AlertingSevId { get; set; } 32 | public int? MonitorRelationId { get; set; } 33 | } 34 | 35 | public class MonitorMetric 36 | { 37 | public List Metrics { get; set; } 38 | public float? Min { get; set; } 39 | public float? Max { get; set; } 40 | public float? Avg { get; set; } 41 | public string MonitorDesc { get; set; } 42 | public string Units { get; set; } 43 | public int? MonitorTypeId { get; set; } 44 | 45 | public class Metric 46 | { 47 | public DateTime Dt { get; set; } 48 | public double? Val { get; set; } 49 | } 50 | } 51 | } 52 | -------------------------------------------------------------------------------- /Src/StackifyLib/Models/TraceFrame.cs: -------------------------------------------------------------------------------- 1 |  2 | using System.Runtime.Serialization; 3 | using Newtonsoft.Json; 4 | 5 | namespace StackifyLib.Models 6 | { 7 | public class TraceFrame 8 | { 9 | [JsonProperty] 10 | public int? LineNum { get; set; } 11 | [JsonProperty] 12 | public string Method { get; set; } 13 | [JsonProperty] 14 | public string CodeFileName { get; set; } 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /Src/StackifyLib/Properties/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | using System.Reflection; 2 | using System.Runtime.CompilerServices; 3 | using System.Runtime.InteropServices; 4 | 5 | // General Information about an assembly is controlled through the following 6 | // set of attributes. Change these attribute values to modify the information 7 | // associated with an assembly. 8 | [assembly: AssemblyTitle("StackifyLib")] 9 | [assembly: AssemblyDescription("Library for Stackify users to integrate Stackify in to their projects. Provides support for sending errors, logs, and custom metrics to Stackify. Also some support for querying metric data back out of Stackify for use in external projects.")] 10 | [assembly: AssemblyConfiguration("")] 11 | [assembly: AssemblyCompany("Stackify")] 12 | [assembly: AssemblyProduct("Stackify API for .NET")] 13 | [assembly: AssemblyCopyright("Copyright © 2018-2020")] 14 | [assembly: AssemblyTrademark("")] 15 | [assembly: AssemblyCulture("")] 16 | //[assembly: AssemblyKeyFile("Netreo.snk")] 17 | 18 | // Setting ComVisible to false makes the types in this assembly not visible 19 | // to COM components. If you need to access a type in this assembly from 20 | // COM, set the ComVisible attribute to true on that type. 21 | [assembly: ComVisible(false)] 22 | 23 | #if NETFULL 24 | // The following GUID is for the ID of the typelib if this project is exposed to COM 25 | [assembly: Guid("67aae97f-aa9f-4c35-b611-b68af22b9712")] 26 | #endif 27 | 28 | // Version information for an assembly consists of the following four values: 29 | // 30 | // Major Version 31 | // Minor Version 32 | // Build Number 33 | // Revision 34 | // 35 | // You can specify all the values or you can default the Build and Revision Numbers 36 | // by using the '*' as shown below: 37 | // [assembly: AssemblyVersion("1.0.*")] 38 | //[assembly: AssemblyVersion("1.24.*")] 39 | //[assembly: AssemblyFileVersion("1.24.*")] 40 | -------------------------------------------------------------------------------- /Src/StackifyLib/StringException.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections; 3 | using System.Collections.Generic; 4 | using System.Diagnostics; 5 | using System.Linq; 6 | using System.Reflection; 7 | using System.Text; 8 | using System.Threading.Tasks; 9 | using StackifyLib.Models; 10 | 11 | namespace StackifyLib 12 | { 13 | /// 14 | /// Used when someone logs an error but only logs a string with no exception 15 | /// 16 | public class StringException : Exception 17 | { 18 | public StringException(string message) 19 | : base(message) 20 | { 21 | 22 | } 23 | 24 | //Used to hold the stack trace for the exception and we have to manually figure it out 25 | public List TraceFrames { get; set; } 26 | } 27 | } 28 | 29 | /* 30 | * Example usage from log4net appender 31 | * 32 | StringException stringEx = new StringException(loggingEvent.RenderedMessage); 33 | stringEx.TraceFrames = new List(); 34 | 35 | 36 | stringEx.TraceFrames = StackifyLib.Logger.GetCurrentStackTrace(loggingEvent.LoggerName); 37 | 38 | if (stringEx.TraceFrames.Any()) 39 | { 40 | var first = stringEx.TraceFrames.First(); 41 | 42 | msg.SrcMethod = first.Method; 43 | msg.SrcLine = first.LineNum; 44 | } 45 | 46 | //Make error out of log message 47 | error = StackifyError.New(stringEx); 48 | 49 | 50 | */ 51 | -------------------------------------------------------------------------------- /Src/StackifyLib/Utils/DateExtensions.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Text; 5 | 6 | namespace StackifyLib.Utils 7 | { 8 | internal static class DateExtensions 9 | { 10 | public static DateTime Round(this DateTime date, TimeSpan span) 11 | { 12 | long ticks = (date.Ticks + (span.Ticks / 2) + 1) / span.Ticks; 13 | return new DateTime(ticks * span.Ticks, date.Kind); 14 | } 15 | public static DateTime Floor(this DateTime date, TimeSpan span) 16 | { 17 | long ticks = (date.Ticks / span.Ticks); 18 | return new DateTime(ticks * span.Ticks, date.Kind); 19 | } 20 | public static DateTime Ceil(this DateTime date, TimeSpan span) 21 | { 22 | long ticks = (date.Ticks + span.Ticks - 1) / span.Ticks; 23 | return new DateTime(ticks * span.Ticks, date.Kind); 24 | } 25 | 26 | /// 27 | /// Calculates the Unix epoch for the date 28 | /// 29 | /// The Unix epoch 30 | public static long ToUnixEpoch(this DateTime date) 31 | { 32 | return (date.Ticks - 621355968000000000) / 10000000; 33 | } 34 | 35 | /// 36 | /// Calculates the Unix epoch minutes for the date 37 | /// 38 | /// The Unix epoch minutes 39 | public static long ToUnixEpochMinutes(this DateTime date) 40 | { 41 | return date.ToUnixEpoch() / 60; 42 | } 43 | } 44 | } 45 | -------------------------------------------------------------------------------- /Src/StackifyLib/Utils/EtwEventListener.cs: -------------------------------------------------------------------------------- 1 | #if NETFULL 2 | #if !NET40 3 | using System; 4 | using System.Collections.Generic; 5 | using System.Diagnostics; 6 | using System.Diagnostics.Tracing; 7 | using System.Linq; 8 | using System.Text; 9 | using System.Threading.Tasks; 10 | 11 | namespace StackifyLib.Utils 12 | { 13 | public class EtwEventListener : EventListener 14 | { 15 | private static readonly Guid tplGuid = new Guid("2e5dba47-a3d2-4d16-8ee0-6671ffdcd7b5"); 16 | // private static readonly Guid aspnetGuid = new Guid("aff081fe-0247-4275-9c4e-021f3dc1da35"); 17 | 18 | protected override void OnEventSourceCreated(EventSource eventSource) 19 | { 20 | if (eventSource.Guid == tplGuid) 21 | { 22 | EnableEvents(eventSource, EventLevel.Informational); 23 | } 24 | } 25 | 26 | protected override void OnEventWritten(EventWrittenEventArgs eventData) 27 | { 28 | 29 | } 30 | } 31 | } 32 | #endif 33 | #endif -------------------------------------------------------------------------------- /Src/StackifyLib/Utils/HighPrecisionTime.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Runtime.InteropServices; 5 | using System.Threading.Tasks; 6 | 7 | namespace StackifyLib.Utils 8 | { 9 | public static class HighPrecisionTime 10 | { 11 | public static bool IsAvailable { get; private set; } 12 | 13 | [DllImport("Kernel32.dll", CallingConvention = CallingConvention.Winapi)] 14 | private static extern void GetSystemTimePreciseAsFileTime(out long filetime); 15 | 16 | public static DateTime UtcNow 17 | { 18 | get 19 | { 20 | if (!IsAvailable) 21 | { 22 | return DateTime.UtcNow; 23 | // throw new InvalidOperationException("High resolution clock isn't available."); 24 | } 25 | long filetime; 26 | GetSystemTimePreciseAsFileTime(out filetime); 27 | return DateTime.FromFileTimeUtc(filetime); 28 | } 29 | } 30 | 31 | static HighPrecisionTime() 32 | { 33 | try 34 | { 35 | long filetime; 36 | GetSystemTimePreciseAsFileTime(out filetime); 37 | IsAvailable = true; 38 | } 39 | catch 40 | { 41 | IsAvailable = false; 42 | } 43 | } 44 | } 45 | } 46 | -------------------------------------------------------------------------------- /Src/StackifyLib/Utils/RegistryHelper.cs: -------------------------------------------------------------------------------- 1 | #if NETFULL 2 | using System; 3 | using System.Collections.Generic; 4 | using System.Linq; 5 | using System.Text; 6 | using Microsoft.Win32; 7 | 8 | namespace StackifyLib.Utils 9 | { 10 | public static class RegistryHelper 11 | { 12 | public static RegistryKey GetRegistryKey(string keyPath, bool writeable = false) 13 | { 14 | RegistryKey localMachineRegistry 15 | = RegistryKey.OpenBaseKey(RegistryHive.LocalMachine, 16 | Environment.Is64BitOperatingSystem 17 | ? RegistryView.Registry64 18 | : RegistryView.Registry32); 19 | 20 | return string.IsNullOrEmpty(keyPath) 21 | ? localMachineRegistry 22 | : localMachineRegistry.OpenSubKey(keyPath, writeable); 23 | } 24 | 25 | public static object GetRegistryValue(string keyPath, string keyName) 26 | { 27 | RegistryKey registry = GetRegistryKey(keyPath); 28 | return registry.GetValue(keyName); 29 | } 30 | } 31 | } 32 | #endif -------------------------------------------------------------------------------- /Src/StackifyLib/Utils/SequentialGuid.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Runtime.InteropServices; 5 | using System.Text; 6 | 7 | namespace StackifyLib.Utils 8 | { 9 | public static class SequentialGuid 10 | { 11 | #if NETFULL 12 | [DllImport("rpcrt4.dll", SetLastError = true)] 13 | private static extern int UuidCreateSequential(out Guid guid); 14 | #endif 15 | public static Guid NewGuid() 16 | { 17 | #if NETFULL 18 | const int RPC_S_OK = 0; 19 | Guid guid; 20 | int result = UuidCreateSequential(out guid); 21 | if (result == RPC_S_OK) 22 | { 23 | return guid; 24 | } 25 | #endif 26 | return Guid.NewGuid(); 27 | } 28 | } 29 | } 30 | -------------------------------------------------------------------------------- /Src/StackifyLib/Utils/ServerConfigHelper.cs: -------------------------------------------------------------------------------- 1 | using StackifyLib.Models; 2 | using System; 3 | using System.Collections.Generic; 4 | using System.Text; 5 | 6 | namespace StackifyLib.Utils 7 | { 8 | public class ServerConfigHelper 9 | { 10 | public const string ProductionEnvName = "Production"; 11 | 12 | public static string GetEnvironment() 13 | { 14 | if (AzureConfig.IsWebsite) 15 | { 16 | var key = Environment.GetEnvironmentVariable("Stackify.Environment"); 17 | 18 | if (string.IsNullOrEmpty(key) == false) 19 | { 20 | return key; 21 | } 22 | 23 | if (string.IsNullOrEmpty(AzureConfig.AzureAppWebConfigEnvironment) == false) 24 | { 25 | return AzureConfig.AzureAppWebConfigEnvironment; 26 | } 27 | 28 | return ProductionEnvName; 29 | } 30 | 31 | return string.Empty; 32 | } 33 | } 34 | } 35 | -------------------------------------------------------------------------------- /Src/StackifyLib/Web/ErrorLoggerHttpModule.cs: -------------------------------------------------------------------------------- 1 | #if NETFULL 2 | using System; 3 | using System.Collections.Generic; 4 | using System.Linq; 5 | using System.Text; 6 | using System.Web; 7 | 8 | namespace StackifyLib.Web 9 | { 10 | public class ErrorLoggerHttpModule : IHttpModule 11 | { 12 | void IHttpModule.Init(HttpApplication context) 13 | { 14 | if (context == null) 15 | throw new ArgumentNullException("context"); 16 | 17 | context.Error += context_Error; 18 | } 19 | 20 | void context_Error(object sender, EventArgs e) 21 | { 22 | try 23 | { 24 | var application = (HttpApplication)sender; 25 | Logger.QueueException("Unhandled Web Exception", application.Server.GetLastError()); 26 | } 27 | catch (Exception) 28 | { 29 | 30 | } 31 | } 32 | 33 | void IHttpModule.Dispose() 34 | { 35 | 36 | } 37 | } 38 | } 39 | #endif -------------------------------------------------------------------------------- /Src/packages/repositories.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /appveyor.yml: -------------------------------------------------------------------------------- 1 | version: '{build}' 2 | os: Visual Studio 2017 3 | 4 | pull_requests: 5 | do_not_increment_build_number: true 6 | 7 | branches: 8 | only: 9 | - develop 10 | 11 | nuget: 12 | disable_publish_on_pr: true 13 | 14 | init: 15 | - SET PATH=C:\Program Files\PostgreSQL\9.6\bin\;%PATH% 16 | 17 | build_script: 18 | - ps: .\Build.ps1 19 | 20 | test: off 21 | 22 | artifacts: 23 | - path: .\**\artifacts\**\*.nupkg 24 | name: NuGet 25 | 26 | deploy: 27 | - provider: NuGet 28 | server: https://www.myget.org/F/stackify-private/api/v2 29 | api_key: 30 | secure: Txfu3efySdQMNgs/NF4N3dXvnMckOkQXNRL0ILka6BwQc3mUX4Isn8/r17N1J7l6 31 | skip_symbols: true 32 | on: 33 | branch: develop -------------------------------------------------------------------------------- /build.ps1: -------------------------------------------------------------------------------- 1 | $revision = @{ $true = $env:APPVEYOR_BUILD_NUMBER; $false = 1 }[$env:APPVEYOR_BUILD_NUMBER -ne $NULL]; 2 | $revision = "{0:D4}" -f [convert]::ToInt32($revision, 10) 3 | 4 | dotnet restore .\Src 5 | 6 | dotnet build .\Src\StackifyLib -c Release 7 | dotnet build .\Src\StackifyLib.AspNetCore -c Release 8 | dotnet build .\Src\StackifyLib.CoreLogger -c Release 9 | #dotnet build .\Src\StackifyLib.ELMAH -c Release 10 | dotnet build .\Src\StackifyLib.log4net -c Release 11 | #dotnet build .\Src\StackifyLib.log4net.Sitecore -c Release 12 | #dotnet build .\Src\StackifyLib.log4net.Tests -c Release 13 | #dotnet build .\Src\StackifyLib.log4net.v1_2_10 -c Release 14 | #dotnet build .\Src\StackifyLib.nlog -c Release 15 | #dotnet build .\Src\StackifyLib.NoWeb -c Release 16 | dotnet build .\Src\StackifyLib.StackifyTraceListener -c Release 17 | 18 | Write-Output "APPVEYOR_REPO_TAG: $env:APPVEYOR_REPO_TAG" 19 | Write-Output "VERSION-SUFFIX: alpha1-$revision" 20 | 21 | If($env:APPVEYOR_REPO_TAG -eq $true) { 22 | Write-Output "RUNNING dotnet pack .\Src\StackifyLib -c Release -o .\artifacts " 23 | dotnet pack .\Src\StackifyLib -c Release -o .\artifacts 24 | } 25 | Else { 26 | Write-Output "RUNNING dotnet pack .\Src\StackifyLib -c Release -o .\artifacts --version-suffix=alpha1-$revision" 27 | dotnet pack .\Src\StackifyLib -c Release -o .\artifacts --version-suffix=beta1-$revision 28 | } -------------------------------------------------------------------------------- /log4netinstalled.md: -------------------------------------------------------------------------------- 1 | ## StackifyLib.log4net installed 2 | 3 | Thanks for installing Stackify in to your application. Here are some things to know about using log4net with Stackify 4 | 5 | - You can send all logs including DEBUG level statements or just your ERROR/FATAL messages via the log4net config. 6 | - Messages are queued and sent asynchronously within our library. 7 | 8 | 9 | ## Sample config for log4net 10 | -------------------------------------------------------------------------------- /samples/CoreConsoleApp/NLog.config: -------------------------------------------------------------------------------- 1 |  2 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | -------------------------------------------------------------------------------- /samples/CoreConsoleApp/Properties/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | using System.Reflection; 2 | using System.Runtime.CompilerServices; 3 | using System.Runtime.InteropServices; 4 | 5 | // General Information about an assembly is controlled through the following 6 | // set of attributes. Change these attribute values to modify the information 7 | // associated with an assembly. 8 | [assembly: AssemblyConfiguration("")] 9 | [assembly: AssemblyCompany("")] 10 | [assembly: AssemblyProduct("CoreConsoleApp")] 11 | [assembly: AssemblyTrademark("")] 12 | 13 | // Setting ComVisible to false makes the types in this assembly not visible 14 | // to COM components. If you need to access a type in this assembly from 15 | // COM, set the ComVisible attribute to true on that type. 16 | [assembly: ComVisible(false)] 17 | 18 | // The following GUID is for the ID of the typelib if this project is exposed to COM 19 | [assembly: Guid("2b832b34-ba30-4b5a-8e78-d6dc78af16fb")] 20 | -------------------------------------------------------------------------------- /samples/CoreConsoleApp/Properties/launchSettings.json: -------------------------------------------------------------------------------- 1 | { 2 | "profiles": { 3 | "CoreConsoleApp": { 4 | "commandName": "Project", 5 | "environmentVariables": { 6 | "COR_ENABLE_PROFILING": "1", 7 | "CORECLR_ENABLE_PROFILING": "1" 8 | } 9 | } 10 | } 11 | } -------------------------------------------------------------------------------- /samples/CoreConsoleApp/Stackify-empty.json: -------------------------------------------------------------------------------- 1 | { 2 | } 3 | -------------------------------------------------------------------------------- /samples/CoreConsoleApp/Stackify.Production.json: -------------------------------------------------------------------------------- 1 | { 2 | "AppName": "CoreConsoleApp_stackifyjson_Prod", 3 | "Environment": "Prod_stackifyjson", 4 | "ApiKey": "sampleKey_stackifyjson_Prod" 5 | } 6 | -------------------------------------------------------------------------------- /samples/CoreConsoleApp/Stackify.json: -------------------------------------------------------------------------------- 1 | { 2 | "AppName": "CoreConsoleApp_stackifyjson", 3 | "Environment": "Dev_stackifyjson", 4 | "ApiKey": "sampleKey_stackifyjson", 5 | "EnableDebugging": true, 6 | "Instrumentation": [ 7 | { 8 | "Assembly": "CoreConsoleApp", 9 | "Class": "CoreConsoleApp.Program", 10 | "Method": "TestInstrument", 11 | "StartTrace": true 12 | }, 13 | { 14 | "Assembly": "CoreConsoleApp", 15 | "Class": "CoreConsoleApp.Program", 16 | "Method": "TestInstrumentNested", 17 | "StartTrace": true 18 | } 19 | ] 20 | } 21 | -------------------------------------------------------------------------------- /samples/CoreConsoleApp/appsettings.json: -------------------------------------------------------------------------------- 1 | { 2 | "Stackify": { 3 | "ApiKey": "", 4 | "AppName": "CoreConsoleApp", 5 | "Environment": "Dev" 6 | } 7 | } -------------------------------------------------------------------------------- /samples/CoreConsoleApp/log4net.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | -------------------------------------------------------------------------------- /samples/CoreWebApp/ApplicationLogging.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Threading.Tasks; 5 | using Microsoft.Extensions.Logging; 6 | using StackifyLib.CoreLogger; 7 | 8 | namespace CoreWebApp 9 | { 10 | public class ApplicationLogging 11 | { 12 | private static ILoggerFactory _Factory = null; 13 | 14 | public static void ConfigureLogger(ILoggerFactory factory) 15 | { 16 | factory.AddDebug(LogLevel.None).AddStackify(); 17 | factory.AddFile("logFileFromHelper.log"); //serilog file extension 18 | } 19 | 20 | public static ILoggerFactory LoggerFactory 21 | { 22 | get 23 | { 24 | if (_Factory == null) 25 | { 26 | _Factory = new LoggerFactory(); 27 | ConfigureLogger(_Factory); 28 | } 29 | return _Factory; 30 | } 31 | set { _Factory = value; } 32 | } 33 | public static ILogger CreateLogger() => LoggerFactory.CreateLogger(); 34 | } 35 | } 36 | -------------------------------------------------------------------------------- /samples/CoreWebApp/Controllers/SomeOtherClass.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Net.Http; 5 | using System.Threading.Tasks; 6 | using Microsoft.Extensions.Logging; 7 | 8 | namespace CoreWebApp.Controllers 9 | { 10 | public class SomeOtherClass 11 | { 12 | public SomeOtherClass() 13 | { 14 | } 15 | 16 | public async Task DoBadWebRequest() 17 | { 18 | try 19 | { 20 | using (HttpClient hc = new HttpClient()) 21 | { 22 | var data = await hc.GetStringAsync("https://stackify.comm"); 23 | return data; 24 | } 25 | } 26 | catch (Exception ex) 27 | { 28 | var logger = ApplicationLogging.CreateLogger(); 29 | logger.LogError("Error! " + ex.ToString()); 30 | } 31 | 32 | return null; 33 | } 34 | } 35 | } 36 | -------------------------------------------------------------------------------- /samples/CoreWebApp/Models/ValueModel.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Threading.Tasks; 5 | 6 | namespace CoreWebApp.Models 7 | { 8 | public class ValueModel 9 | { 10 | public string Value { get; set; } 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /samples/CoreWebApp/NLog.config: -------------------------------------------------------------------------------- 1 |  2 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | -------------------------------------------------------------------------------- /samples/CoreWebApp/Program.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.IO; 4 | using System.Linq; 5 | using System.Threading.Tasks; 6 | using Microsoft.AspNetCore.Hosting; 7 | using Microsoft.AspNetCore.Builder; 8 | 9 | namespace CoreWebApp 10 | { 11 | public class Program 12 | { 13 | public static void Main(string[] args) 14 | { 15 | var host = new WebHostBuilder() 16 | .UseKestrel() 17 | .UseContentRoot(Directory.GetCurrentDirectory()) 18 | .UseIISIntegration() 19 | .UseStartup() 20 | .Build(); 21 | 22 | host.Run(); 23 | } 24 | } 25 | } 26 | -------------------------------------------------------------------------------- /samples/CoreWebApp/Properties/launchSettings.json: -------------------------------------------------------------------------------- 1 | { 2 | "iisSettings": { 3 | "windowsAuthentication": false, 4 | "anonymousAuthentication": true, 5 | "iisExpress": { 6 | "applicationUrl": "http://localhost:15950/", 7 | "sslPort": 0 8 | } 9 | }, 10 | "profiles": { 11 | "IIS Express": { 12 | "commandName": "IISExpress", 13 | "launchBrowser": true, 14 | "launchUrl": "api/values", 15 | "environmentVariables": { 16 | "DOTNET_ENVIRONMENT": "Production" 17 | } 18 | }, 19 | "CoreWebApp": { 20 | "commandName": "Project", 21 | "launchBrowser": true, 22 | "launchUrl": "http://localhost:5000/api/values", 23 | "environmentVariables": { 24 | "DOTNET_ENVIRONMENT": "Production" 25 | } 26 | } 27 | } 28 | } -------------------------------------------------------------------------------- /samples/CoreWebApp/Stackify.Development.json: -------------------------------------------------------------------------------- 1 | { 2 | "AppName": "CoreWebApp_stackifyjson_dev", 3 | "Environment": "Development", 4 | "ApiKey": "" 5 | } -------------------------------------------------------------------------------- /samples/CoreWebApp/Stackify.Production.json: -------------------------------------------------------------------------------- 1 | { 2 | "AppName": "CoreWebApp_stackifyjson_prod", 3 | "Environment": "Production", 4 | "ApiKey": "" 5 | } -------------------------------------------------------------------------------- /samples/CoreWebApp/Stackify.json: -------------------------------------------------------------------------------- 1 | { 2 | "AppName": "CoreWebApp_stackifyjson", 3 | "Environment": "Dev_stackifyjson", 4 | "ApiKey": "" 5 | } -------------------------------------------------------------------------------- /samples/CoreWebApp/appsettings.json: -------------------------------------------------------------------------------- 1 | { 2 | "Logging": { 3 | "IncludeScopes": false, 4 | "LogLevel": { 5 | "Default": "None", 6 | "System": "None", 7 | "Microsoft": "None", 8 | "Microsoft.AspNetCore.Mvc.Internal": "None" 9 | } 10 | }, 11 | "Stackify": { 12 | "AppName": "CoreWebApp", 13 | "Environment": "Dev" 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /samples/CoreWebApp/web.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | -------------------------------------------------------------------------------- /templates/build-and-pack.yml: -------------------------------------------------------------------------------- 1 | # BuildAndPack.yml 2 | 3 | parameters: 4 | - name: ProjectLocation 5 | type: string 6 | - name: ProjectName 7 | type: string 8 | - name: ProjectJobName 9 | type: string 10 | - name: BuildConfiguration 11 | type: string 12 | 13 | steps: 14 | - task: DotNetCoreCLI@2 15 | displayName: dotnet build ${{parameters.ProjectName}} [Unsigned] 16 | inputs: 17 | projects: | 18 | ${{ parameters.ProjectLocation }} 19 | arguments: '-c ${{ parameters.BuildConfiguration }}' 20 | - task: DotNetCoreCLI@2 21 | displayName: dotnet pack copy ${{parameters.ProjectName}} [Unsigned] 22 | inputs: 23 | command: pack 24 | searchPatternPack: ${{ parameters.ProjectLocation }} 25 | nobuild: true -------------------------------------------------------------------------------- /test/StackifyLib.UnitTests/Fixtures/JsonConfig/Stackify-Empty.json: -------------------------------------------------------------------------------- 1 | { 2 | 3 | } 4 | -------------------------------------------------------------------------------- /test/StackifyLib.UnitTests/Fixtures/JsonConfig/Stackify-Invalid-Format.json: -------------------------------------------------------------------------------- 1 | Invalid -------------------------------------------------------------------------------- /test/StackifyLib.UnitTests/Fixtures/JsonConfig/Stackify-Invalid-Property-Type.json: -------------------------------------------------------------------------------- 1 | { 2 | "AppName": true, 3 | "Environment": { 4 | "Test": "Test" 5 | }, 6 | "ApiKey": [ 7 | "Test" 8 | ] 9 | } 10 | -------------------------------------------------------------------------------- /test/StackifyLib.UnitTests/Fixtures/JsonConfig/Stackify-With-Comment.json: -------------------------------------------------------------------------------- 1 | { 2 | "AppName": "CoreConsoleApp", 3 | "Environment": "Dev", 4 | "ApiKey": "sampleKey" 5 | // "AppName": "CoreConsoleApp2", 6 | } 7 | -------------------------------------------------------------------------------- /test/StackifyLib.UnitTests/Fixtures/JsonConfig/Stackify.json: -------------------------------------------------------------------------------- 1 | { 2 | "AppName": "CoreConsoleApp", 3 | "Environment": "Dev", 4 | "ApiKey": "sampleKey" 5 | } 6 | -------------------------------------------------------------------------------- /test/StackifyLib.UnitTests/Models/EnvironmentDetail_Tests.cs: -------------------------------------------------------------------------------- 1 | // Copyright (c) 2024 BMC Software, Inc. 2 | // Copyright (c) 2021-2024 Netreo 3 | // Copyright (c) 2019 Stackify 4 | using StackifyLib.Models; 5 | using System; 6 | using System.Collections.Generic; 7 | using System.IO; 8 | using System.Reflection; 9 | using System.Text; 10 | using System.Threading.Tasks; 11 | using Xunit; 12 | using Moq; 13 | 14 | namespace StackifyLib.UnitTests.Models 15 | { 16 | public class EnvironmentDetail_Tests 17 | { 18 | #if NETCORE 19 | [Fact] 20 | public async Task TestIfConfigEc2IsNull() 21 | { 22 | var envService = new EnvironmentDetail(); 23 | Assert.Equal(Environment.MachineName, envService.GetDeviceName()); 24 | 25 | var type = envService.GetType(); 26 | var property = type.GetField("ec2InstanceId", BindingFlags.NonPublic | BindingFlags.Instance); 27 | Assert.Equal(property.GetValue(envService) as string, string.Empty); 28 | } 29 | #endif 30 | #if NETFULL 31 | [Fact] 32 | public void TestIfConfigEc2IsNull() 33 | { 34 | var envService = new EnvironmentDetail(); 35 | Assert.Equal(Environment.MachineName, envService.GetDeviceName()); 36 | 37 | var type = envService.GetType(); 38 | var property = type.GetField("ec2InstanceId", BindingFlags.NonPublic | BindingFlags.Instance); 39 | Assert.Equal(property.GetValue(envService) as string, string.Empty); 40 | } 41 | #endif 42 | } 43 | } 44 | -------------------------------------------------------------------------------- /test/StackifyLib.UnitTests/StackifyLib.UnitTests.csproj: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | net6.0;net462 5 | false 6 | true 7 | 8 | 9 | NETCORE 10 | 11 | 12 | 13 | NETFULL 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | PreserveNewest 32 | 33 | 34 | PreserveNewest 35 | 36 | 37 | PreserveNewest 38 | 39 | 40 | PreserveNewest 41 | 42 | 43 | PreserveNewest 44 | 45 | 46 | 47 | 48 | --------------------------------------------------------------------------------