Data Factory Pipeline Copy Activity (Cosmos DB - Mongo API) does not run

Patrick Steiner 11 Reputation points
2020-05-06T08:29:26.193+00:00

A simple data copy activity pipeline in Azure Data Factory to copy collection data from one Cosmos DB Account (Mongo API) to another Cosmos DB Account (Mongo API) does fail with the following error:

{
    "errorCode": "2200",
    "message": "'Type=Microsoft.Azure.Documents.DocumentClientException,Message=, Request URI: /, RequestStats: , SDK: documentdb-dotnet-sdk/2.5.1 Host/64-bit MicrosoftWindowsNT/6.2.9200.0,Source=Microsoft.Azure.Documents.Client,'",
    "failureType": "UserError",
    "target": "dev_copy_mongo_subscriptions",
    "details": []
}

in Output:

{
    "dataRead": 44294,
    "dataWritten": 0,
    "sourcePeakConnections": 1,
    "sinkPeakConnections": 1,
    "rowsRead": 12,
    "rowsCopied": 0,
    "copyDuration": 5,
    "throughput": 8.651,
    "errors": [
        {
            "Code": 11000,
            "Message": "'Type=Microsoft.Azure.Documents.DocumentClientException,Message=, Request URI: /, RequestStats: , SDK: documentdb-dotnet-sdk/2.5.1 Host/64-bit MicrosoftWindowsNT/6.2.9200.0,Source=Microsoft.Azure.Documents.Client,'",
            "EventType": 0,
            "Category": 5,
            "Data": {},
            "MsgId": null,
            "ExceptionType": null,
            "Source": null,
            "StackTrace": null,
            "InnerEventInfos": []
        }
    ],
Azure Cosmos DB
Azure Cosmos DB
An Azure NoSQL database service for app development.
1,442 questions
Azure Data Factory
Azure Data Factory
An Azure service for ingesting, preparing, and transforming data at scale.
9,538 questions
{count} votes

4 answers

Sort by: Most helpful
  1. HimanshuSinha-msft 601 Reputation points
    2020-05-07T00:28:58.357+00:00

    Hello @Patrick Steiner ,

    I am aware that you have raised a request with the MS support , but I did try to copy a very simple document with zipcode and it worked fine for me . The error which you have pasted does not help a lot . The below clip may help you understand what I am doing .

    8011-adf-ui.gif

    2 people found this answer helpful.

  2. Patrick Steiner 11 Reputation points
    2020-09-23T07:27:46.257+00:00

    Hi @Prithvi Chawla
    Yes - there is a solution provided by MS Support:

    Symptom:
    Pipeline with Copy Activity in context of Cosmos DB Accounts (mongo) does not work
    Cause:
    ADF Not fully compatible with Mongo API 3.6
    Resolution:
    Change the host name in connection string from ‘.mongo.cosmos.azure.com’ to ‘.documents.azure.com' and then retry it.

    After I adapted the connection strings stored in the Key Vault as shown above, it started to work.

    Hope this helps

    2 people found this answer helpful.

  3. Prithvi Chawla 1 Reputation point
    2020-09-23T07:12:17.013+00:00

    I am facing the similar issue while trying to migrate data between two different subscriptions.
    I am using Key vault to store the access keys.
    The error message I am getting is -

    Operation on target Copy data1 failed: 'Type=Microsoft.Azure.Documents.DocumentClientException,Message=, Request URI: /, RequestStats: , SDK: documentdb-dotnet-sdk/2.5.1 Host/64-bit MicrosoftWindowsNT/6.2.9200.0,Source=Microsoft.Azure.Documents.Client,'

    Is there any resolution yet? @Mike-Ubezzi-MSFT

    0 comments No comments

  4. Prithvi Chawla 1 Reputation point
    2020-09-23T14:41:22.08+00:00

    @Patrick Steiner Thanks, it worked by making this change.

    0 comments No comments