TransactionScope limitations (link) in the EF Core

EF Core 2.1 from the start to support the use of TransactionScope, but using TransactionScope in EF Core is there are some limitations, because .NET Core Framework is a cross-operating system platform, but there are some TransactionScope feature is only supported on Windows systems not supported on Linux systems, such as: distributed transaction coordinator (distributed transaction coordinator) exists only on a Windows system, so use TransactionScope in EF Core, we must not start a distributed transaction, or whether you code under Windows, or on Linux systems, will throw an exception:

System.PlatformNotSupportedException: This platform does not support distributed transactions.

For more details, see: the Entity Framework Core - TransactionScope with the Use Caution!

 

Guess you like

Origin www.cnblogs.com/OpenCoder/p/12482229.html