The Task Parallel Library Sampler – Part 13: Async/Await

Previous Post in this series:Part 12: Cancelling Threads with the CancellationTokenSource – The Code This sample derives from a Microsoft example and an updated solution is available here. AsyncAwaitSample model: There are two runs here, one shown using the keyword “await” with an asyncronous method and another run just running an asyncronous method without using […]

.

Read more

The Task Parallel Library Sampler – Part 12: Cancelling Threads with the CancellationTokenSource – The Code

Previous Post in this series:Part 11: Cancelling Threads with the CancellationTokenSource – The MVVM So now that we’ve covered the MVVM, which you saw was pretty trivial to implement, let’s cover the actual sample. CancellationSample.Run We start by instantiating the CancellationTokenSource that holds our token. We have to do this for each run or else […]

.

Read more

The Task Parallel Library Sampler – Part 9: Basic Exception handling with the AggregateException

Previous Post in this series:Part 8: Adding a New Sample, Matrices Multiplication In the updated solution you’ll find two new models, AggregateExceptionNoCatchSample and AggregateExceptionCatchSample. The TPL provides a convienient exception handling mechanism in the form of an AggregateException. If you run through a Parallel.For or .ForEach and an exception is thrown in one of the […]

.

Read more

The Task Parallel Library Sampler – Part 7: Using Parallel.For effectively

Part One: Starting with MVVMPart Two: The MVVM solution structure and basic frameworkPart Three: Base ClassesPart 4: Sampler View, View Model and ModelPart 5: Running and working with the TPL samplesPart 6: Parallel.For Sample In the last post we discussed where using a Parallel.For isn’t effective. The answer is fairly straightforward, Parallel.For (and by extension […]

.

Read more

The Task Parallel Library Sampler – Part 6: Parallel.For Sample

Part One: Starting with MVVMPart Two: The MVVM solution structure and basic frameworkPart Three: Base ClassesPart 4: Sampler View, View Model and ModelPart 5: Running and working with the TPL samples In the solution directory Models, you will find the LineSample and LineParallelSample models. These are fairly straight forward samples. LineSample.Run() We start a stop […]

.

Read more

The Task Parallel Library Sampler – Part 4: Sampler View, View Model and Model

Part One: Starting with MVVMPart Two: The MVVM solution structure and basic frameworkPart Three: Base Classes I want to go over the main view (SamplerView), view model (SamplerViewModel) and model (Sampler) classes next. I’ve gone over the ItemsControl that populates the TPL samples but I wanted to cover the other MVVM aspects as well as […]

.

Read more
FormatException

928 East Plymouth Drive Asbury Park, NJ 07712