Skip to main content
3 votes
2 answers
97 views

Immutability and side effects with dataflow TransformBlocks

I'm currently reading about TPL dataflow pipelines and there's something I'm curious about when it comes to TransformBlocks. As I understand it, TransformBlock<TInput, TOutput> accepts an input ...
lightning_missile's user avatar
0 votes
0 answers
58 views

Parallelizing the database Write operations

I wanted to improve my upload time efficiency by using TPL Dataflow. I receive files with multiple rows. I parse and upload them into the database. I have two Dataflow blocks: Receive & parse file ...
Mihai Socaciu's user avatar
0 votes
1 answer
74 views

Dataflow thread safe db context

My app receives multiple files (50 files, each file with 1000 rows) and processes them in Dataflow blocks. In one of the blocks UploadToDatabaseBlock, I set MaxDegreeOfParalellism to 8. This creates ...
Mihai Socaciu's user avatar
0 votes
1 answer
26 views

How to preload all the files in a TPL DataFlow pipeline between two TranformBlocks before processing their content?

I have a TPL DataFlow pipeline that parses msbuild project files in order to obtain the location of the respective binary and then processes these binaries. Here is how it looks like: var linkOptions =...
mark's user avatar
  • 63k
1 vote
0 answers
52 views

Why does AsObservable used with BroadCastBlock not get all values

I was experimenting with having a BroadcastBlock also broadcast to observers. However I found that it doesn't quite work the way I'd expect. This is an example which demonstrates the difference ...
Ivan Petrov's user avatar
  • 5,632
1 vote
1 answer
95 views

"BatchBlock" does not work properly in non-greedy mode

When I use greedy mode, everything works as expected. But when I enable non-greedy mode, аt the moment of executing "foo.Receive()", the thread hangs while waiting. BatchBlock<int> foo ...
Tim Kuk's user avatar
  • 21
1 vote
0 answers
60 views

Join block not invoked although the two calling blocks exited successfully

I have 2 transform blocks that are joined into a join block but I sometimes have an issue where both transform blocks finish successfully and the join block is not invoked. Relevant code snippet and ...
FMK's user avatar
  • 11
0 votes
1 answer
32 views

Why is TPL Post response different in Bounded BroadcastBlock and BufferBlock?

I expected that result1 in the last assertion equal false on BroadcastBlock as on BufferedBlock, but it is not the case. I'm using latest System.Threading.Tasks.Dataflow version 8.0.1 var ...
Chris's user avatar
  • 1,139
0 votes
0 answers
60 views

TPL Dataflow WPF - Block is getting hosed up while await for Task to complete - .NET Framework 4.8

I am writing a File Transfer Pipeline using TPL library. I am new to this types of implementation so my issue could be related to something I am not aware of. Part of my application allows users to ...
Jean's user avatar
  • 47
1 vote
2 answers
186 views

How to produce multiple outputs in TPL Dataflow block before completion

I have this case where I am trying to build a pipeline using TPL Dataflow that could process a big number of items. At some point in the pipeline I need to batch items and send to the next block after ...
Arturio's user avatar
  • 466
1 vote
0 answers
84 views

TPL Dataflow: Running a pipeline *while impersonated* leaks millions of handles

My Winforms app was consistently crashing to desktop on a large TPL Dataflow pipeline operation. This wasn't caught by the normal try/catch. Only when I put a try/catch at the outermost Program.cs/...
amonroejj's user avatar
  • 645
0 votes
1 answer
75 views

C# .NET Core Dataflow Pattern Unit Test does not wait for action to complete

There is a .NET Core Worker Service that has Dataflow pattern used to do the parallel process. It has TransformBlock and ActionBlock. While running the Worker process both TransformBlock and ...
user3497702's user avatar
0 votes
1 answer
743 views

Parallel.ForEach vs ActionBlock [closed]

For a given MaxDegreeOfParallelism and fixed amount of objects that need to be processed (i.e. have certain code executed on them) it would seem Parallel.ForEach and an ActionBlock would be equally ...
Inbox's user avatar
  • 111
0 votes
2 answers
117 views

TPL ActionBlock not handling messages after an exception

I've setup an ActionBlock<T> like so: private readonly ActionBlock<PresentationListNotification> _actionBlock; ... _actionBlock = new ActionBlock<...
auburg's user avatar
  • 1,485
1 vote
1 answer
45 views

Completion is not being propagated between dataflow blocks

I am studying Dataflow basics. Here is a code sample which looks correct to me but does not work. Instead of returning result integer value it freezes. In my understanding it is because completing is ...
walruz's user avatar
  • 1,329

15 30 50 per page
1
2 3 4 5
43