Closed Doris-Ge closed 1 year ago
Please make sure that this branch is based off of dev
and not mater
. In the Go repo, we make all the new changes in the dev
branch and only the releases are merged to the main (master
) branch. Thank you!
Please make sure that this branch is based off of
dev
and notmater
. In the Go repo, we make all the new changes in thedev
branch and only the releases are merged to the main (master
) branch. Thank you! Thanks for letting me know that! I triedgit push
but it always got rejected, so I created a PR to merge dev into this branch because dev is only one commit ahead of this branch.
SendEachForMulticastDryRun
SendEach
,SendEachDryRun
,SendEachForMulticast
,SendEachForMulticastDryRun
SendAll
,SendAllDryRun
,SendMulticast
,SendMulticastDryRun
SendEach
vsSendAll
SendEach
sends one HTTP request to V1 Send endpoint for each message in the array.SendAll
sends only one HTTP request to V1 Batch Send endpoint to send all messages in the array.SendEach
calls fcmClient.Send to send each message and constructs a SendResponse with the returned message id or error.SendEach
uses sync.WaitGroup to execute all fcmClient.Send calls asynchronously and wait for all of them to complete and construct a BatchResponse with all SendResponses. Therefore, unlikeSendAll
,SendEach
does not always returns an error for a total failure. It can also return aBatchResponse
with only errors in it.SendEachForMulticast
callsSendEach
under the hood.Will send the integration tests in another PR.