The Blob Trigger binding for NodeJS functions always binds data as a Buffer even if 'dataType' is set to 'stream' or 'string'.
Repro steps
- Create a node-based function using the blob trigger
- Set "dataType" to "stream" in function.json:
{
"bindings": [
{
"name": "fileBlob",
"type": "blobTrigger",
"direction": "in",
"path": "container/{fileName}.csv",
"connection": "AzureWebJobsStorage",
"dataType": "stream"
}
],
"scriptFile": "../dist/myFunction/index.js"
}
Expected behavior
fileBlob input parameter should be some kind of Stream type
Actual behavior
fileBlob input parameter is a Buffer
Known workarounds
None
Related information
Functions runtime ~3
Node ~14
The Blob Trigger binding for NodeJS functions always binds data as a Buffer even if 'dataType' is set to 'stream' or 'string'.
Repro steps
{ "bindings": [ { "name": "fileBlob", "type": "blobTrigger", "direction": "in", "path": "container/{fileName}.csv", "connection": "AzureWebJobsStorage", "dataType": "stream" } ], "scriptFile": "../dist/myFunction/index.js" }Expected behavior
fileBlobinput parameter should be some kind of Stream typeActual behavior
fileBlobinput parameter is a BufferKnown workarounds
None
Related information
Functions runtime ~3
Node ~14