Managing EntityConnection lifetime

后端 未结 2 598
北恋
北恋 2020-12-10 16:32

There have been many question on managing EntityContext lifetime,

e.g. Instantiating a context in LINQ to Entities

I\'ve come to the conclusion tha

2条回答
  •  一整个雨季
    2020-12-10 17:16

    EntityConnection is documented to be not thread-safe. I think you could pool them, but you cannot use a single, static connection for a Web application, as there will be many threads involved.

提交回复
热议问题