在 Azure 门户中创建、查看和管理事件网格系统主题Create, view, and manage Event Grid system topics in the Azure portal

本文说明如何使用 Azure 门户创建和管理系统主题。This article shows you how to create and manage system topics using the Azure portal. 有关系统主题的概述,请参阅系统主题For an overview of system topics, see System topics.

创建系统主题Create a system topic

可以通过两种方式创建 Azure 资源(存储帐户、事件中心命名空间等)的系统主题:You can create a system topic for an Azure resource (Storage account, Event Hubs namespace, etc.) in two ways:

  • 使用资源(例如存储帐户或事件中心命名空间)的“事件”页。Using the Events page of a resource, for example, Storage Account or Event Hubs Namespace. 在 Azure 门户中使用“事件”页为 Azure 源(例如 Azure 存储帐户)引发的事件创建事件订阅时,门户创建 Azure 资源的系统主题,然后创建该系统主题的订阅。When you use the Events page in the Azure portal to create an event subscription for an event raised by an Azure source (for example: Azure Storage account), the portal creates a system topic for the Azure resource and then creates a subscription for the system topic. 如果是首次在 Azure 资源上创建事件订阅,则指定系统主题的名称。You specify the name of the system topic if you are creating an event subscription on the Azure resource for the first time. 从第二次开始,系统主题名称将在只读模式下显示。From the second time onwards, the system topic name is displayed for you in the read-only mode.
  • 使用“事件网格系统主题”页。Using the Event Grid System Topics page. 以下步骤用于通过“事件网格系统主题”页创建系统主题。The following steps are for creating a system topic using the Event Grid System Topics page.
  1. 登录到 Azure 门户Sign in to Azure portal.

  2. 在顶部的搜索框中,键入“事件网格系统主题”,然后按 Enter。In the search box at the top, type Event Grid System Topics, and then press ENTER.

    搜索系统主题

  3. 在“事件网格系统主题”页上的工具栏中选择“+ 添加”。 On the Event Grid System Topics page, select + Add on the toolbar.

    添加系统主题 - 工具栏按钮

  4. 在“创建事件网格系统主题”页中执行以下步骤:On the Create Event Grid System Topic page, do the following steps:

    1. 选择“主题类型”。Select the topic type. 以下示例选择了“存储帐户”选项。In the following example, Storage Accounts option is selected.

    2. 选择包含存储帐户资源的“Azure 订阅”。Select the Azure subscription that has your storage account resource.

    3. 选择包含存储帐户的“资源组”。Select the resource group that has the storage account.

    4. 选择 “存储帐户”Select the storage account.

    5. 输入要创建的系统主题的名称。Enter a name for the system topic to be created.

      备注

      可以使用此系统主题名来搜索指标和诊断日志。You can use this system topic name to search metrics and diagnostic logs.

    6. 选择“查看 + 创建”。Select Review + create.

      创建系统主题

    7. 查看设置并选择“创建”。Review settings and select Create.

      查看并创建系统主题

    8. 部署成功后,选择“转到资源”以查看创建的系统主题的“事件网格系统主题”页。After the deployment succeeds, select Go to resource to see the Event Grid System Topic page for the system topic you created.

      系统主题页

查看所有系统主题View all system topics

按照以下步骤查看所有现有事件网格系统主题。Follow these steps to view all existing Event Grid system topics.

  1. 登录到 Azure 门户Sign in to Azure portal.

  2. 在顶部的搜索框中,键入“事件网格系统主题”,然后按 Enter。In the search box at the top, type Event Grid System Topics, and then press ENTER.

    搜索系统主题

  3. 在“事件网格系统主题”页上可以看到所有系统主题。On the Event Grid System Topics page, you see all the system topics.

    系统主题列表

  4. 从列表中选择“系统主题”以查看其详细信息。Select a system topic from the list to see details about it.

    系统主题详细信息

    此页显示有关系统主题的详细信息,如以下信息:This page shows you details about the system topic such as the following information:

    • 源。Source. 在其上创建系统主题的资源的名称。Name of the resource on which the system topic was created.
    • 源类型。Source type. 资源的类型。Type of the resource. 例如 Microsoft.Storage.StorageAccountsMicrosoft.EventHub.NamespacesMicrosoft.Resources.ResourceGroups 等。For example: Microsoft.Storage.StorageAccounts, Microsoft.EventHub.Namespaces, Microsoft.Resources.ResourceGroups and so on.
    • 为系统主题创建的任何订阅。Any subscriptions created for the system topic.

    此页允许如下操作:This page allows operations such as the following ones:

    • 创建事件订阅。在工具栏上选择“+事件订阅”。Create an event subscription Select +Event Subscription on the toolbar.
    • 删除事件订阅。Delete an event subscription. 在工具栏上选择“删除”。Select Delete on the toolbar.
    • 为系统主题添加标记。Add tags for the system topic. 在左侧菜单中选择“标记”,并指定标记名称和值。Select Tags on the left menu, and specify tag names and values.

删除系统主题Delete a system topic

  1. 按照查看系统主题部分中的说明查看所有系统主题,并从列表选择要删除的系统主题。Follow instructions from the View system topics section to view all system topics, and select the system topic that you want to delete from the list.

  2. 在“事件网格系统主题”页上的工具栏中选择“删除”。 On the Event Grid System Topic page, select Delete on the toolbar.

    系统主题 -“删除”按钮

  3. 在确认页上选择“确定”以确认删除。On the confirmation page, select OK to confirm the deletion. 它删除系统主题以及系统主题的所有事件订阅。It deletes the system topic and also all the event subscriptions for the system topic.

创建事件订阅Create an event subscription

  1. 按照查看系统主题部分中的说明查看所有系统主题,并从列表选择要删除的系统主题。Follow instructions from the View system topics section to view all system topics, and select the system topic that you want to delete from the list.

  2. 在“事件网格系统主题”页上的工具栏中选择“+ 事件订阅”。 On the Event Grid System Topic page, select + Event Subscription from the toolbar.

    系统主题 - 添加事件订阅按钮

  3. 确认已自动填充“主题类型”、“源资源”和“主题名称”。Confirm that the Topic Type, Source Resource, and Topic Name are automatically populated. 输入名称,选择“终结点类型”,并指定“终结点”。Enter a name, select an Endpoint Type, and specify the endpoint. 然后选择“创建”以创建事件订阅。Then, select Create to create the event subscription.

    系统主题 - 创建事件订阅

后续步骤Next steps

请参阅 Azure 事件网格中的系统主题部分,详细了解 Azure 事件网格支持的系统主题和主题类型。See the System topics in Azure Event Grid section to learn more about system topics and topic types supported by Azure Event Grid.