2017-10-11 122 views
1

我有一個調用U-SQL轉換的管道。 使用門戶部署鏈接服務,數據集,管道Json使用servicePrincipal爲AzureDataLakeAnalytics定義鏈接服務

鏈接服務JSON for ADLS支持ServicePrincipal,但對於ADLA,如果我聲明servicePrincipalKey,則顯示錯誤。

  1. 確實給筆者門戶支持鏈接服務 「AzureDataLakeAnalytics」還是我需要使用VS部署?
  2. 有沒有樣品?因爲下面的JSON不起作用

下面的示例顯示錯誤:

{ 
"name": "ADLA-ProdLinkService", 
"properties": { 
    "type": "AzureDataLakeAnalytics", 
    "typeProperties": { 
     "accountName": "my-account", 
     "servicePrincipalId": "my principal id", 
     "servicePrincipalKey": { 
      "value": "secret key", 
      "type": "SecureString" 
     }, 
     "tenant": "directory id", 
     "subscriptionId": "my subscription", 
     "resourceGroupName": "my resource" 
    } 
} 

}

回答

1

我可以使用下面的鏈接服務

{ 
    "name": "linkedservice-dataanalytics", 
    "properties": { 
     "type": "AzureDataLakeAnalytics", 
     "typeProperties": { 
     "accountName": "<name of your analytics account>", 
     "subscriptionId": "<subscription id in which ADLA exists>", 
     "resourceGroupName": "<resource group name in which ADLA exists>", 
     "servicePrincipalId": "<id of app>", 
     "servicePrincipalKey": "<key of app>", 
     "tenant": "<guid tenant id from the portal>" 
     } 
    } 
} 
  • 觸發USQL腳本我保證應用程序ID其中包含了對Azure Data Lake Store和Azure Data Lake Analytics的適當訪問權限
  • 我將應用程序添加爲包含分析的資源組的所有者CS帳戶和數據湖商店帳戶。然而這可能太多的訪問。你可以嘗試一種受限制的方法。
  • Azure的數據工廠V1
0

是否使用Azure的數據工廠V1或Azure的數據工廠V2?您正在使用的語法(servicePrincipalKey在secureString類型中)適用於ADF V2。如果您使用的是V2,請分享詳細的錯誤信息。

如果您使用的是ADF V1,請遵循@frictionlesspulley共享的語法。