These are chat archives for akkadotnet/AkkaStreams

10th
Jul 2018
fromano2802
@fromano2802
Jul 10 2018 14:47
@Horusiath thank you. Can you point me to any example?
Bartosz Sypytkowski
@Horusiath
Jul 10 2018 17:57
@fromano2802 it really depends on what you want to achieve - graph stages are usually an option after you get familiar with like 140 of existing akka streams operators and decide that your needs are too custom to be solved with them ;)
fromano2802
@fromano2802
Jul 10 2018 19:36
@Horusiath I just want to achieve the same goal of your BatchingPublisher. I have an API that is producing several thousand records and I want to retrieve them in batches. If network or other issues arise, i want to be able to apply backpressure.
Bartosz Sypytkowski
@Horusiath
Jul 10 2018 19:55
@fromano2802 this can be done on several ways, one of them is GroupedWithin - it takes two params: a max size of a batch and a timeout. It will start batching incoming elements and pass them in a single collection downstream if either batch size have been reached or a timeout occurred - whatever happens first
fromano2802
@fromano2802
Jul 10 2018 19:56
@Horusiath Thank you again. I'll give it a try