0

I have a Consumption Logic App where we Create a .zip blob in a storage account and then extract its content into the same storage, as follows:

enter image description here

We created a Standard Logic App to replace the Consumption one, but the Extract archive to folder (V2) fails with "400 Bad Request Unable to extract contents of file xxxx" All other Create blob (V2) activities work fine.

The connection and the parameters are the same in both Apps.

nahimmedto
  • 25
  • 6

1 Answers1

0

I have reproduced in my environment and expected results as below:

I have first faced same error as you(Created Standard Logic app) :

enter image description here

Then changed overwrite to Yes, It worked :

enter image description here

Succeeded Output:

enter image description here

File Extracted in Blob Storage:

enter image description here

Code view :

{
    "definition": {
        "$schema": "https://schema.management.azure.com/providers/Microsoft.Logic/schemas/2016-06-01/workflowdefinition.json#",
        "actions": {
            "Create_blob_(V2)": {
                "inputs": {
                    "body": "@variables('emo')",
                    "headers": {
                        "ReadFileMetadataFromServer": true
                    },
                    "host": {
                        "connection": {
                            "referenceName": "azureblob"
                        }
                    },
                    "method": "post",
                    "path": "/v2/datasets/@{encodeURIComponent(encodeURIComponent('AccountNameFromSettings'))}/files",
                    "queries": {
                        "folderPath": "/rithwik",
                        "name": "emo.txt",
                        "queryParametersSingleEncoded": true
                    }
                },
                "runAfter": {
                    "Initialize_variable": [
                        "Succeeded"
                    ]
                },
                "runtimeConfiguration": {
                    "contentTransfer": {
                        "transferMode": "Chunked"
                    }
                },
                "type": "ApiConnection"
            },
            "Extract_archive_to_folder_(V2)": {
                "inputs": {
                    "host": {
                        "connection": {
                            "referenceName": "azureblob"
                        }
                    },
                    "method": "post",
                    "path": "/v2/datasets/@{encodeURIComponent(encodeURIComponent('AccountNameFromSettings'))}/extractFolderV2",
                    "queries": {
                        "destination": "/rithwik",
                        "overwrite": true,
                        "queryParametersSingleEncoded": true,
                        "source": "/rithwik/emo1.zip"
                    }
                },
                "runAfter": {
                    "Create_blob_(V2)": [
                        "Succeeded"
                    ]
                },
                "type": "ApiConnection"
            },
            "Initialize_variable": {
                "inputs": {
                    "variables": [
                        {
                            "name": "emo",
                            "type": "string",
                            "value": "emo ra babu"
                        }
                    ]
                },
                "runAfter": {},
                "type": "InitializeVariable"
            }
        },
        "contentVersion": "1.0.0.0",
        "outputs": {},
        "triggers": {
            "manual": {
                "inputs": {},
                "kind": "Http",
                "type": "Request"
            }
        }
    },
    "kind": "Stateful"
}
RithwikBojja
  • 5,069
  • 2
  • 3
  • 7