1

I can't seem to find any documentation regarding thread safety...

In particular - is the Database class (and subclasses) thread safe

How would I find this out for myself? Are there references to thread safety for classes on the MSDN site?

Ben Lings
  • 28,823
  • 13
  • 72
  • 81
Ed Vowles
  • 67
  • 5

1 Answers1

1

Yes, instances of the Database class are thread-safe. However, objects created by it (such as SqlDataReader) are not.

Steven
  • 166,672
  • 24
  • 332
  • 435
  • How would I go about making the objects created by the Database class thread safe? For instance, if I use the database class to create the command object (GetSqlStringCommand) how do I ensure thread safety on this object? – ptn77 Oct 19 '16 at 15:43