Config Issue re: SQL Server Datasource.default.connectionString property?

760 views
Skip to first unread message

GaryG

unread,
Feb 23, 2010, 1:28:13 PM2/23/10
to Quartz.NET
I've been trying to follow the hints in tutorial and examples, and
exploring source, but so far I'm unable to instantiate a scheduler
that's tied to my database.

I think the problem is in datasource.default property, which does not
seem to exist.

My app's config file looks like this:

<quartz>
<add key="quartz.scheduler.instanceName"
value="xxxQuartzJobScheduler" />

<add key="quartz.threadPool.type"
value="Quartz.Simpl.SimpleThreadPool, Quartz" />
<add key="quartz.threadPool.threadCount" value="5" />
<add key="quartz.threadPool.threadPriority" value="1" />

<add key="quartz.jobStore.type"
value="Quartz.Impl.AdoJobStore.JobStoreTX, Quartz" />
<add key="quartz.jobStore.driverDelegateType"
value="Quartz.Impl.AdoJobStore.SqlServerDelegate, Quartz" />
<add key="quartz.jobStore.tablePrefix" value="QuartzJS_" />
<add key="quartz.jobStore.dataSource" value="default" />
<add key="quartz.jobStore.lockHandler.type"
value="Quartz.Impl.AdoJobStore.UpdateLockRowSemaphore, Quartz" />
<add key="quartz.jobStore.dataSource.default.connectionString"
value="Provider=SQLOLEDB.1;Password=xxxxxxx;Persist Security
Info=True;User ID=xxxx;Initial Catalog=xxxxxxx;Data Source=xxxxx
\SQLSERVER2005" />
<add key="quartz.jobStore.dataSource.default.provider"
value="SqlServer-20" />
<add key="quartz.jobStore.misfireThreshold" value="60000" />

</quartz>

And my VB.Net code looks like this:

Private moQuartzSchedulerFactory As Quartz.ISchedulerFactory =
Nothing
Private moQuartzScheduler As Quartz.IScheduler = Nothing

moQuartzSchedulerFactory = New Quartz.Impl.StdSchedulerFactory

moQuartzScheduler = moQuartzSchedulerFactory.GetScheduler()

When the GetScheduler is called, it throws these 3 nested exceptions:

Error: JobStore type 'Quartz.Impl.AdoJobStore.JobStoreTX, Quartz'
props could not be configured.

Error: Could not parse property 'dataSource.default.connectionString'
into correct data type: No property
'DataSource.default.connectionString'

Error: No property 'DataSource.default.connectionString'"


Apparently, my "DataSource" has no "default.connectionString'"
property. But I have no idea how to correct this.

Any ideas? I've been trying various config settings for hours now,
but no joy.

Is there any documentation available for those of us who want to
attach Quartz.Net to a database?

Marko Lahma

unread,
Feb 25, 2010, 12:03:30 PM2/25/10
to quar...@googlegroups.com
Quartz dataSource properties are set with keys beginning with
"quartz.dataSource.default.". So in your case:

<add key="quartz.dataSource.default.connectionString"


value="Provider=SQLOLEDB.1;Password=xxxxxxx;Persist Security
Info=True;User ID=xxxx;Initial Catalog=xxxxxxx;Data Source=xxxxx
\SQLSERVER2005" />

-Marko

> --
> You received this message because you are subscribed to the Google Groups "Quartz.NET" group.
> To post to this group, send email to quar...@googlegroups.com.
> To unsubscribe from this group, send email to quartznet+...@googlegroups.com.
> For more options, visit this group at http://groups.google.com/group/quartznet?hl=en.
>
>

Gary German

unread,
Feb 25, 2010, 3:47:03 PM2/25/10
to quar...@googlegroups.com
Thanks. Using "default" was the key to getting it to work.

I was tripped up by the documentation on Lesson 10 of the tutorial, that
uses "myDS" as the datasource name.

Coding my .config exactly like the example on Lesson 10 will not work,
because "myDS" does not exist, but "defalt" does.

Perhaps the examples on that Tutorial could be changed?

Gary

Marko Lahma

unread,
Feb 26, 2010, 11:54:16 AM2/26/10
to quar...@googlegroups.com
A fair request. Could you open a ticket in JIRA? Glad you got it
working eventually.

-Marko

Reply all
Reply to author
Forward
0 new messages