public class QuartzApplication {
private static final Log LOG = LogFactory.getLog(QuartzApplication.class);
/**
* @param args
*/
@SuppressWarnings("resource")
public static void main(String[] args)
{
LOG.info("ApplicationContext init...");
new ClassPathXmlApplicationContext("classpath*:applicationContext-quartz.xml");
LOG.info("ApplicationContext load complete.");
// 防止进程退出
synchronized (QuartzApplication.class) {
try {
QuartzApplication.class.wait();
} catch (InterruptedException e) {
LOG.error(e.getMessage(),e);
}
}
}
}