Link to home
Start Free TrialLog in
Avatar of basil365
basil365Flag for Ireland

asked on

Concurrent queue exception

Hi,

I recently changed a live application to .net 4 in order to use concurrentDictionary's and queues. I received the following error:
at System.Collections.Concurrent.ConcurrentQueue`1.GetHeadTailPositions(Segment& head, Segment& tail, Int32& headLow, Int32& tailHigh) at System.Collections.Concurrent.ConcurrentQueue`1.get_Count() at [i]MY METHOD[/i]

Open in new window


This is quite a complex app with several threads accessing the objects simulataneously, can anybody help geive me an insight into what condition would raise this error?

Thanks
Avatar of Naman Goel
Naman Goel
Flag of India image

can you give more details stack trace of exception, method/thread causing exception
Avatar of basil365

ASKER

Sorry, thats the only exception i received this time. I have since removed the queue.count call as i assume its not needed because i then use the 'tryDequeue()' method and base further logic on the bool result (instead of using the count to decide if i should continue)
yes, for that exception only I need complete Call Stack trace with Exception message, error code.

Method call causing that exception.
Without the exception name and message included, it is kind of hard to address your question.
ASKER CERTIFIED SOLUTION
Avatar of basil365
basil365
Flag of Ireland image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial