I have an azure function project with a queue trigger; the project is an azure function v2.
When I add messages to the queue that are not of type JSON, I get an exception inside the JsonSerialization.cs
at the line JObject parsed = JObject.Load(jsonReader);
.
The exception is: Newtonsoft.Json.JsonReaderException: 'Unexpected end when reading JSON. Path '', line 1, position 3.'
The code then proceeds into the Queue trigger normally.
When running azure function v1, I did not run into this exception.
Could someone explain why does azure function v2 force you to have queue messages that are of type JSON? And is there a way to avoid going into the JsonSerialization.cs
??
Thank you!!