Closed
Description
Symfony version(s) affected
6.4.2
Description
Currently, the implementation of handling SendGrid webhooks processes only the first event. However, SendGrid webhooks often contain multiple batched events (Reference) causing to miss events in the current implementation. The SendgridRequestParser.php#L44 expects a single AbstractMailerEvent
to be returned so i think this one is hard to fix without breaking the current implementation.
How to reproduce
- Implement the Sendgrid webhook & mailer by following the Symfony Docs.
- Send an e-mail to a non-existing recipient address, causing a direct defer. The webhook will contain a
processed
event and adeferred
event. - Only the first event is being parsed. (Ref to code)
Possible Solution
No response
Additional Context
No response