小编Ram*_*ias的帖子

Azure 函数:队列触发器需要 Base-64 消息,但未正确处理它们

我有这个Queue Trigger。预期是当我在 中插入一条消息时Queue,触发器必须触发并处理出队的消息。

    [FunctionName("NewPayrollQueueTrigger")]
    public async static void Run([QueueTrigger("myqueue", Connection = 
    "AzureWebJobsStorage")]string myQueueItem,
        [DurableClient] IDurableOrchestrationClient starter,
        ILogger log)
    {
        log.LogInformation($"C# Queue trigger function processed: {myQueueItem}");

        await starter.StartNewAsync("NewPayrollOrchestrator", input: myQueueItem);

    }
Run Code Online (Sandbox Code Playgroud)

触发器正在正常激活,但这种奇怪的行为正在发生。该函数显然希望messageBase-64.

异常绑定参数 'myQueueItem' <--- 输入不是有效的 Base-64 字符串,因为它包含非 base-64 字符、两个以上的填充字符或填充字符中的非法字符。

I'm sending messages to the queue using this method from the Azure Queue library v.12 from Azure.Storage.Queues and found no overloads that encodes the message to Base-64. Note that _queue is a …

c# azure-queues .net-core azure-functions azure-triggers

12
推荐指数
3
解决办法
4060
查看次数