Optionaloptions: EnqueueOneOrMoreOptionsThe following are true:
Taken together, we need to ensure each job only contains one chunk of recipients so it either
succeeds or fails and retries on its own. If we moved chunking to the
NotificationClient.trigger method, for example, the following could happen:
Now the job will fail indefinitely and the later batches won't get their notifications.
Even if you're sure you won't have more >MAXIMUM_RECIPIENTS_COUNT recipients, the method
enforces other best practices, like setting expiresAt on enqueue instead of calculating it in
your job on each run. Doing this usually means it's always in the future and doesn't help
prevent stale notifications.
So please, use this method if not for customers, then to save fellow engineers time debugging!
Use NotificationClient.triggerChunked instead; see the README for details.
In short: It's important that notification jobs use this method. It enforces best practices to ensure customers don't receive duplicate or stale notifications.