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

Asset Mappings - Create

将已发送共享中的源资产映射到接收共享中的目标资产。
在收到的共享上创建资产映射

PUT {endpoint}/receivedShares/{receivedShareName}/assetMappings/{assetMappingName}?api-version=2021-09-01-preview

URI 参数

Name In Required Type Description
assetMappingName
path True
  • string

资产映射的名称

endpoint
path True
  • string

purview 帐户的扫描终结点。 示例:https://{accountName}.purview.azure.com/share

receivedShareName
path True
  • string

已接收共享的名称

api-version
query True
  • string

要使用的 API 版本。

请求正文

请求正文可以为下列任一内容:

Name Description
AdlsGen2AccountAssetMapping

Blob 存储帐户资产映射。

BlobAccountAssetMapping

adls gen 2 存储帐户资产映射。

AdlsGen2AccountAssetMapping

Blob 存储帐户资产映射。

Name Required Type Description
kind True string:
  • AdlsGen2Account

资产映射的类型。

properties.assetId True
  • string

发送方资产的 ID。

properties.containerName True
  • string

要接收共享路径的容器的名称。

properties.folder True
  • string

将反映共享路径的文件夹。

properties.storageAccountResourceId True
  • string

接收方存储帐户的资源 ID。

properties.mountPath
  • string

共享路径的可选装载路径。

BlobAccountAssetMapping

adls gen 2 存储帐户资产映射。

Name Required Type Description
kind True string:
  • BlobAccount

资产映射的类型。

properties.assetId True
  • string

发送方资产的 ID。

properties.containerName True
  • string

要接收共享路径的容器的名称。

properties.folder True
  • string

将反映共享路径的文件夹。

properties.storageAccountResourceId True
  • string

接收方存储帐户的资源 ID。

properties.mountPath
  • string

共享路径的可选装载路径。

响应

Name Type Description
200 OK AssetMapping:

成功

202 Accepted AssetMapping:

已接受

Other Status Codes

默认错误响应。

示例

AssetMappings_AdlsGen2AccountCreate
AssetMappings_BlobAccountCreate
AssetMappings_Create

AssetMappings_AdlsGen2AccountCreate

Sample Request

PUT accountName.purview.azure.com/share/receivedShares/receivedShareName1/assetMappings/assetMappingName1?api-version=2021-09-01-preview

{
  "kind": "AdlsGen2Account",
  "properties": {
    "assetId": "5d862c55-4de9-4a46-969d-cf1ed3e235ed",
    "storageAccountResourceId": "/subscriptions/de06c3a0-4610-4ca0-8cbb-bbdac204bd65/resourceGroups/receiver-storage-rg/providers/Microsoft.Storage/storageAccounts/receiverstorage",
    "containerName": "sinkcontainer",
    "folder": "newfolder",
    "mountPath": "mountPath"
  }
}

Sample Response

Date: Wed, 13 Sep 2017 17:33:55 GMT
x-ms-correlation-request-id: 5d862c55-4de9-4a46-969d-cf1ed3e235ed
{
  "properties": {
    "assetId": "5d862c55-4de9-4a46-969d-cf1ed3e235ed",
    "storageAccountResourceId": "/subscriptions/de06c3a0-4610-4ca0-8cbb-bbdac204bd65/resourceGroups/receiver-storage-rg/providers/Microsoft.Storage/storageAccounts/receiverstorage",
    "containerName": "sinkcontainer",
    "folder": "newfolder",
    "mountPath": "mountPath",
    "provisioningState": "Succeeded"
  },
  "kind": "AdlsGen2Account",
  "id": "receivedShareShares/receivedShareName1/assetMappings/assetMappingName1",
  "name": "assetMappingName1",
  "type": "receivedShareShares/assetMappings"
}
Date: Wed, 13 Sep 2017 17:33:55 GMT
x-ms-correlation-request-id: 5d862c55-4de9-4a46-969d-cf1ed3e235ed
x-ms-long-running-operation: True
Azure-AsyncOperation: https://accountName.purview.azure.com/share/operationResults/dad6baec-3a39-41df-a469-843a9ee94213?api-version=2021-09-01-preview
Operation-Location: https://accountName.purview.azure.com/share/operationResults/dad6baec-3a39-41df-a469-843a9ee94213?api-version=2021-09-01-preview
{
  "properties": {
    "assetId": "5d862c55-4de9-4a46-969d-cf1ed3e235ed",
    "storageAccountResourceId": "/subscriptions/de06c3a0-4610-4ca0-8cbb-bbdac204bd65/resourceGroups/receiver-storage-rg/providers/Microsoft.Storage/storageAccounts/receiverstorage",
    "containerName": "sinkcontainer",
    "folder": "newfolder",
    "mountPath": "mountPath",
    "provisioningState": "Creating"
  },
  "kind": "AdlsGen2Account",
  "id": "receivedShareShares/receivedShareName1/assetMappings/assetMappingName1",
  "name": "assetMappingName1",
  "type": "receivedShareShares/assetMappings"
}

AssetMappings_BlobAccountCreate

Sample Request

PUT accountName.purview.azure.com/share/receivedShares/receivedShareName1/assetMappings/assetMappingName1?api-version=2021-09-01-preview

{
  "kind": "BlobAccount",
  "properties": {
    "assetId": "5d862c55-4de9-4a46-969d-cf1ed3e235ed",
    "storageAccountResourceId": "/subscriptions/de06c3a0-4610-4ca0-8cbb-bbdac204bd65/resourceGroups/receiver-storage-rg/providers/Microsoft.Storage/storageAccounts/receiverstorage",
    "containerName": "sinkcontainer",
    "folder": "newfolder",
    "mountPath": "mountPath"
  }
}

Sample Response

Date: Wed, 13 Sep 2017 17:33:55 GMT
x-ms-correlation-request-id: 5d862c55-4de9-4a46-969d-cf1ed3e235ed
{
  "properties": {
    "assetId": "5d862c55-4de9-4a46-969d-cf1ed3e235ed",
    "storageAccountResourceId": "/subscriptions/de06c3a0-4610-4ca0-8cbb-bbdac204bd65/resourceGroups/receiver-storage-rg/providers/Microsoft.Storage/storageAccounts/receiverstorage",
    "containerName": "sinkcontainer",
    "folder": "newfolder",
    "mountPath": "mountPath",
    "provisioningState": "Succeeded"
  },
  "kind": "BlobAccount",
  "id": "receivedShareShares/receivedShareName1/assetMappings/assetMappingName1",
  "name": "assetMappingName1",
  "type": "receivedShareShares/assetMappings"
}
Date: Wed, 13 Sep 2017 17:33:55 GMT
x-ms-correlation-request-id: 5d862c55-4de9-4a46-969d-cf1ed3e235ed
x-ms-long-running-operation: True
Azure-AsyncOperation: https://accountName.purview.azure.com/share/operationResults/dad6baec-3a39-41df-a469-843a9ee94213?api-version=2021-09-01-preview
Operation-Location: https://accountName.purview.azure.com/share/operationResults/dad6baec-3a39-41df-a469-843a9ee94213?api-version=2021-09-01-preview
{
  "properties": {
    "assetId": "5d862c55-4de9-4a46-969d-cf1ed3e235ed",
    "storageAccountResourceId": "/subscriptions/de06c3a0-4610-4ca0-8cbb-bbdac204bd65/resourceGroups/receiver-storage-rg/providers/Microsoft.Storage/storageAccounts/receiverstorage",
    "containerName": "sinkcontainer",
    "folder": "newfolder",
    "mountPath": "mountPath",
    "provisioningState": "Creating"
  },
  "kind": "BlobAccount",
  "id": "receivedShareShares/receivedShareName1/assetMappings/assetMappingName1",
  "name": "assetMappingName1",
  "type": "receivedShareShares/assetMappings"
}

AssetMappings_Create

Sample Request

PUT accountName.purview.azure.com/share/receivedShares/receivedShareName1/assetMappings/assetMappingName1?api-version=2021-09-01-preview

{
  "kind": "AdlsGen2Account",
  "properties": {
    "assetId": "5d862c55-4de9-4a46-969d-cf1ed3e235ed",
    "storageAccountResourceId": "/subscriptions/de06c3a0-4610-4ca0-8cbb-bbdac204bd65/resourceGroups/receiver-storage-rg/providers/Microsoft.Storage/storageAccounts/receiverstorage",
    "containerName": "sinkcontainer",
    "folder": "newfolder",
    "mountPath": "mountPath"
  }
}

Sample Response

Date: Wed, 13 Sep 2017 17:33:55 GMT
x-ms-correlation-request-id: 5d862c55-4de9-4a46-969d-cf1ed3e235ed
{
  "properties": {
    "assetId": "5d862c55-4de9-4a46-969d-cf1ed3e235ed",
    "storageAccountResourceId": "/subscriptions/de06c3a0-4610-4ca0-8cbb-bbdac204bd65/resourceGroups/receiver-storage-rg/providers/Microsoft.Storage/storageAccounts/receiverstorage",
    "containerName": "sinkcontainer",
    "folder": "newfolder",
    "mountPath": "mountPath",
    "provisioningState": "Succeeded"
  },
  "kind": "AdlsGen2Account",
  "id": "receivedShareShares/receivedShareName1/assetMappings/assetMappingName1",
  "name": "assetMappingName1",
  "type": "receivedShareShares/assetMappings"
}
Date: Wed, 13 Sep 2017 17:33:55 GMT
x-ms-correlation-request-id: 5d862c55-4de9-4a46-969d-cf1ed3e235ed
x-ms-long-running-operation: True
Azure-AsyncOperation: https://accountName.purview.azure.com/share/operationResults/dad6baec-3a39-41df-a469-843a9ee94213?api-version=2021-09-01-preview
Operation-Location: https://accountName.purview.azure.com/share/operationResults/dad6baec-3a39-41df-a469-843a9ee94213?api-version=2021-09-01-preview
{
  "properties": {
    "assetId": "5d862c55-4de9-4a46-969d-cf1ed3e235ed",
    "storageAccountResourceId": "/subscriptions/de06c3a0-4610-4ca0-8cbb-bbdac204bd65/resourceGroups/receiver-storage-rg/providers/Microsoft.Storage/storageAccounts/receiverstorage",
    "containerName": "sinkcontainer",
    "folder": "newfolder",
    "mountPath": "mountPath",
    "provisioningState": "Creating"
  },
  "kind": "AdlsGen2Account",
  "id": "receivedShareShares/receivedShareName1/assetMappings/assetMappingName1",
  "name": "assetMappingName1",
  "type": "receivedShareShares/assetMappings"
}

定义

AdlsGen2AccountAssetMapping

Blob 存储帐户资产映射。

AssetMappingStatus

资产映射的状态

AssetMappingType

资产映射的类型。

BlobAccountAssetMapping

adls gen 2 存储帐户资产映射。

ProvisioningState

资源的预配状态

PurviewShareError

purview 共享错误模型。

PurviewShareErrorInfo

purview 共享错误正文模型。

AdlsGen2AccountAssetMapping

Blob 存储帐户资产映射。

Name Type Description
id
  • string

资源的资源 ID。

kind string:
  • AdlsGen2Account

资产映射的类型。

name
  • string

资源的名称。

properties.assetId
  • string

发送方资产的 ID。

properties.assetMappingStatus

资产映射的状态

properties.containerName
  • string

要接收共享路径的容器的名称。

properties.folder
  • string

将反映共享路径的文件夹。

properties.location
  • string

接收方存储帐户的位置。

properties.mountPath
  • string

共享路径的可选装载路径。

properties.provisioningState

资源的预配状态

properties.storageAccountResourceId
  • string

接收方存储帐户的资源 ID。

type
  • string

资源的类型。

AssetMappingStatus

资产映射的状态

Name Type Description
Broken
  • string
Ok
  • string

AssetMappingType

资产映射的类型。

Name Type Description
AdlsGen2Account
  • string
BlobAccount
  • string

BlobAccountAssetMapping

adls gen 2 存储帐户资产映射。

Name Type Description
id
  • string

资源的资源 ID。

kind string:
  • BlobAccount

资产映射的类型。

name
  • string

资源的名称。

properties.assetId
  • string

发送方资产的 ID。

properties.assetMappingStatus

资产映射的状态

properties.containerName
  • string

要接收共享路径的容器的名称。

properties.folder
  • string

将反映共享路径的文件夹。

properties.location
  • string

接收方存储帐户的位置。

properties.mountPath
  • string

共享路径的可选装载路径。

properties.provisioningState

资源的预配状态

properties.storageAccountResourceId
  • string

接收方存储帐户的资源 ID。

type
  • string

资源的类型。

ProvisioningState

资源的预配状态

Name Type Description
Creating
  • string
Deleting
  • string
Failed
  • string
Moving
  • string
SoftDeleted
  • string
SoftDeleting
  • string
SourceDeleted
  • string
SourceMoved
  • string
Succeeded
  • string
TargetDeleted
  • string
TargetMoved
  • string
Unknown
  • string

PurviewShareError

purview 共享错误模型。

Name Type Description
error

purview 共享错误正文模型。

PurviewShareErrorInfo

purview 共享错误正文模型。

Name Type Description
code
  • string

错误代码

details

错误模型的嵌套详细信息

message
  • string

错误消息

target
  • string

错误的目标