Package longpoll supports batching e.g. receiving as many values as possible from a channel.
See the docs for example usage.
See also github.com/joeycumines/go-microbatch, for a higher-level implementation, with built-in concurrency control, and support for batched request/response patterns.