Skip to content

Feature #9290 #2

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jan 16, 2018
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
30 changes: 30 additions & 0 deletions src/main/dist/configuration/silverpeas/01-schedulerSettings.groovy
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
/**
* This script configures the JDBC dialect to use by the Quartz scheduler when persisting the
* jobs and the triggers into a JDBC store.
* @author mmoquillon
*/

log.info 'Configure the JDBC driver delegate for the Persistent Quartz Scheduler'

String driverDelegateClass
switch (settings.DB_SERVERTYPE) {
case 'POSTGRESQL':
driverDelegateClass = 'org.quartz.impl.jdbcjobstore.PostgreSQLDelegate'
break
case 'MSSQL':
driverDelegateClass = 'org.quartz.impl.jdbcjobstore.MSSQLDelegate'
break
case 'ORACLE':
driverDelegateClass = 'org.quartz.impl.jdbcjobstore.oracle.OracleDelegate'
break
default:
driverDelegateClass = 'org.quartz.impl.jdbcjobstore.StdJDBCDelegate'
break
}

def properties = ['org.quartz.jobStore.driverDelegateClass': driverDelegateClass]

service.updateProperties(
"${settings.SILVERPEAS_HOME}/properties/org/silverpeas/scheduler/settings/persistent-scheduler.properties",
properties)