Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

troubleshooting #2264

Merged
merged 8 commits into from
May 12, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions Readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -64,5 +64,8 @@ Refer to our [Milestones](https://github.com/microsoft/ApplicationInsights-dotne

## Support

A guide on common troubleshooting topics is available [here](troubleshooting).

For immediate support relating to the Application Insights .NET SDK we encourage you to file an [Azure Support Request](https://docs.microsoft.com/azure/azure-portal/supportability/how-to-create-azure-support-request) with Microsoft Azure instead of filing a GitHub Issue in this repository.
You can do so by going online to the [Azure portal](https://portal.azure.com/) and submitting a support request. Access to subscription management and billing support is included with your Microsoft Azure subscription, and technical support is provided through one of the [Azure Support Plans](https://azure.microsoft.com/support/plans/). For step-by-step guidance for the Azure portal, see [How to create an Azure support request](https://docs.microsoft.com/azure/azure-portal/supportability/how-to-create-azure-support-request). Alternatively, you can create and manage your support tickets programmatically using the [Azure Support ticket REST API](https://docs.microsoft.com/rest/api/support/).

File renamed without changes.
35 changes: 35 additions & 0 deletions troubleshooting/Ingestion/PostTelemetry.ps1
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
$url="https://{IngestionEndpoint-from-Component-ConnectionString}/v2/track"
$iKey="{test-iKey}"
Write-Host $url, $iKey

$time = Get-Date
$time = $time.ToUniversalTime().ToString('o')

$availabilityData = @"
{
"data": {
"baseData": {
"ver": 2,
"id": "TestId",
"name": "Post Telemetry Test",
"duration": "10.00:00:00",
"success": true,
"runLocation": "TestLocation",
"message": "Test Message",
"properties": {
"TestProperty": "TestValue"
}
},
"baseType": "AvailabilityData"
},
"ver": 1,
"name": "Microsoft.ApplicationInsights.Metric",
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

seems incorrect for AvailabilityData?

"time": "$time",
"sampleRate": 100,
"iKey": "$iKey",
"flags": 0
}
"@

Invoke-WebRequest -Uri $url -Method POST -Body $availabilityData -Verbose -Debug -UseBasicParsing
# Expected Output: {"itemsReceived":1,"itemsAccepted":1,"errors":[]}
13 changes: 13 additions & 0 deletions troubleshooting/Ingestion/Readme.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
# Troubleshooting Ingestion

## Fiddler

A tool such as Fiddler can be used to inspect raw HTTPS data from an app integrated with SDK to Ingestion Service.

## Networking

If the SDK is unable to send telemetry to the Ingestion Service, you may be experiencing a networking issue.

Please review our guides on [IP Addresses used by Azure Monitor](https://docs.microsoft.com/azure/azure-monitor/app/ip-addresses)

You can test your network by manually sending telemetry using the PowerShell script [PostTelemetry.ps1](PostTelemetry.ps1).
23 changes: 23 additions & 0 deletions troubleshooting/Readme.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
# Troubleshooting

## For Immediate Support

For immediate support relating to the Application Insights .NET SDK we encourage you to file an [Azure Support Request](https://docs.microsoft.com/azure/azure-portal/supportability/how-to-create-azure-support-request) with Microsoft Azure instead of filing a GitHub Issue in this repository.
You can do so by going online to the [Azure portal](https://portal.azure.com/) and submitting a support request. Access to subscription management and billing support is included with your Microsoft Azure subscription, and technical support is provided through one of the [Azure Support Plans](https://azure.microsoft.com/support/plans/). For step-by-step guidance for the Azure portal, see [How to create an Azure support request](https://docs.microsoft.com/azure/azure-portal/supportability/how-to-create-azure-support-request). Alternatively, you can create and manage your support tickets programmatically using the [Azure Support ticket REST API](https://docs.microsoft.com/rest/api/support/).

## SDK Internal Logs

The Application Insights .NET SDK uses ETW to expose internal exceptions.

To collect these logs, please review our full guide on [ETW](ETW).

## Networking Issues

The Application Insights .NET SDK has no knowledge of the environment it's deployed in.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this statement is incorrect, if we consider the fact that SDK does have specific initializers for azure environments.

The SDK will send telemetry to the configured endpoint.

If you suspect networking issues, please review our guide on [Troubleshooting Ingestion](Ingestion).

## No Data

Please review our full guide on [Troubleshooting no data](https://docs.microsoft.com/azure/azure-monitor/app/asp-net-troubleshoot-no-data)