嘗試在System.Data.Sqlite.Core(1.0.105.2)上使用帶有Quartz scheduler 3.0.0-alpha3的Sqlite,並使用以下配置.NET 2.0核心控制檯應用程序編譯在我的Mac OSX的Visual Studio:使用Quartz.net 3.x和Sqlite 3.0的.NET Core 2.0控制檯應用程序
NameValueCollection props = new NameValueCollection {
{ "quartz.threadPool.type", "Quartz.Simpl.SimpleThreadPool, Quartz" },
{ "quartz.threadPool.threadCount", "10" },
{ "quartz.jobStore.type", "Quartz.Impl.AdoJobStore.JobStoreTX, Quartz" },
{ "quartz.jobStore.misfireThreshold", "60000" },
{ "quartz.jobStore.lockHandler.type", "Quartz.Impl.AdoJobStore.UpdateLockRowSemaphore, Quartz" },
{ "quartz.jobStore.useProperties", "true" },
{ "quartz.jobStore.dataSource", "default" },
{ "quartz.jobStore.tablePrefix", "QRTZ_" },
{ "quartz.jobStore.driverDelegateType", "Quartz.Impl.AdoJobStore.SQLiteDelegate, Quartz" },
{ "quartz.dataSource.default.provider", "SQLite-10" },
{ "quartz.dataSource.default.connectionString", "Data Source=quartznet.db;Version=3;" }
};
實際行爲
Quartz.SchedulerException:無法初始化數據源:SqliteDS ---> System.ArgumentOutOfRangeException:沒有元數據信息n提供者'SQLite-10'參數名稱:providerName
at Quartz.Impl.AdoJobStore.Common.DbProvider.GetDbMetadata(String providerName)in C:\ projects \ quartznet-6fcn8 \ src \ Quartz \ Impl \ AdoJobStore \ Common \ DbProvider.cs:line 118 at C:\ projects \ quartznet-6fcn8 \ src \ Quartz \ Impl \ AdoJobStore \ Common \ DbProvider中Quartz.Impl.AdoJobStore.Common.DbProvider..ctor(String dbProviderName,String connectionString) .cs:line 74 at Quartz.Impl.StdSchedulerFactory.d__65.MoveNext()in C:\ projects \ quartznet-6fcn8 \ src \ Quartz \ Impl \ StdSchedulerFactory.cs:line 614 ---內部異常堆棧跟蹤結束--- at Quartz.Impl.StdSchedulerFactory.d__65.MoveNext()in C:\ projects \ quartznet-6fcn8 \ src \ Quartz \ Impl \ StdSchedulerFactory.cs:line 623 - - 從拋出異常的上一個位置結束堆棧跟蹤---在Quartz.Impl的System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw() at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(任務任務) 處的 。 StdSchedulerFactory.d__69.MoveNext()在C:\ projects \ quartznet-6fcn8 \ src \ Quartz \ Impl \ StdSchedulerFactory.cs中:第1118行 ---從之前位置拋出異常的堆棧跟蹤結束--- at System .Runtime.ExceptionServices.ExceptionDispatchInfo.Throw() 在System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(任務task) 在System.Runtime.CompilerServices.TaskAwaiter`1.GetResult() 在BackgroundProcessingWithQuartz.Program.d__1.MoveNext( )in/Users/ja kesmith/Projects/BackgroundProcessingWithQuartz/BackgroundProcessingWithQuartz/BackgroundProcessingWithQuartz/Program.cs:line 44 [請參閱嵌套異常:System.ArgumentOutOfRangeException:沒有提供程序'SQLite-10'的元數據信息 參數名稱:providerName at Quartz.Impl.AdoJobStore。 C:\ projects \ quartznet-6fcn8 \ src \ Quartz \ Impl \ AdoJobStore \ Common \ DbProvider.cs中的Common.DbProvider.GetDbMetadata(String providerName):第118行 at Quartz.Impl.AdoJobStore.Common.DbProvider..ctor字符串dbProviderName,字符串connectionString)在C:\ projects \ quartznet-6fcn8 \ src \ Quartz \ Impl \ AdoJobStore \ Common \ DbProvider.cs中:第74行 at Quartz.Impl.StdSchedulerFactory.d__65.MoveNext()in C:\ projects \ quartznet-6fcn8 \ src \ Quartz \ Impl \ StdSchedulerFactory.cs:line 614
我缺少什麼?一切都通過我的Visual Studio for Mac上的NuGet安裝。另外,爲什麼當dll實際上在Mac上運行時,有C盤的引用。請幫忙。