Skip to content

Commit 2600e87

Browse files
timotheeandreswilkinsona
authored andcommitted
Warn about limitations of Quartz's schema scripts
See gh-43955 Signed-off-by: Timothée Andres <[email protected]>
1 parent 71c9643 commit 2600e87

File tree

1 file changed

+3
-0
lines changed
  • spring-boot-project/spring-boot-docs/src/docs/antora/modules/reference/pages/io

1 file changed

+3
-0
lines changed

spring-boot-project/spring-boot-docs/src/docs/antora/modules/reference/pages/io/quartz.adoc

+3
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,9 @@ WARNING: By default, the database is detected and initialized by using the stand
3535
These scripts drop existing tables, deleting all triggers on every restart.
3636
It is also possible to provide a custom script by setting the configprop:spring.quartz.jdbc.schema[] property.
3737

38+
WARNING: SQL Server and Azure SQL databases may not use this mechanism because the script requires the specification of the database name directly.
39+
Make a copy of the script and edit it, before using configprop:spring.quartz.jdbc.schema[] to direct Spring to use it.
40+
3841
To have Quartz use a javadoc:javax.sql.DataSource[] other than the application's main javadoc:javax.sql.DataSource[], declare a javadoc:javax.sql.DataSource[] bean, annotating its javadoc:org.springframework.context.annotation.Bean[format=annotation] method with javadoc:org.springframework.boot.autoconfigure.quartz.QuartzDataSource[format=annotation].
3942
Doing so ensures that the Quartz-specific javadoc:javax.sql.DataSource[] is used by both the javadoc:org.springframework.scheduling.quartz.SchedulerFactoryBean[] and for schema initialization.
4043
Similarly, to have Quartz use a javadoc:org.springframework.transaction.TransactionManager[] other than the application's main javadoc:org.springframework.transaction.TransactionManager[] declare a javadoc:org.springframework.transaction.TransactionManager[] bean, annotating its javadoc:org.springframework.context.annotation.Bean[format=annotation] method with javadoc:org.springframework.boot.autoconfigure.quartz.QuartzTransactionManager[format=annotation].

0 commit comments

Comments
 (0)