RQ: QueueManager.Recieve throwing ArgumentOutOfRangeException

10 views
Skip to first unread message

Jason Meckley

unread,
Oct 9, 2009, 2:40:12 PM10/9/09
to Rhino Tools Dev
System.ArgumentOutOfRangeException: Number must be either non-negative
and less than or equal to Int32.MaxValue or -1.
Parameter name: timeout
at System.Threading.Monitor.Wait(Object obj, TimeSpan timeout)
at Rhino.Queues.QueueManager.Receive(String queueName, String
subqueue, TimeSpan timeout) in QueueManager.cs: line 369
at Rhino.Queues.QueueManager.Receive(String queueName, TimeSpan
timeout) in QueueManager.cs: line 343
at Rhino.ServiceBus.RhinoQueues.RhinoQueuesTransport.ReceiveMessage()
in ....\Rhino.ServiceBus\RhinoQueues\RhinoQueuesTransport.cs: line 153
at System.Threading.ThreadHelper.ThreadStart_Context(Object state)
at System.Threading.ExecutionContext.Run(ExecutionContext
executionContext, ContextCallback callback, Object state)
at System.Threading.ThreadHelper.ThreadStart()

This happens, inconsistantly, in our production environment. I cannot
reproduce this in a test environment though. reviewing the
QueueManager.Recieve member it would seem the error occurs because as
some point line 331
(remaining = remaining - sp.Elapsed;) makes remaining negative.

At which point the system crashes, and the error is recorded to the
event log. Once I find out the service stopped. I log on, restart the
service, and the messages filter through.

Any ideas on what may be causing negative time?

the

Vadim Kantorov

unread,
Oct 11, 2009, 3:31:07 AM10/11/09
to Rhino Tools Dev
Happened to me many times during debugging. Also inconsistent
behavior.

Ayende Rahien

unread,
Oct 21, 2009, 7:35:58 AM10/21/09
to rhino-t...@googlegroups.com
Yes,
It happens when the duration takes too long. It is probably only a very small amount, but it can happen.
I fixed this locally and will push it up shortly.
Reply all
Reply to author
Forward
0 new messages