Codota Logo
DriverDelegate.selectNumTriggersForJob
Code IndexAdd Codota to your IDE (free)

How to use
selectNumTriggersForJob
method
in
org.quartz.impl.jdbcjobstore.DriverDelegate

Best Java code snippets using org.quartz.impl.jdbcjobstore.DriverDelegate.selectNumTriggersForJob (Showing top 4 results out of 315)

  • Add the Codota plugin to your IDE and get smart completions
private void myMethod () {
BufferedReader b =
  • Codota IconInputStream in;new BufferedReader(new InputStreamReader(in))
  • Codota IconReader in;new BufferedReader(in)
  • Codota IconFile file;new BufferedReader(new FileReader(file))
  • Smart code suggestions by Codota
}
origin: quartz-scheduler/quartz

protected boolean removeTrigger(Connection conn, TriggerKey key)
  throws JobPersistenceException {
  boolean removedTrigger;
  try {
    // this must be called before we delete the trigger, obviously
    JobDetail job = getDelegate().selectJobForTrigger(conn,
        getClassLoadHelper(), key, false);
    removedTrigger = 
      deleteTriggerAndChildren(conn, key);
    if (null != job && !job.isDurable()) {
      int numTriggers = getDelegate().selectNumTriggersForJob(conn,
          job.getKey());
      if (numTriggers == 0) {
        // Don't call removeJob() because we don't want to check for
        // triggers again.
        deleteJobAndChildren(conn, job.getKey());
      }
    }
  } catch (ClassNotFoundException e) {
    throw new JobPersistenceException("Couldn't remove trigger: "
        + e.getMessage(), e);
  } catch (SQLException e) {
    throw new JobPersistenceException("Couldn't remove trigger: "
        + e.getMessage(), e);
  }
  return removedTrigger;
}
origin: quartz-scheduler/quartz

protected boolean removeTrigger(Connection conn, TriggerKey key)
  throws JobPersistenceException {
  boolean removedTrigger;
  try {
    // this must be called before we delete the trigger, obviously
    JobDetail job = getDelegate().selectJobForTrigger(conn,
        getClassLoadHelper(), key, false);
    removedTrigger = 
      deleteTriggerAndChildren(conn, key);
    if (null != job && !job.isDurable()) {
      int numTriggers = getDelegate().selectNumTriggersForJob(conn,
          job.getKey());
      if (numTriggers == 0) {
        // Don't call removeJob() because we don't want to check for
        // triggers again.
        deleteJobAndChildren(conn, job.getKey());
      }
    }
  } catch (ClassNotFoundException e) {
    throw new JobPersistenceException("Couldn't remove trigger: "
        + e.getMessage(), e);
  } catch (SQLException e) {
    throw new JobPersistenceException("Couldn't remove trigger: "
        + e.getMessage(), e);
  }
  return removedTrigger;
}
origin: com.opensymphony.quartz/com.springsource.org.quartz

protected boolean removeTrigger(Connection conn, SchedulingContext ctxt,
    String triggerName, String groupName)
  throws JobPersistenceException {
  boolean removedTrigger = false;
  try {
    // this must be called before we delete the trigger, obviously
    JobDetail job = getDelegate().selectJobForTrigger(conn,
        triggerName, groupName, getClassLoadHelper());
    removedTrigger = 
      deleteTriggerAndChildren(conn, triggerName, groupName);
    if (null != job && !job.isDurable()) {
      int numTriggers = getDelegate().selectNumTriggersForJob(conn,
          job.getName(), job.getGroup());
      if (numTriggers == 0) {
        // Don't call removeJob() because we don't want to check for
        // triggers again.
        deleteJobAndChildren(conn, ctxt, job.getName(), job.getGroup());
      }
    }
  } catch (ClassNotFoundException e) {
    throw new JobPersistenceException("Couldn't remove trigger: "
        + e.getMessage(), e);
  } catch (SQLException e) {
    throw new JobPersistenceException("Couldn't remove trigger: "
        + e.getMessage(), e);
  }
  return removedTrigger;
}
origin: quartz/quartz-all

protected boolean removeTrigger(Connection conn, SchedulingContext ctxt,
    String triggerName, String groupName)
  throws JobPersistenceException {
  boolean removedTrigger = false;
  try {
    // this must be called before we delete the trigger, obviously
    JobDetail job = getDelegate().selectJobForTrigger(conn,
        triggerName, groupName, getClassLoadHelper());
    removedTrigger = 
      deleteTriggerAndChildren(conn, triggerName, groupName);
    if (null != job && !job.isDurable()) {
      int numTriggers = getDelegate().selectNumTriggersForJob(conn,
          job.getName(), job.getGroup());
      if (numTriggers == 0) {
        // Don't call removeJob() because we don't want to check for
        // triggers again.
        deleteJobAndChildren(conn, ctxt, job.getName(), job.getGroup());
      }
    }
  } catch (ClassNotFoundException e) {
    throw new JobPersistenceException("Couldn't remove trigger: "
        + e.getMessage(), e);
  } catch (SQLException e) {
    throw new JobPersistenceException("Couldn't remove trigger: "
        + e.getMessage(), e);
  }
  return removedTrigger;
}
org.quartz.impl.jdbcjobstoreDriverDelegateselectNumTriggersForJob

Javadoc

Select the number of triggers associated with a given job.

Popular methods of DriverDelegate

  • calendarExists
    Check whether or not a calendar exists.
  • calendarIsReferenced
    Check whether or not a calendar is referenced by any triggers.
  • deleteCalendar
    Delete a calendar.
  • deleteFiredTrigger
    Delete a fired trigger.
  • deleteFiredTriggers
    Delete all fired triggers of the given instance.
  • deleteJobDetail
    Delete the job detail record for the given job.
  • deletePausedTriggerGroup
  • deleteSchedulerState
    Delete a scheduler-instance state record.
  • deleteTrigger
    Delete the base trigger data for a trigger.
  • insertCalendar
    Insert a new calendar.
  • insertFiredTrigger
    Insert a fired trigger.
  • insertJobDetail
    Insert the job detail record.
  • insertFiredTrigger,
  • insertJobDetail,
  • insertPausedTriggerGroup,
  • insertSchedulerState,
  • insertTrigger,
  • isTriggerGroupPaused,
  • jobExists,
  • selectCalendar,
  • selectCalendars,
  • selectFiredTriggerInstanceNames

Popular in Java

  • Reading from database using SQL prepared statement
  • scheduleAtFixedRate (ScheduledExecutorService)
  • getResourceAsStream (ClassLoader)
  • setScale (BigDecimal)
    Returns a BigDecimal whose scale is the specified value, and whose value is numerically equal to thi
  • FlowLayout (java.awt)
    A flow layout arranges components in a left-to-right flow, much like lines of text in a paragraph. F
  • Thread (java.lang)
    A thread is a thread of execution in a program. The Java Virtual Machine allows an application to ha
  • SocketException (java.net)
    This SocketException may be thrown during socket creation or setting options, and is the superclass
  • Collection (java.util)
    Collection is the root of the collection hierarchy. It defines operations on data collections and t
  • SSLHandshakeException (javax.net.ssl)
    The exception that is thrown when a handshake could not be completed successfully.
  • LogFactory (org.apache.commons.logging)
    A minimal incarnation of Apache Commons Logging's LogFactory API, providing just the common Log look
Codota Logo
  • Products

    Search for Java codeSearch for JavaScript codeEnterprise
  • IDE Plugins

    IntelliJ IDEAWebStormAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogCodota Academy Plugin user guide Terms of usePrivacy policyJava Code IndexJavascript Code Index
Get Codota for your IDE now