code: public static void stopJob(String jobName) throws SundialSchedulerException {
  
      try {
        List<JobExecutionContext> currentlyExecutingJobs = getScheduler().getCurrentlyExecutingJobs();
        for (JobExecutionContext jobExecutionContext : currentlyExecutingJobs) {
          String currentlyExecutingJobName = jobExecutionContext.getJobDetail().getName();
          if (currentlyExecutingJobName.equals(jobName)) {
            logger.debug("Matching Job found. Now Stopping!");
            if (jobExecutionContext.getJobInstance() instanceof Job) {
              ((Job) jobExecutionContext.getJobInstance()).interrupt();
            } else {
              logger.warn("CANNOT STOP NON-INTERRUPTABLE JOB!!!");
            }
          } else {
            logger.debug("Non-matching Job found. Not Stopping!");
          }
        }
      } catch (SchedulerException e) {
        throw new SundialSchedulerException("ERROR STOPPING JOB!!!", e);
      }
    }
docs: Triggers a Job interrupt on all Jobs matching the given Job Name. The Job termination mechanism
  works by setting a flag that the Job should be terminated, but it is up to the logic in the Job
  to decide at what point termination should occur. Therefore, in any long-running job that you
  anticipate the need to terminate, put the method call checkTerminated() at an appropriate
  location.
  
  @param jobName The job name