You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
# Customer Intent: As a .NET developer, I'd like to enable Application Insights Profiler for my .NET web application hosted in Linux
10
10
---
@@ -14,9 +14,9 @@ ms.reviewer: charles.weininger
14
14
By using Profiler, you can track how much time is spent in each method of your live ASP.NET Core web apps that are hosted in Linux on Azure App Service. This article focuses on web apps hosted in Linux. You can also experiment by using Linux, Windows, and Mac development environments.
15
15
16
16
In this article, you:
17
-
18
-
- Set up and deploy an ASP.NET Core web application hosted on Linux.
19
-
- Add Application Insights Profiler to the ASP.NET Core web application.
17
+
> [!div class="checklist"]
18
+
> - Set up and deploy an ASP.NET Core web application hosted on Linux.
19
+
> - Add Application Insights Profiler to the ASP.NET Core web application.
Copy file name to clipboardExpand all lines: articles/azure-monitor/profiler/profiler-azure-functions.md
+5-5Lines changed: 5 additions & 5 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,13 +1,13 @@
1
1
---
2
-
title: Profile Azure Functions app with Application Insights Profiler
2
+
title: Enable Profiler for Azure Functions apps
3
3
description: Enable Application Insights Profiler for Azure Functions app.
4
4
ms.contributor: charles.weininger
5
-
ms.topic: conceptual
6
-
ms.date: 09/22/2023
5
+
ms.topic: how-to
6
+
ms.date: 08/16/2024
7
7
ms.reviewer: ryankahng
8
8
---
9
9
10
-
# Profile live Azure Functions app with Application Insights
10
+
# Enable Profiler for Azure Functions apps
11
11
12
12
In this article, you'll use the Azure portal to:
13
13
- View the current app settings for your Functions app.
@@ -67,7 +67,7 @@ From your Functions app overview page in the Azure portal:
67
67
68
68
The app settings now show up in the table:
69
69
70
-
:::image type="content" source="./media/profiler-azure-functions/app-settings-table.png" alt-text="Screenshot showing the two new app settings in the table on the configuration pane.":::
70
+
:::image type="content" source="./media/profiler-azure-functions/app-settings-table.png" alt-text="Screenshot showing the two new app settings in the table on the configuration pane.":::
@@ -17,7 +17,7 @@ When you use [Application Insights Profiler](./profiler-overview.md) or [Snapsho
17
17
- Processing and analysis.
18
18
- Encryption-at-rest and lifetime management policies.
19
19
20
-
Meanwhile, when you configure your own storage account (BYOS), artifacts are uploaded into a storage account that only you control and cover the cost for:
20
+
Meanwhile, when you configure your own storage account (Bring Your Own Storage, or BYOS), artifacts are uploaded into a storage account that only you control and cover the cost for:
21
21
22
22
- The encryption-at-rest policy and the Lifetime management policy.
Copy file name to clipboardExpand all lines: articles/azure-monitor/profiler/profiler-servicefabric.md
+8-8Lines changed: 8 additions & 8 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,21 +1,21 @@
1
1
---
2
2
title: Enable Profiler for Azure Service Fabric applications
3
3
description: Profile live Azure Service Fabric apps with Application Insights.
4
-
ms.topic: conceptual
4
+
ms.topic: how-to
5
5
ms.custom:
6
-
ms.date: 09/22/2023
6
+
ms.date: 08/16/2024
7
7
---
8
8
9
9
# Enable Profiler for Azure Service Fabric applications
10
10
11
11
Application Insights Profiler is included with Azure Diagnostics. You can install the Azure Diagnostics extension by using an Azure Resource Manager template (ARM template) for your Azure Service Fabric cluster. Get a [template that installs Azure Diagnostics on a Service Fabric cluster](https://github.com/Azure/azure-docs-json-samples/blob/master/application-insights/ServiceFabricCluster.json).
12
12
13
-
In this article, you:
14
-
15
-
- Add the Application Insights Profiler property to your ARM template.
16
-
- Deploy your Service Fabric cluster with the Application Insights Profiler instrumentation key.
17
-
- Enable Application Insights on your Service Fabric application.
18
-
- Redeploy your Service Fabric cluster to enable Profiler.
13
+
In this guide, you learn how to:
14
+
> [!div class="checklist"]
15
+
> - Add the Application Insights Profiler property to your ARM template.
16
+
> - Deploy your Service Fabric cluster with the Application Insights Profiler instrumentation key.
17
+
> - Enable Application Insights on your Service Fabric application.
18
+
> - Redeploy your Service Fabric cluster to enable Profiler.
For more information about this global instrumentation key configuration, see [Use Service Fabric with Application Insights](https://github.com/Azure-Samples/service-fabric-dotnet-getting-started/blob/dev/appinsights/ApplicationInsights.md).
27
+
For more information about this global instrumentation key configuration, see [Use Service Fabric with Application Insights](https://github.com/Azure-Samples/service-fabric-dotnet-getting-started/blob/dev/appinsights/ApplicationInsights.md).
28
28
29
-
1. For any piece of code that you want to instrument, add a `StartOperation<RequestTelemetry>`**using** statement around it, as shown in the following example:
29
+
1. For any piece of code that you want to instrument, add a `StartOperation<RequestTelemetry>`**using** statement around it, as shown in the following example:
30
30
31
-
```csharp
32
-
using Microsoft.ApplicationInsights;
33
-
using Microsoft.ApplicationInsights.DataContracts;
34
-
...
35
-
var client = new TelemetryClient();
36
-
...
37
-
using (var operation = client.StartOperation<RequestTelemetry>("Insert_Your_Custom_Event_Unique_Name"))
38
-
{
39
-
// ... Code I want to profile.
40
-
}
41
-
```
31
+
```csharp
32
+
usingMicrosoft.ApplicationInsights;
33
+
usingMicrosoft.ApplicationInsights.DataContracts;
34
+
...
35
+
varclient=newTelemetryClient();
36
+
...
37
+
using (varoperation=client.StartOperation<RequestTelemetry>("Insert_Your_Custom_Event_Unique_Name"))
38
+
{
39
+
// ... Code I want to profile.
40
+
}
41
+
```
42
42
43
-
Calling `StartOperation<RequestTelemetry>` within another `StartOperation<RequestTelemetry>` scope isn't supported. You can use `StartOperation<DependencyTelemetry>` in the nested scope instead. For example:
43
+
1. Calling `StartOperation<RequestTelemetry>` within another `StartOperation<RequestTelemetry>` scope isn't supported. You can use `StartOperation<DependencyTelemetry>` in the nested scope instead. For example:
44
44
45
-
```csharp
46
-
using (var getDetailsOperation = client.StartOperation<RequestTelemetry>("GetProductDetails"))
47
-
{
48
-
try
49
-
{
50
-
ProductDetail details = new ProductDetail() { Id = productId };
Copy file name to clipboardExpand all lines: articles/azure-monitor/profiler/profiler.md
+5-3Lines changed: 5 additions & 3 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,14 +1,14 @@
1
1
---
2
2
title: Enable Profiler for Azure App Service apps | Microsoft Docs
3
3
description: Profile live apps on Azure App Service with Application Insights Profiler.
4
-
ms.topic: conceptual
4
+
ms.topic: how-to
5
5
ms.date: 08/15/2024
6
6
ms.reviewer: ryankahng
7
7
---
8
8
9
9
# Enable Profiler for Azure App Service apps
10
10
11
-
[Application Insights Profiler](./profiler-overview.md) is preinstalled as part of the Azure App Service runtime. You can run Profiler on ASP.NET and ASP.NET Core apps running on App Service by using the Basic service tier or higher. Follow these steps, even if you included the Application Insights SDK in your application at build time.
11
+
[Application Insights Profiler](./profiler-overview.md) is preinstalled as part of the Azure App Service runtime. You can run Profiler on ASP.NET and ASP.NET Core apps running on App Service by using the Basic service tier or higher.
12
12
13
13
Codeless installation of Application Insights Profiler:
14
14
- Follows [the .NET Core support policy](https://dotnet.microsoft.com/platform/support/policy/dotnet-core).
@@ -37,7 +37,9 @@ To enable Profiler on Linux, walk through the [ASP.NET Core Azure Linux web apps
37
37
38
38
## Enable Application Insights and Profiler
39
39
40
-
The following sections show you how to enable Application Insights for the same subscription or different subscriptions.
40
+
You can enable Profiler either when:
41
+
-[Your Application Insights resource and App Service resource are in the same subscription](#for-application-insights-and-app-service-in-the-same-subscription), or
42
+
-[Your Application Insights resource and App Service resource are in separate subscriptions.](#for-application-insights-and-app-service-in-different-subscriptions)
41
43
42
44
### For Application Insights and App Service in the same subscription
0 commit comments