你当前正在访问 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 参数
名称 | 在 | 必需 | 类型 | 说明 |
---|---|---|---|---|
namespace
|
path | True |
string minLength: 6maxLength: 50 pattern: ^[a-zA-Z][a-zA-Z0-9-]{6,50}[a-zA-Z0-9]$ |
Namespace名称 |
private
|
path | True |
string |
PrivateEndpointConnection 名称 |
resource
|
path | True |
string minLength: 1maxLength: 90 |
Azure 订阅中的资源组的名称。 |
subscription
|
path | True |
string |
唯一标识Microsoft Azure 订阅的订阅凭据。 订阅 ID 构成了每个服务调用的 URI 的一部分。 |
api-version
|
query | True |
string |
客户端 API 版本。 |
请求正文
名称 | 类型 | 说明 |
---|---|---|
properties.privateEndpoint |
此连接的专用终结点资源。 |
|
properties.privateLinkServiceConnectionState |
有关连接状态的详细信息。 |
|
properties.provisioningState |
专用终结点连接的预配状态。 |
响应
名称 | 类型 | 说明 |
---|---|---|
200 OK |
已成功创建 PrivateEndPoint 连接的状态。 |
|
201 Created |
请求更新已接受的 PrivateEndPoint 连接状态。 |
|
202 Accepted |
请求更新已接受的 PrivateEndPoint 连接状态。 |
|
Other Status Codes |
事件中心错误响应,描述作失败的原因。 |
安全性
azure_auth
Azure Active Directory OAuth2 Flow
类型:
oauth2
流向:
implicit
授权 URL:
https://login.microsoftonline.com/common/oauth2/authorize
作用域
名称 | 说明 |
---|---|
user_impersonation | 模拟用户帐户 |
示例
NameSpacePrivateEndPointConnectionCreate
示例请求
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"
}
}
示例响应
{
"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"
}
}
}
定义
名称 | 说明 |
---|---|
Connection |
ConnectionState 信息。 |
created |
创建资源的标识的类型。 |
End |
专用终结点连接的预配状态。 |
Error |
资源管理错误附加信息。 |
Error |
错误详细信息。 |
Error |
错误响应指示事件中心服务无法处理传入请求。 错误消息中提供了原因。 |
Private |
PrivateEndpoint 信息。 |
Private |
PrivateEndpointConnection 的属性。 |
Private |
连接状态。 |
system |
与创建和上次修改资源相关的元数据。 |
ConnectionState
ConnectionState 信息。
名称 | 类型 | 说明 |
---|---|---|
description |
string |
连接状态的说明。 |
status |
连接状态。 |
createdByType
创建资源的标识的类型。
值 | 说明 |
---|---|
Application | |
Key | |
ManagedIdentity | |
User |
EndPointProvisioningState
专用终结点连接的预配状态。
值 | 说明 |
---|---|
Canceled | |
Creating | |
Deleting | |
Failed | |
Succeeded | |
Updating |
ErrorAdditionalInfo
资源管理错误附加信息。
名称 | 类型 | 说明 |
---|---|---|
info |
object |
其他信息。 |
type |
string |
其他信息类型。 |
ErrorDetail
错误详细信息。
名称 | 类型 | 说明 |
---|---|---|
additionalInfo |
错误附加信息。 |
|
code |
string |
错误代码。 |
details |
错误详细信息。 |
|
message |
string |
错误消息。 |
target |
string |
错误目标。 |
ErrorResponse
错误响应指示事件中心服务无法处理传入请求。 错误消息中提供了原因。
名称 | 类型 | 说明 |
---|---|---|
error |
错误对象。 |
PrivateEndpoint
PrivateEndpoint 信息。
名称 | 类型 | 说明 |
---|---|---|
id |
string |
专用终结点的 ARM 标识符。 |
PrivateEndpointConnection
PrivateEndpointConnection 的属性。
名称 | 类型 | 说明 |
---|---|---|
id |
string |
资源的完全限定资源 ID。 Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} |
location |
string |
资源所在的地理位置 |
name |
string |
资源的名称 |
properties.privateEndpoint |
此连接的专用终结点资源。 |
|
properties.privateLinkServiceConnectionState |
有关连接状态的详细信息。 |
|
properties.provisioningState |
专用终结点连接的预配状态。 |
|
systemData |
与此资源相关的系统元数据。 |
|
type |
string |
资源的类型。 例如“Microsoft.EventHub/Namespaces”或“Microsoft.EventHub/Namespaces/EventHubs” |
PrivateLinkConnectionStatus
连接状态。
值 | 说明 |
---|---|
Approved | |
Disconnected | |
Pending | |
Rejected |
systemData
与创建和上次修改资源相关的元数据。
名称 | 类型 | 说明 |
---|---|---|
createdAt |
string (date-time) |
资源创建时间戳(UTC)。 |
createdBy |
string |
创建资源的标识。 |
createdByType |
创建资源的标识的类型。 |
|
lastModifiedAt |
string (date-time) |
上次修改资源的标识的类型。 |
lastModifiedBy |
string |
上次修改资源的标识。 |
lastModifiedByType |
上次修改资源的标识的类型。 |