org.quartz.xml.XMLSchedulingDataProcessor.addJobGroupToNeverDelete()方法的使用及代码示例

x33g5p2x  于2022-02-03 转载在 其他  
字(1.7k)|赞(0)|评价(0)|浏览(169)

本文整理了Java中org.quartz.xml.XMLSchedulingDataProcessor.addJobGroupToNeverDelete()方法的一些代码示例,展示了XMLSchedulingDataProcessor.addJobGroupToNeverDelete()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。XMLSchedulingDataProcessor.addJobGroupToNeverDelete()方法的具体详情如下:
包路径:org.quartz.xml.XMLSchedulingDataProcessor
类名称:XMLSchedulingDataProcessor
方法名:addJobGroupToNeverDelete

XMLSchedulingDataProcessor.addJobGroupToNeverDelete介绍

[英]Add the given group to the list of job groups that will never be deleted by this processor, even if a pre-processing-command to delete the group is encountered.
[中]将给定组添加到此处理程序永远不会删除的作业组列表中,即使遇到删除该组的预处理命令。

代码示例

代码示例来源:origin: quartz-scheduler/quartz

private void processFile(JobFile jobFile) {
  if (jobFile == null || !jobFile.getFileFound()) {
    return;
  }
  try {
    XMLSchedulingDataProcessor processor = 
      new XMLSchedulingDataProcessor(this.classLoadHelper);
    
    processor.addJobGroupToNeverDelete(JOB_INITIALIZATION_PLUGIN_NAME);
    processor.addTriggerGroupToNeverDelete(JOB_INITIALIZATION_PLUGIN_NAME);
    
    processor.processFileAndScheduleJobs(
        jobFile.getFileName(), 
        jobFile.getFileName(), // systemId 
        getScheduler());
  } catch (Exception e) {
    getLog().error("Error scheduling jobs: " + e.getMessage(), e);
  }
}

代码示例来源:origin: quartz-scheduler/quartz

private void processFile(JobFile jobFile) {
  if (jobFile == null || !jobFile.getFileFound()) {
    return;
  }
  try {
    XMLSchedulingDataProcessor processor = 
      new XMLSchedulingDataProcessor(this.classLoadHelper);
    
    processor.addJobGroupToNeverDelete(JOB_INITIALIZATION_PLUGIN_NAME);
    processor.addTriggerGroupToNeverDelete(JOB_INITIALIZATION_PLUGIN_NAME);
    
    processor.processFileAndScheduleJobs(
        jobFile.getFileName(), 
        jobFile.getFileName(), // systemId 
        getScheduler());
  } catch (Exception e) {
    getLog().error("Error scheduling jobs: " + e.getMessage(), e);
  }
}

相关文章