RxCookbook icon indicating copy to clipboard operation
RxCookbook copied to clipboard

Create Buffer that doesn't yield empty buffers

Open LeeCampbell opened this issue 9 years ago • 2 comments

As this post requests http://stackoverflow.com/questions/35606136/rx-buffer-without-empty-calls-to-subscriber/35616332#35616332, he would like to have a buffer run at 50ms. However when no values are found during the window, he doesn't want a buffer to be yielded. He could use .Where(buffer=>buffer.Any()) but this doesn't help with the GC pressure he may incur.

Can we build a low allocation version of Buffer?

LeeCampbell avatar Feb 25 '16 01:02 LeeCampbell

I worked with @epsitec on an implementation of this. I should be able to lean on that example. http://share.linqpad.net/ekvedh.linq

LeeCampbell avatar Dec 14 '16 13:12 LeeCampbell

Any updates on this issue?

ivasilyeu avatar Mar 30 '21 17:03 ivasilyeu