azure-sdk-for-net: [BUG] DeserializeEventGridEvents is not working when using the ServiceBusQueue flow
Describe the bug I have not tried all consumer, but when trying it with the Azure Service Bus Queue, the data does not come as an array as mentioned in the doc page here https://docs.microsoft.com/en-us/dotnet/api/overview/azure/eventgrid?view=azure-dotnet
Consequently, calling DeserializeEventGridEvents expects to receive an array, but I receive only 1 object.
Expected behavior Explain how this should work better via the documentation, or provide a better method, or fix the what is being passed in to the queue?
Actual behavior (include Exception or Stack Trace)

Environment:
- Microsoft.Azure.EventGrid: 3.2.0
- Microsoft.Azure.ServiceBus: 3.1.1
About this issue
- Original URL
- State: closed
- Created 4 years ago
- Comments: 16 (11 by maintainers)
Hello @jsgoupil … thanks for your feedback and we understand your concern.
FYI, Microsoft.Azure.Management.EventGrid is used for various CRUD management APIs through ARM for Event Grid. These are used for control plane only. Microsoft.Azure.EventGrid and Azure.Messaging.EventGrid are for the data plane operations only. The separation between management/control and data plane is the pattern observed by all Azure services and not specific to Event Grid. Actually, it is a requirement for our team to do so.
As for the new Azure.Messaging.EventGrid… We are still in the process of authoring/finalizing this new package. We are working on documentation including migration documents. The goal is to ensure the new package addresses all customers feedback and include all new features (as well as fix any existing bugs in the old package).
We appreciate and understand the pain during this period and we are working hard to address this.
thanks
Just noting that this is not an issue in the new Event Grid SDK that is currently in beta - https://www.nuget.org/packages/Azure.Messaging.EventGrid/4.0.0-beta.2