C# .NET - Producer/Consumer Queue and BlockingCollection in C# 4.0 - application throws exception

Asked By Madhavan Thasu Ramachandran on 17-Jun-14 11:08 AM
Hi Team,

I have downloaded the code and tried with "object" for may class in task creation. I am getting memory out of exception 

public ProducerConsumerQueue(int workerCount, object[] states)
        {
            // Create and start a separate Task for each consumer:
            for (int i = 0; i < workerCount; i++)
                Task.Factory.StartNew(Consume, states[i], TaskCreationOptions.LongRunning); // Exception thrown here
        }


Any update on this project to handle memory out of exception?