Upgrading from SQL Server transport version 5 to version 6 is a major upgrade and requires careful planning. Read the entire guide before beginning the upgrade process.
The minimum .NET Framework version for version 6 is .NET Framework 4.6.1.
All projects must be updated to .NET Framework 4.6.1 before upgrading to SQL Server Transport version 6.
It is recommended to update to .NET Framework 4.6.1 and perform a full migration to production before updating to version 6. This will isolate any issues that may occur.
For solutions with many projects, the Target Framework Migrator Visual Studio extension can reduce the manual effort required in performing an upgrade.
The transport is now compatible with both
Microsoft.. The existing NServiceBus.SqlServer package references
System., and it is the package that should be used when compatibility with
System. is required. The new NServiceBus.Transport.SqlServer package references
Microsoft., and this is the recommended package for new projects, or if compatibility with
Microsoft. is required in an existing project.
System.is in maintenance mode. Microsoft will bring new features and improvements to
Microsoft.only. For more information, read Introduction to the new Microsoft.Data.SqlClient. It is recommended to switch to the new client if possible.
Certain advanced configuration APIs have been moved from the namespace
NServiceBus. (note the change in case). Code must to be adjusted accordingly. A straight forward way is to search and replace
In SQL Server Transport version 6, the timeout manager compatibility mode is disabled by default.
DisableTimeoutManagerCompatibility API has been deprecated:
var delayedDelivery = transport.NativeDelayedDelivery(); delayedDelivery.DisableTimeoutManagerCompatibility();
To enable the timeout manager compatibility mode use:
var transport = endpointConfiguration.UseTransport<SqlServerTransport>(); var delayedDelivery = transport.NativeDelayedDelivery(); delayedDelivery.EnableTimeoutManagerCompatibility();
Regardless of the client used, the transport is compatible with NServiceBus.Persistence.Sql. It is recommended to use the same client in the transport as well as the persister. When migrating from
Microsoft., the transport and the persister can operate in mixed mode as long as the transport transaction mode is either
SendsWithAtomicReceive. If the transport operates with transport transaction mode,
TransactionScope, using both clients will lead to DTC escalation in all cases, which might not be the desired behavior.