question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

[Data Factory] Failed to pass string Parameter to ADF pipeline

See original GitHub issue

Describe the bug

  • Can not pass string parameter to ADF pipeline. When trying to pass string parameter(such as folder name) to ADF pipeline, the string has been changed to dictionary format on Pipeline side.

  • js code:

const params = {
    valtest: new String("test")
};
  • data show on ADF UI:
    "value": {
        "0": "t",
        "1": "e",
        "2": "s",
        "3": "t"
    }

To Reproduce Steps to reproduce the behavior:

  1. Create a DataFactoryManagementClient instance.
  2. Add the parameter in createRun

Expected behavior The string should be passed to ADF parameter as string rather other format which can not use in parameter.

Screenshots image

Additional context Sample code I used:

const { ClientSecretCredential } = require('@azure/identity');
const { DataFactoryManagementClient } = require("@azure/arm-datafactory");

const subscriptionId = '****';
const resourceGroupName = '****';
const factoryName = '****';
const pipelineName = '****';

const tenantID = '****';
const clientID = '****';
const clientSecret = '****';

const adfClient = new DataFactoryManagementClient(
    new ClientSecretCredential(
        tenantID,
        clientID,
        clientSecret,
    ),
    subscriptionId,
);

const params = {
    valtest: new String("test")
};


const run = adfClient.pipelines.createRun(
    resourceGroupName,
    factoryName,
    pipelineName,
    {
        parameters: params
    }
);

Issue Analytics

  • State:closed
  • Created a year ago
  • Comments:6 (5 by maintainers)

github_iconTop GitHub Comments

2reactions
qiaozhacommented, Jun 7, 2022

@xirzec Thanks Jeff, Jose told me to use a m4 option modelerfour.treat-type-object-as-anything: true, I will try to regenerate the package and see if it can resolve this issue.

1reaction
qiaozhacommented, Jun 8, 2022

released a new package here https://www.npmjs.com/package/@azure/arm-datafactory/v/10.6.0 which should be able to fix this issue.

Read more comments on GitHub >

github_iconTop Results From Across the Web

When passing a parameter to an Azure Data ADF pipeline ...
When passing a parameter to an Azure Data ADF pipeline from Power Automate: Failed: The expression 'pipeline().parameters.EmailTo.
Read more >
How to pass parameters to ADF pipeline using .NET SDK
I'm using this pipeline parameter within my Copy Data activity in the query like: ... FROM @{pipeline().parameters.schema}.CUSTOMERS t2 ...
Read more >
ADF pipeline parameters default values · Issue #81 - GitHub
It's about passing (parameter) values to the ADF pipeline and collecting it. Here is my use case - I have a pipeline(say P2)...
Read more >
How to Pass Parameter and Variable Value from Pipeline to ...
How to Pass Parameter and Variable Value from Pipeline to Mapping Data Flow in Azure Data Factory | ADF Tutorial 2022, in this...
Read more >
Azure Data Factory v2 Parameter Passing
Prior, your pipeline would fail, now you can give the dataset parameter a default inside the dataset. Better yet, your two parameter names...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found