你当前正在访问 Microsoft Azure Global Edition 技术文档网站。 如果需要访问由世纪互联运营的 Microsoft Azure 中国技术文档网站,请访问 https://docs.azure.cn

Private Endpoint Connections - Create Or Update

创建或更新服务命名空间的 PrivateEndpointConnections。

PUT https://management.azure.com/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.EventHub/namespaces/{namespaceName}/privateEndpointConnections/{privateEndpointConnectionName}?api-version=2024-01-01

URI 参数

名称 必需 类型 说明
namespaceName
path True

string

命名空间名称

Regex pattern: ^[a-zA-Z][a-zA-Z0-9-]{6,50}[a-zA-Z0-9]$

privateEndpointConnectionName
path True

string

PrivateEndpointConnection 名称

resourceGroupName
path True

string

Azure 订阅中资源组的名称。

subscriptionId
path True

string

唯一标识 Microsoft Azure 订阅的订阅凭据。 此订阅 ID 是每个服务调用的 URI 的一部分。

api-version
query True

string

客户端 API 版本。

请求正文

名称 类型 说明
properties.privateEndpoint

PrivateEndpoint

此连接的专用终结点资源。

properties.privateLinkServiceConnectionState

ConnectionState

有关连接状态的详细信息。

properties.provisioningState

EndPointProvisioningState

专用终结点连接的预配状态。

响应

名称 类型 说明
200 OK

PrivateEndpointConnection

已成功创建 PrivateEndPoint 连接的状态。

201 Created

PrivateEndpointConnection

请求更新已接受的 PrivateEndPoint 连接状态。

202 Accepted

PrivateEndpointConnection

请求更新已接受的 PrivateEndPoint 连接状态。

Other Status Codes

ErrorResponse

描述操作失败原因的 Eventhub 错误响应。

安全性

azure_auth

Azure Active Directory OAuth2 流

Type: oauth2
Flow: implicit
Authorization URL: https://login.microsoftonline.com/common/oauth2/authorize

Scopes

名称 说明
user_impersonation 模拟用户帐户

示例

NameSpacePrivateEndPointConnectionCreate

Sample Request

PUT https://management.azure.com/subscriptions/subID/resourceGroups/ArunMonocle/providers/Microsoft.EventHub/namespaces/sdk-Namespace-2924/privateEndpointConnections/privateEndpointConnectionName?api-version=2024-01-01

{
  "properties": {
    "privateEndpoint": {
      "id": "/subscriptions/dbedb4e0-40e6-4145-81f3-f1314c150774/resourceGroups/SDK-EventHub-8396/providers/Microsoft.Network/privateEndpoints/sdk-Namespace-2847"
    },
    "privateLinkServiceConnectionState": {
      "status": "Rejected",
      "description": "testing"
    },
    "provisioningState": "Succeeded"
  }
}

Sample Response

{
  "id": "/subscriptions/dbedb4e0-40e6-4145-81f3-f1314c150774/resourceGroups/SDK-EventHub-4794/providers/Microsoft.EventHub/namespaces/sdk-Namespace-5828/privateEndpointConnections/928c44d5-b7c6-423b-b6fa-811e0c27b3e0",
  "name": "928c44d5-b7c6-423b-b6fa-811e0c27b3e0",
  "type": "Microsoft.EventHub/Namespaces/PrivateEndpointConnections",
  "properties": {
    "provisioningState": "Succeeded",
    "privateEndpoint": {
      "id": "/subscriptions/dbedb4e0-40e6-4145-81f3-f1314c150774/resourceGroups/SDK-EventHub-4794/providers/Microsoft.Network/privateEndpoints/sdk-Namespace-5828"
    },
    "privateLinkServiceConnectionState": {
      "status": "Approved",
      "description": "Auto-Approved"
    }
  }
}
{
  "id": "/subscriptions/dbedb4e0-40e6-4145-81f3-f1314c150774/resourceGroups/SDK-EventHub-4794/providers/Microsoft.EventHub/namespaces/sdk-Namespace-5828/privateEndpointConnections/928c44d5-b7c6-423b-b6fa-811e0c27b3e0",
  "name": "928c44d5-b7c6-423b-b6fa-811e0c27b3e0",
  "type": "Microsoft.EventHub/Namespaces/PrivateEndpointConnections",
  "properties": {
    "provisioningState": "Succeeded",
    "privateEndpoint": {
      "id": "/subscriptions/dbedb4e0-40e6-4145-81f3-f1314c150774/resourceGroups/SDK-EventHub-4794/providers/Microsoft.Network/privateEndpoints/sdk-Namespace-5828"
    },
    "privateLinkServiceConnectionState": {
      "status": "Approved",
      "description": "Auto-Approved"
    }
  }
}
{
  "id": "/subscriptions/dbedb4e0-40e6-4145-81f3-f1314c150774/resourceGroups/SDK-EventHub-4794/providers/Microsoft.EventHub/namespaces/sdk-Namespace-5828/privateEndpointConnections/928c44d5-b7c6-423b-b6fa-811e0c27b3e0",
  "name": "928c44d5-b7c6-423b-b6fa-811e0c27b3e0",
  "type": "Microsoft.EventHub/Namespaces/PrivateEndpointConnections",
  "properties": {
    "provisioningState": "Succeeded",
    "privateEndpoint": {
      "id": "/subscriptions/dbedb4e0-40e6-4145-81f3-f1314c150774/resourceGroups/SDK-EventHub-4794/providers/Microsoft.Network/privateEndpoints/sdk-Namespace-5828"
    },
    "privateLinkServiceConnectionState": {
      "status": "Approved",
      "description": "Auto-Approved"
    }
  }
}

定义

名称 说明
ConnectionState

ConnectionState 信息。

createdByType

创建资源的标识类型。

EndPointProvisioningState

专用终结点连接的预配状态。

ErrorAdditionalInfo

资源管理错误附加信息。

ErrorDetail

错误详细信息。

ErrorResponse

错误响应指示事件中心服务无法处理传入请求。 错误消息中提供了原因。

PrivateEndpoint

PrivateEndpoint 信息。

PrivateEndpointConnection

PrivateEndpointConnection 的属性。

PrivateLinkConnectionStatus

连接状态。

systemData

与资源的创建和上次修改相关的元数据。

ConnectionState

ConnectionState 信息。

名称 类型 说明
description

string

连接状态的说明。

status

PrivateLinkConnectionStatus

连接状态。

createdByType

创建资源的标识类型。

名称 类型 说明
Application

string

Key

string

ManagedIdentity

string

User

string

EndPointProvisioningState

专用终结点连接的预配状态。

名称 类型 说明
Canceled

string

Creating

string

Deleting

string

Failed

string

Succeeded

string

Updating

string

ErrorAdditionalInfo

资源管理错误附加信息。

名称 类型 说明
info

object

其他信息。

type

string

其他信息类型。

ErrorDetail

错误详细信息。

名称 类型 说明
additionalInfo

ErrorAdditionalInfo[]

错误附加信息。

code

string

错误代码。

details

ErrorDetail[]

错误详细信息。

message

string

错误消息。

target

string

错误目标。

ErrorResponse

错误响应指示事件中心服务无法处理传入请求。 错误消息中提供了原因。

名称 类型 说明
error

ErrorDetail

错误对象。

PrivateEndpoint

PrivateEndpoint 信息。

名称 类型 说明
id

string

专用终结点的 ARM 标识符。

PrivateEndpointConnection

PrivateEndpointConnection 的属性。

名称 类型 说明
id

string

资源的完全限定的资源 ID。 例如 - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}

location

string

资源所在的地理位置

name

string

资源的名称

properties.privateEndpoint

PrivateEndpoint

此连接的专用终结点资源。

properties.privateLinkServiceConnectionState

ConnectionState

有关连接状态的详细信息。

properties.provisioningState

EndPointProvisioningState

专用终结点连接的预配状态。

systemData

systemData

与此资源相关的系统元数据。

type

string

资源类型。 例如“Microsoft.EventHub/Namespaces”或“Microsoft.EventHub/Namespaces/EventHubs”

PrivateLinkConnectionStatus

连接状态。

名称 类型 说明
Approved

string

Disconnected

string

Pending

string

Rejected

string

systemData

与资源的创建和上次修改相关的元数据。

名称 类型 说明
createdAt

string

资源创建时间戳 (UTC) 。

createdBy

string

创建资源的标识。

createdByType

createdByType

创建资源的标识类型。

lastModifiedAt

string

上次修改资源的标识类型。

lastModifiedBy

string

上次修改资源的标识。

lastModifiedByType

createdByType

上次修改资源的标识类型。