docs/_posts/2020-07-24-quartznet-3.1-released.md
This release concentrates on performance and bringing support for standard integrations.
Quartz 3.1 supports netstandard2.0 and net461 targets (for integrations they may be different).
[[toc]]
New NuGet packages ASP.NET Core Integration and Quartz.Extensions.DependencyInjection finally bring built-in support for integrating Quartz.NET with reliable manner with the Microsoft DI container and hosted services infrastructure.
The best resource the see the new DI integration in progress is to head to the example ASP.NET Core application.
I would like to thank both Facundo Glaeser and Lewis Zou for working with the new integration packages and their logistics.
New experimental NuGet package Quartz.OpenTelemetry.Instrumentation brings support for emerging OpenTelemetry standard.
First version of integration is able transmit job execution (Started, Ended, Exception) information to exporters. With this infrastructure is should also be easier to implement job history
using battle-tested log backends for storing data. The example ASP.NET Core application integrates
with Jaeger and transmits this data.
A big change on the persistent store side is that now SQL queries use parametrized scheduler name, which allows database server to reuse query plans and use indexes more optimally. This will help especially clusters which have large number of nodes. The SQL server indexes were also revisited and their amount reduced by using smarter covering indexes.
See the updated create index definition for more details.
::: tip You need to re-run the index script to take advantage of changes, this will drop old indexes and rebuild/create new ones, it can be time-consuming! :::
There is also a very important bug fix present for lock handling on retries. There was a possibility for a deadlock in cluster's database lock handling in some situations.
Quartz now uses Microsoft.Data.SqlClient as the connection library for SQL Server as it's the one going to get new features. It is dependency for Quartz library (for now) so you shouldn't need to do any manual install steps.
You need to use the latest MySqlConnector 1.0.0 in order to use with default Quartz configuration. As the namespace for library has changed it's not backwards compatible. If you need to use the old version, you should manually register DB provider with the old details.
No known issues. Documentation might require additions and community contributions are welcomed. Edits should be easy now with the new publishing framework.
BREAKING CHANGES
Quartz.Impl.AdoJobStore.JobStoreSupport (see also #818). Affected are only schedulers that use customized configurations of SQL commands in Quartz.Impl.AdoJobStore.JobStoreSupport, e.g. SelectWithLockSQL. Migration example:<!-- Quartz <=3.0.7 -->
<item key="quartz.jobStore.selectWithLockSQL">SELECT * FROM {0}LOCKS WITH (UPDLOCK,ROWLOCK) WHERE SCHED_NAME = {1} AND LOCK_NAME = @lockName</item>
<!-- Quartz >=3.1.0 -->
<item key="quartz.jobStore.selectWithLockSQL">SELECT * FROM {0}LOCKS WITH (UPDLOCK,ROWLOCK) WHERE SCHED_NAME = @schedulerName AND LOCK_NAME = @lockName</item>
NEW FEATURE
ClusterCheckinMisfireThreshold (#692)FIXES