Questions tagged [parallel-extensions]

Parallel Extensions is a managed concurrency library included in the .NET 4.0 release.

Parallel Extensions is a managed concurrency library included in the .NET 4.0 release. It is composed of two parts: Parallel LINQ (PLINQ) and Task Parallel Library (TPL).

124 questions
0
votes
1 answer

c# parallelize simulation

I have a simulation engine that I would like to parallelize first and later develop as a web service in C#. This is an intensive simulation that requires a lot of CPU and RAM and I would like to split each run on a separate thread. To give you a…
Dimitris
  • 2,030
  • 3
  • 27
  • 45
0
votes
2 answers

Concurrent acess to EF4 entities (Parallel + EF4)

I'm currently working in a dispatcher service that processes thousands of messages delivered in different channels (email, private message, application message) using EF4 and WCF. To try to speed up message dispatching i'm trying to use…
0
votes
1 answer

How to prioritize nested tasks using a QueuedTaskScheduler?

I'm using the QueuedTaskScheduler from ParallelExtensionsExtras to schedule tasks T, A and B. The QueuedTaskScheduler is set to use only 1 thread. Tasks A and B just sleep for 2000 ms. Task T starts A and B. I'm using two queues: q1 (priority 1) and…
0
votes
2 answers

Can Parallel.ForEach be used safely with CloudTableQuery

I have a reasonable number of records in an Azure Table that I'm attempting to do some one time data encryption on. I thought that I could speed things up by using a Parallel.ForEach. Also because there are more than 1K records and I don't want to…
knightpfhor
  • 9,299
  • 3
  • 29
  • 42
0
votes
1 answer

Is it possible to use Deedle's methods "as parallel"?

Something PLINQ style, for example: var myTimeSeries = from kvp in myOtherTimeSeries.AsParallel() where kvp //etc.
0
votes
3 answers

Why is LazyInit restricted to reference types

I have a pseudo-realtime data processing application where I would like to use LazyInit so I don't do calculations I don't need, but LazyInit restricts T to classes. I can work around it, but I'd obviously prefer not to. Does anybody…
Jon Norton
  • 2,969
  • 21
  • 20
0
votes
1 answer

Creating extensions for Pipeline from Parallel Extensions Extras

I truly enjoy working with Parallel Extensions Extras, but must admit, still find myself challenged when it comes to creating extensions for Fluent programming methods. I have a particular need, given this simple BusinessEntity following the Null…
Darek
  • 4,687
  • 31
  • 47
0
votes
2 answers

Parallel.For Loop with Thread-Local Variables

I have a C# ASP.NET MVC project. I am basically running a simulation (with an option to cancel) and collating the results. I need to use multi-threading as I could run a million or more simulations at at time. My code is like this: public class…
Th4t Guy
  • 1,442
  • 3
  • 16
  • 28
0
votes
1 answer

Adding extension method to ParallelQuery

I built a concurrent list class that implements the interfaces IEnumerator and IEnumerable. My goal is to be able to write: IEnumrable MyConcurrentList1 = new…
Stav Alfi
  • 13,139
  • 23
  • 99
  • 171
0
votes
1 answer

Is it possible to parallelize an Iterator that uses Yield?

Consider this code, which extends the Array .NET type : Public Module ArrayExtensions Public Iterator Function ToEnumerable(Of T)(target As Array) As IEnumerable(Of T) For Each item In…
Rob Perkins
  • 3,088
  • 1
  • 30
  • 51
0
votes
1 answer

How can I get parallel extensions to run a function that has two input parameters?

I've tried really hard to get this to work and have had no luck. How can I get parallel extensions to run a function that has two input parameters? I'm using the more recent version, the Reactive Extensions with the 3.5 framework. I need to get…
Middletone
  • 4,190
  • 12
  • 53
  • 74
0
votes
1 answer

how to implement async method using Task Parallel Library for I/O operations

I found that for expensive IO bound operation I can use TaskCompletionSource as shown here http://msdn.microsoft.com/en-us/library/hh873177.aspx#workloads But the example shown is only waiting for some time and return DateTime. public static…
0
votes
1 answer

Excel in parallel

I have a program that inserts data in excel and creates graphs. All the "number operations" are done in the program (with linq), so excel is only used for creating graphs. The final excel has around 300 worksheets (50 sheet with data and 250…
Alberto
  • 704
  • 2
  • 12
  • 26
0
votes
2 answers

Load a List More Efficiently

i have been tasked with updating some legacy code and really need to decrease the run time on part of it. The below list is loaded quite often. I have managed to reduce the time from about a minute to around fifteen seconds, but it really needs to…
Opus Krokus
  • 241
  • 1
  • 2
  • 3
0
votes
1 answer

How to achieve equivalent using TPL/TAP?

Below I have a fairly simple .NET console app consuming an Azure Service Bus Queue. As you'll see, I am using Task.Factory to fire up 25 receiver tasks that then call my APM-style BeginMessageReceive method. Then, at the end of EndMessageReceive, I…
anderly
  • 727
  • 7
  • 16
1 2 3
8
9