org.openbp.config.scheduler.QuartzProcessSchedulerConfig Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of openbp-server Show documentation
Show all versions of openbp-server Show documentation
The OpenBP process engine (main module)
package org.openbp.config.scheduler;
import org.openbp.server.scheduler.ProcessScheduler;
import org.openbp.server.scheduler.QuartzProcessScheduler;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
/**
* Spring configuration providing the as Quartz scheduler component.
*/
@Configuration
public class QuartzProcessSchedulerConfig
{
/** Classpath name of the scheduler's properties resource or null */
private String propertiesResourceName = "OpenBP-Quartz.properties";
@Bean
public ProcessScheduler processScheduler()
{
QuartzProcessScheduler scheduler = new QuartzProcessScheduler();
scheduler.setPropertiesResourceName(propertiesResourceName);
return scheduler;
}
/**
* Sets the classpath name of the scheduler's properties resource.
* @param propertiesResourceName Resource name or null (default: "OpenBP-Quartz.properties")
*/
public void setPropertiesResourceName(String propertiesResourceName)
{
this.propertiesResourceName = propertiesResourceName;
}
}