solve using TPL. I have (currently, I say this because I can still change it) a ConcurrentQueue of items, where items will get added. then I would like to dequeue these items in prallel and handle them, since this handling takes a lot more time than adding new entries. What could I use for this?
Atm I have a custom implementation that just creates new tasks and adds a max of 5 running at the same time. I'd like to think that I can improve performance by not doing this manually but using in built framework funcionality
consider using Channels ? (in async world, rather than TPL)
Thanks for the input I will take a look! I also just read about producer/consumer pattern: https://markheath.net/post/producer-consumer-pattern-tpl Which kind of sounds like what I want to do but Im unsure?
Обсуждают сегодня