O'Reilly logo

C# Multithreaded and Parallel Programming by Rodney Ringler

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Summary

In this chapter, you learned how to change an ordinary LINQ to Objects query into a concurrent PLINQ. You also learned how to order results, merge results, and cancel queries. PLINQ makes it very easy to concurrently process queries on any memory data collection that supports IEnumerable.

It is also important to remember that PLINQ only supports LINQ to Objects and not the other forms of LINQ such as LINQ to SQL or LINQ to XML.

PLINQ is as easy to implement as adding a parallel extension method to a source data collection in a LINQ query—it is really that simple. Then .NET can determine if the query will have better performance running concurrently by partitioning the data collection into pieces, and if so, how to partition it. You as the ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required