Installation
Steps:
- The scheduler will be automatically available if the
Include Page |
---|
| _ProfileCaseEngine |
---|
| _ProfileCaseEngine |
---|
|
profile is added to the list of spring active profiles in the bootstrap.properties
. More information on how to configure the application using Spring Profiles can be found here: External application configuration with Spring Profiles. - Add the
application-case-engine.properties
file in the configuration location if it does not yet exist. This properties file is added in the Include Page |
---|
| _ConfigLocation |
---|
| _ConfigLocation |
---|
|
directory when using the Blueriq installer. - Run the provided scripts for creating the quartz tables in the database: msssql.sql, pgsql.sql or oracle.sql. The scripts are located in the release zip in \Runtime\Java\Webapp\DBScripts\blueriq-case-engine-scheduler-quartz
- Define quartz database connection in the
Include Page |
---|
| _PropertiesExternalDatasources |
---|
| _PropertiesExternalDatasources |
---|
|
file.
Info |
---|
Steps 3 and 4 are applicable only if Quartz triggers and jobs are stored in a database instead of in memory. |
Configuration
Info |
---|
Every Quartz configuration property has to be specified in application-case-engine.properties for the Runtime. |
Quartz is configured using a set of properties. Quartz uses a job store in order to persist jobs details, triggers and other job related information. We support two types of job stores:
- Memory (default) for demo's and standalone development
- Database recommended
Memory (default)
Info |
---|
|
This is the default configuration for Java environments. For more details about in memory job store configuration please visit Config RAM Job Store. |
By default memory mode is enabled which should be used only for demos and standalone development. For recommended settings please check the Database section. For memory the following setting should be set in the Include Page |
---|
| _PropertiesCaseEngine |
---|
| _PropertiesCaseEngine |
---|
|
.
Code Block |
---|
title | application-case-engine.properties |
---|
|
spring.quartz.job-store-type = memory |
Database
For database mode, which is required for production, specify the following in Include Page |
---|
| _PropertiesCaseEngine |
---|
| _PropertiesCaseEngine |
---|
|
:
Code Block |
---|
title | application-case-engine.properties |
---|
|
spring.quartz.job-store-type = jdbc
spring.quartz.properties.org.quartz.jobStore.tablePrefix = QRTZ_
# Enable the delegate for the specific database
#spring.quartz.properties.org.quartz.jobStore.driverDelegateClass=org.quartz.impl.jdbcjobstore.MSSQLDelegate
#spring.quartz.properties.org.quartz.jobStore.driverDelegateClass=org.quartz.impl.jdbcjobstore.PostgreSQLDelegate
#spring.quartz.properties.org.quartz.jobStore.driverDelegateClass=org.quartz.impl.jdbcjobstore.oracle.OracleDelegate
# Notewhen thatusing the OracleDelegate is not compatible with the supported Oracle JDBC versions, so don't configure Quartz to use that delegate classa JDBC datasource enable tx
#spring.quartz.properties.org.quartz.jobStore.driverDelegateClass class= org.quartz.impl.jdbcjobstore.MSSQLDelegateJobStoreTX
# when using a JNDI datasource enable CMT
#spring.quartz.properties.org.quartz.jobStore.driverDelegateClass class= org.quartz.impl.jdbcjobstore.PostgreSQLDelegateJobStoreCMT |
JDBCJobStore’s “table prefix” property is a string equal to the prefix given to Quartz’s tables that were created in your database. You can have multiple sets of Quartz’s tables within the same database if they use different table prefixes.
Info |
---|
When changing the org.quartz.jobStore.tablePrefix, please change the SQL create scripts accordingly. |
Include Page |
---|
| _DatasourceConfiguration |
---|
| _DatasourceConfiguration |
---|
|
Info |
---|
The datasource created must be named scheduler-quartz |
Thread Pool
When the database is configured, we recommend to also configure the thread pool. Each DCM project gets its own trigger. It is recommended to have a thread per DCM project. For example if you have 3 DCM projects you should set the threadCount to 3.
Please check that the threadCount does not exceed the number of available database connections (or connections in the database connection pool). The quartz documentation suggests the following: provided that the database allows X connections, then the threadCount must be set to X - 3.
Below are the default thread Pool properties:
Code Block |
---|
language | powershell |
---|
title | application-case-engine.properties |
---|
|
spring.quartz.properties.org.quartz.threadPool.class = org.quartz.simpl.SimpleThreadPool
spring.quartz.properties.org.quartz.threadPool.threadCount = 2 |
Clustering
There are many configuration properties for clustering, see the Quartz documentation. To enable clustering, specify at least these properties:
Code Block |
---|
language | powershell |
---|
title | application-case-engine.properties |
---|
|
spring.quartz.properties.org.quartz.jobStore.isClustered = true
spring.quartz.properties.org.quartz.scheduler.instanceName = MyClusteredScheduler
# Have Quartz generate an instanceId for each node in the cluster
spring.quartz.properties.org.quartz.scheduler.instanceId = AUTO |
Anchor |
---|
| Troubleshooting |
---|
| Troubleshooting |
---|
|
Troubleshooting