I noticed that multiple instances of my Web job are receiving the same message and end up acting on it. This is not the desired behavior. I would like multiple messages to be processed concurrently, however, I do not want the same message being processed by multiple instances of the web job.
- My web job is of the continuous running type.
- I use a QueueTrigger to receive the message and invoke the function
- My function runs for several hours.
I have looked into the JobHostConfiguration.BatchSize and MaxDequeue properties and I am not sure on these. I simply want a single instance processing a message and that it could take several hours to complete.
This is what I see in the web job logs indicating the message is received twice.
[01/24/2017 16:17:30 > 7e0338: INFO] Executing: 'Functions.RunExperiment' - Reason: 'New queue message detected on 'runexperiment'.'
[01/24/2017 16:17:30 > 7e0338: INFO] Executing: 'Functions.RunExperiment' - Reason: 'New queue message detected on 'runexperiment'.'

