R
Randolph Neall
In VS 2005 do multiple threads and multiple writers impair a hashtable to
the extent that an actual exception would be thrown? Or, on the contrary, do
you simply get a badly-written hashtable? We are trying to track down why a
C# windows service program we've written exits--we're assuming because of an
uncaught exception somewhere. We do have some cases in this program where
we've not synchronized hashtable access, and wondered whether this would be
a candidate explanation for a windows service that dies and disappears.
More generally, does one get an exception when multiple threads hit a
non-thread-safe object, or does one rather simply get inconsistent values
within that object, with no exceptions thrown? We are aware of exceptions
that happen when two uninvoked threads hit a windows form-related object,
but what about non-form objects, such as hashtables or objects we might have
written, or objects containing static methods?
Thanks,
Randy Neall
the extent that an actual exception would be thrown? Or, on the contrary, do
you simply get a badly-written hashtable? We are trying to track down why a
C# windows service program we've written exits--we're assuming because of an
uncaught exception somewhere. We do have some cases in this program where
we've not synchronized hashtable access, and wondered whether this would be
a candidate explanation for a windows service that dies and disappears.
More generally, does one get an exception when multiple threads hit a
non-thread-safe object, or does one rather simply get inconsistent values
within that object, with no exceptions thrown? We are aware of exceptions
that happen when two uninvoked threads hit a windows form-related object,
but what about non-form objects, such as hashtables or objects we might have
written, or objects containing static methods?
Thanks,
Randy Neall