Reputation: 13141
I have a queue trigger function that looks like this:
[FunctionName(nameof("MyQueueFunction"))]
public async Task Run([QueueTrigger("queue")] Model model, ILogger logger)
{
if (model.ID == 0)
{
// Ignore message in the queue for now
}
}
What I want to be able to do is re-queue the item if the condition stated is not met. I know I could just re-serialize the item and put it back on the queue myself, but is there a better way?
Thanks
Upvotes: 1
Views: 261
Reputation: 16812
Sadly, the Azure Storage Queues are somewhat limited in terms of filtering functionality.
I suspect you will need to move to a Service Bus Queue/Topic and use the Queue/Topic filtering.
Upvotes: 2