Microsoft Application Insights for .NET Web Applications
Перейти к файлу
Cijo Thomas 729a6c940b Merge branch 'cithomas/evencounter1_app' of https://github.com/Microsoft/ApplicationInsights-dotnet-server into cithomas/evencounter1_app 2019-06-28 16:25:19 -07:00
.github Contributing.md updated with feedback from various sources. 2018-02-02 11:37:21 -08:00
Keys Committing source code 2016-01-19 10:56:08 -08:00
SDL sdl script revision (#789) 2018-01-12 10:39:22 -08:00
Schema Remove references to FW 4.0 (#693) 2017-09-25 09:59:07 -07:00
Src Merge branch 'cithomas/evencounter1_app' of https://github.com/Microsoft/ApplicationInsights-dotnet-server into cithomas/evencounter1_app 2019-06-28 16:25:19 -07:00
Test Use InMemory channel in functional tests (#1204) 2019-05-23 12:55:51 -07:00
.gitattributes Committing source code 2016-01-19 10:56:08 -08:00
.gitignore Populate DependencyTelemetry with Operation Data for Initializers (#897) 2018-06-05 13:04:24 -07:00
AddXmlLanguage.targets convert HostingStartup to PackageReference (#1007) 2018-09-25 09:28:12 -07:00
ApplicationInsightsSDKRules.ruleset update analyzers and fix issues (#1194) 2019-05-21 15:11:16 -07:00
CHANGELOG.md Update changelog 2019-06-28 16:18:52 -07:00
CONTRIBUTING.md Minor adjustments to contributing 2018-02-14 15:35:37 -08:00
CodeCov.ps1 Removed netcore completely from code coverage 2017-06-14 13:09:29 -07:00
Common.props Enable PerfCollectors in netstandard 2.0 2019-02-01 09:23:17 -06:00
Common.targets Added common.targets to all projects and added injection of language into XML documentation files. 2016-09-07 15:08:58 -07:00
DevDivRuleSet.ruleset Sergkanz/to2017 (#410) 2017-04-05 23:16:38 -07:00
Directory.Build.props sdl test dirs (#1208) 2019-05-24 16:31:22 -07:00
DownloadSM.ps1 Changed sm script to take param 2016-06-22 13:06:13 -07:00
EnlistmentRoot.marker Committing source code 2016-01-19 10:56:08 -08:00
GenerateReleaseMetadata.ps1 release metadata (#884) 2018-04-11 15:47:37 -07:00
GlobalStaticVersion.props Upgrade base version to 2.10 stable (#1199) 2019-05-22 10:30:44 -07:00
LICENSE Sergkanz/to2017 (#410) 2017-04-05 23:16:38 -07:00
LibraryInstrumentationGuidance.md Library instrumentation guidance (#768) 2018-04-18 10:03:44 -07:00
Microsoft-Security-Recommended.ruleset Sergkanz/to2017 (#410) 2017-04-05 23:16:38 -07:00
NetCore.props bump version 2.7.1 (#963) 2018-08-01 16:00:32 -07:00
NuGet.config Handle 0-length content responses with HTTP desktop hook (#770) 2017-12-27 19:42:13 -08:00
NuGet.exe add script to audit nupkg during build (#1034) 2018-10-08 17:01:59 -07:00
NuGet.targets Sergkanz/to2017 (#410) 2017-04-05 23:16:38 -07:00
NugetAudit.ps1 Update license URL to license type 2019-01-28 16:42:58 -08:00
Nupkg.props Skip Nuget on Linux builds 2019-01-28 16:50:56 -08:00
Policheck_Template.xml Changes necessary to fix signed builds 2016-01-25 12:20:46 -08:00
README.md Minor fix on #49 2018-06-03 13:00:07 -03:00
Signing.props bump version 2.7.1 (#963) 2018-08-01 16:00:32 -07:00
Test.props bump version 2.7.1 (#963) 2018-08-01 16:00:32 -07:00
ThirdPartyNotices.txt Removing windows azure thir party notices 2016-09-09 15:25:12 -07:00
VSOPushNugetPackages.cmd Removed symbol publishing from nuget script 2016-01-27 12:52:04 -08:00
buildDebug.cmd Minor changes. 2018-01-11 16:36:14 -08:00
buildDebugFull.cmd Minor changes. 2018-01-11 16:36:14 -08:00
buildRelease.cmd Minor changes. 2018-01-11 16:36:14 -08:00
buildReleaseFull.cmd Minor changes. 2018-01-11 16:36:14 -08:00
clean.cmd Add .NETStandard DependencyCollector implementation (#366) 2017-04-07 19:09:05 -07:00
clearNugetCache.cmd Add .NETStandard DependencyCollector implementation (#366) 2017-04-07 19:09:05 -07:00
dirs.proj Update to latest build of base sdk. Use InitializeInstrumentationKey for initializeing ikey alone. 2018-10-31 18:12:31 -07:00
disablestrongnamevalidation.ps1 Comment added about why both are run. 2017-06-23 13:04:06 -07:00
dockercleanup.ps1 Minor 2018-05-16 11:02:33 -07:00
enablestrongnamevalidation.ps1 Comment added about why both are run. 2017-06-23 13:04:06 -07:00
findMsBuild.cmd Sergkanz/to2017 (#410) 2017-04-05 23:16:38 -07:00
killiisexpress.ps1 Cleanup script to stop iisexpresstray.exe as well as it was found to be locking files after failed tests. (#838) 2018-03-02 08:05:02 -08:00
restorePath.cmd Add .NETStandard DependencyCollector implementation (#366) 2017-04-07 19:09:05 -07:00
runAllFunctionalTests.cmd Report intermediate requests for lost and restored Activity (#898) 2018-05-03 16:26:14 -07:00
runFunctionalTestsDependencyCollector.cmd Report intermediate requests for lost and restored Activity (#898) 2018-05-03 16:26:14 -07:00
runFunctionalTestsPerfCollectorAndQuickPulse.cmd Enabled PerfCounterModule for NetCore apps. The perf counter will only collect counters if app is deployed to Azure Web Apps. 2018-04-23 14:30:13 -07:00
runFunctionalTestsWeb.cmd Added Info message when netstandard app use perf counter in non azure web app environment 2018-04-23 15:57:48 -07:00
runUnitTests.cmd Populate DependencyTelemetry with Operation Data for Initializers (#897) 2018-06-05 13:04:24 -07:00
savePath.cmd Add .NETStandard DependencyCollector implementation (#366) 2017-04-07 19:09:05 -07:00
upgradeVersion.ps1 Upgrade base version to 2.10 stable (#1199) 2019-05-22 10:30:44 -07:00

README.md

Build Status codecov.io

NuGet packages

Visual Studio Application Insights SDK for .NET Web Applications

The code in this repository is the .NET web application SDK for Application Insights. Application Insights is a service that lets you monitor your live application's performance and usage. This SDK sends telemetry to the service. It collects data such as web request timings and success rates, dependency calls, exceptions, and server performance counters. You can also use the SDK to send your own telemetry and add modules to collect logs. You can use this SDK in any .NET web application, hosted either on your own servers or on Microsoft Azure.

Get the SDK

The SDK is installed on each project by the Application Insights tools in Visual Studio (2013 and later).

To add Application Insights to your project in Visual Studio:

  • If you're creating a new project, check Add Application Insights in the New Project dialog.
  • If it's an existing project, right-click your project in Solution Explorer and select Add Application Insights or Update Application Insights.
  • If these options aren't available for your project type, use Extension Manager in Visual Studio to install or update the NuGet package. Create a new Application Insights resource in the Azure portal, obtain its instrumentation key, and insert that in ApplicationInsights.config.

Run your project, and then open your Application Insights resource in the Azure Preview Portal and look for events.

To upgrade to the latest SDK

  • After you upgrade, you'll need to merge back any customizations you made to ApplicationInsights.config. If you're unsure whether you customized it, create a new project, add Application Insights to it, and compare your .config file with the one in the new project. Make a note of any differences.
  • In Solution Explorer, right-click your project and choose Manage NuGet packages.
  • Set the filter to show Updates.
  • Select Microsoft.ApplicationInsights.Web and choose Update. (This will also upgrade all the dependent packages.)
  • Compare ApplicationInsights.config with the old copy. Most of the changes you'll see are because we removed some modules and made others parameterizable. Reinstate any customizations you made to the old file.
  • Rebuild your solution.

To build

Follow contributor's guide

Branches

  • master contains the latest published release located on NuGet.
  • develop contains the code for the next release.

Shared Projects

Our projects target multiple frameworks (ex: Net45 & NetCore). We have framework specific projects and a shared project for common files between them. (ex: Perf.Net45, Perf.NetCore, Perf.Shared). If a file is used by both frameworks, we prefer to store that file in a Shared project and use preprocessor directives to separate framework specific code (ex: #if NETCORE, #if !NETCORE). We also use a conditional ItemGroup to assign files to a framework (ex: ItemGroup Condition=" '$(TargetFramework)' != 'netcoreapp1.0' ").

We've found that this makes our projects easier to maintain because it keeps Framework assignments in a single project. As an added bonus our Framework specific projects can include a single Shared project instead of individual files, which keeps our project files neat and clean.

Contributing

We strongly welcome and encourage contributions to this project. Please read the contributor's guide. If making a large change we request that you open an issue first. If we agree that an issue is a bug, we'll add the "bug" label, and issues that we plan to fix are labeled with an iteration number. We follow the Git Flow approach to branching.

This project has adopted the Microsoft Open Source Code of Conduct. For more information see the Code of Conduct FAQ or contact opencode@microsoft.com with any additional questions or comments.