RobotsAndPencils / buford

A push notification delivery engine for the new HTTP/2 APNS service.
MIT License
475 stars 52 forks source link

calling code needs to ensure all responses are handled (not just received) #75

Closed nathany closed 8 years ago

nathany commented 8 years ago

ref #74

Some considerations: If the calling code is adding a WaitGroup, does it still make sense to keep the internal one? The internal wait group does ensure that all notifications are sent before closing the responses channel -- so that is useful.

Another option for the calling code is to use an unbuffered done channel to signal that all responses are processed. That's a little simpler and doesn't require the sync package for the caller.