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
<!-- No table(s) at https://learn.microsoft.com/azure/azure-monitor/reference/tables/tables-resourcetype. -->
39
+
40
+
Azure Notification Hubs supports operational logs, which capture management operations that are performed on the Notification Hubs namespace. All logs are stored in JavaScript Object Notation (JSON) format in the following two locations:
41
+
42
+
-**AzureActivity**: Displays logs from operations and actions that are conducted against the namespace in the Azure portal or through Azure Resource Manager template deployments.
43
+
-**AzureDiagnostics**: Displays logs from operations and actions that are conducted against the namespace by using the API, or through management clients on the language SDK.
44
+
45
+
Diagnostic log JSON strings include the elements listed in the following table:
46
+
47
+
| Name | Description |
48
+
| ------- | ------- |
49
+
| time | UTC timestamp of the log |
50
+
| resourceId | Relative path to the Azure resource |
51
+
| operationName | Name of the management operation |
Operational logs capture all management operations that are performed on the Azure Notification Hubs namespace. Data operations aren't captured, because of the high volume of data operations that are conducted on notification hubs.
62
+
63
+
[Microsoft.NotificationHubs resource provider operations](/azure/role-based-access-control/permissions/integration#microsoftnotificationhubs) lists all the management operations that are captured in operational logs.
64
+
65
+
## Related content
66
+
67
+
- See [Monitor Notification Hubs](monitor-notification-hubs.md) for a description of monitoring Notification Hubs.
68
+
- See [Monitor Azure resources with Azure Monitor](/azure/azure-monitor/essentials/monitor-azure-resource) for details on monitoring Azure resources.
For more information about the resource types for Azure Notification Hubs, see [Notification Hubs monitoring data reference](monitor-notification-hubs-reference.md).
For a list of available metrics for Notification Hubs, see [Notification Hubs monitoring data reference](monitor-notification-hubs-reference.md#metrics).
Notification Hubs supports activity and operational logs, which capture management operations that are performed on the Notification Hubs namespace. Data operations aren't captured, because of the high volume of data operations that are conducted on notification hubs.
31
+
32
+
You can archive the diagnostic logs to a storage account or stream them to an event hub. Sending the logs to a Log Analytics workspace isn't currently supported.
33
+
34
+
- For more information about the logs and instructions for enabling log collection, see [Enable diagnostics logs for Notification Hubs](notification-hubs-diagnostic-logs.md).
35
+
36
+
- For the available resource log categories, associated Log Analytics tables, and the management operations captured in operational logs, see [Notification Hubs monitoring data reference](monitor-notification-hubs-reference.md#resource-logs).
The [Notification Hubs REST APIs](/rest/api/notificationhubs) fall into the following categories:
43
+
44
+
-**Azure Resource Manager:** APIs that perform Resource Manager operations, and have `/providers/Microsoft.NotificationHubs/` as part of the request URI.
45
+
-**Notification Hubs service:** APIs that enable operations directly on the Notification Hubs service, and have `<namespaceName>.servicebus.windows.net/` in the request URI.
46
+
47
+
The [Get notification message telemetry](/rest/api/notificationhubs/get-notification-message-telemetry) API helps monitor push notifications sent from a hub by providing telemetry on the finished states of outgoing push notifications. The Notification ID that this API uses can be retrieved from the HTTP Location header included in the response of the REST API used to send the notification.
The following table lists some suggested alert rules for Notification Hubs. These alerts are just examples. You can set alerts for any metric, log entry, or activity log entry that's listed in the [Notification Hubs monitoring data reference](monitor-notification-hubs-reference.md).
82
+
83
+
| Alert type | Condition | Description |
84
+
|:---|:---|:---|
85
+
| Platform metric | Payload Errors | Whenever the count of pushes that failed because the push notification service (PNS) returned a bad payload error is greater than a dynamic threshold |
86
+
| Activity log | Delete Namespace (Namespace) | Whenever the Activity Log has an event with Category='Administrative', Signal name='Delete Namespace (Namespace)' |
- See [Notification Hubs monitoring data reference](monitor-notification-hubs-reference.md) for a reference of the metrics, logs, and other important values created for Notification Hubs.
93
+
- See [Enable diagnostics logs for Notification Hubs](notification-hubs-diagnostic-logs.md) for information about diagnostic logs for Notification Hubs and how to enable them.
94
+
- See [Get notification message telemetry](/rest/api/notificationhubs/get-notification-message-telemetry) for information about using the API to monitor push notification success.
95
+
- See [Monitoring Azure resources with Azure Monitor](/azure/azure-monitor/essentials/monitor-azure-resource) for general details on monitoring Azure resources.
Copy file name to clipboardExpand all lines: articles/notification-hubs/notification-hubs-diagnostic-logs.md
+11-33Lines changed: 11 additions & 33 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,11 +1,11 @@
1
1
---
2
2
title: Azure Notification Hubs diagnostics logs | Microsoft Docs
3
-
description: This article provides an overview of all the operational and diagnostics logs that are available for Azure Notification Hubs.
3
+
description: Learn about the operational and diagnostics logs that are available for Azure Notification Hubs, and how to enable diagnostic logging.
4
4
author: sethmanheim
5
5
ms.author: sethm
6
6
ms.service: notification-hubs
7
7
ms.topic: article
8
-
ms.date: 10/23/2023
8
+
ms.date: 03/12/2024
9
9
---
10
10
11
11
# Enable diagnostics logs for Notification Hubs
@@ -61,7 +61,7 @@ For calls originating from the Azure portal the `identity` field is empty. The l
61
61
}
62
62
```
63
63
64
-
For calls made through Azure Resource Manager the `identity` field will contain the username of the logged in user.
64
+
For calls made through Azure Resource Manager the `identity` field contains the username of the logged in user.
65
65
66
66
```json
67
67
{
@@ -70,7 +70,7 @@ For calls made through Azure Resource Manager the `identity` field will contain
70
70
}
71
71
```
72
72
73
-
For calls to the Notification Hubs REST API the `identity` field will contain the name of the access policy used to generate the SharedAccessSignature token.
73
+
For calls to the Notification Hubs REST API the `identity` field contains the name of the access policy used to generate the SharedAccessSignature token.
74
74
75
75
```json
76
76
{
@@ -81,41 +81,19 @@ For calls to the Notification Hubs REST API the `identity` field will contain th
81
81
82
82
## Events and operations captured in operational logs
83
83
84
-
Operational logs capture all management operations that are performed on the Azure Notification Hubs namespace. Data operations are not captured, because of the high volume of data operations that are conducted on Azure Notification Hubs.
85
-
86
-
The following management operations are captured in operational logs:
87
-
88
-
| Scope | Operation Name | Operation Description |
89
-
| :-- | :-- | :-- |
90
-
| Namespace | Microsoft.NotificationHubs/Namespaces/authorizationRules/action | List Authorization Rules |
Operational logs capture all management operations that are performed on the Azure Notification Hubs namespace. Data operations aren't captured, because of the high volume of data operations that are conducted on notification hubs.
85
+
86
+
For a list of the management operations that are captured in operational logs, see [Microsoft.NotificationHubs resource provider operations](/azure/role-based-access-control/permissions/integration#microsoftnotificationhubs).
87
+
88
+
### Enable operational logs
111
89
112
90
Operational logs are disabled by default. To enable logs, do the following:
113
91
114
92
1. In the [Azure portal](https://portal.azure.com), go to your Azure Notification Hubs namespace and then, under **Monitoring**, select **Diagnostic settings**.
0 commit comments