-
Notifications
You must be signed in to change notification settings - Fork 21
Open
Milestone
Description
v3 function.json content:
{
"name": "myQueueItem",
"type": "queueTrigger",
"direction": "in",
"queueName": "helloworldqueue",
"connection": "storage_APPSETTING",
"dataType": "binary"
}
v3 index.js content:
module.exports = async function (context, myQueueItem) {
context.log('JavaScript queue trigger function processed work item', myQueueItem);
};
In v3 the type of myQueueItem
changes based on the value of dataType
. If you set dataType
to binary
, myQueueItem
will be a Buffer
. Otherwise, myQueueItem
will either be a string
or possibly a parsed object if the string was JSON.
In v4, we don't allow users to change myQueueItem
to a Buffer
type, which we should. This does not apply to http triggers, but probably applies to several other triggers/bindings other than storage queue.
nakanoasaservice, sinedied and marcuslang