Package org.pentaho.platform.api.scheduler2

Examples of org.pentaho.platform.api.scheduler2.ComplexJobTrigger


    }
  }

  /** {@inheritDoc} */
  public Job[] getJobs() throws SchedulerException {
    IScheduler scheduler = PentahoSystem.get( IScheduler.class, "IScheduler2", null ); //$NON-NLS-1$
    return scheduler.getJobs( null ).toArray( new Job[0] );
  }
View Full Code Here


    return scheduler.getJobs( null ).toArray( new Job[0] );
  }

  /** {@inheritDoc} */
  public void pause() throws SchedulerException {
    IScheduler scheduler = PentahoSystem.get( IScheduler.class, "IScheduler2", null ); //$NON-NLS-1$
    scheduler.pause();
  }
View Full Code Here

    scheduler.pause();
  }

  /** {@inheritDoc} */
  public void pauseJob( String jobId ) throws SchedulerException {
    IScheduler scheduler = PentahoSystem.get( IScheduler.class, "IScheduler2", null ); //$NON-NLS-1$
    scheduler.pauseJob( jobId );
  }
View Full Code Here

    scheduler.pauseJob( jobId );
  }

  /** {@inheritDoc} */
  public void removeJob( String jobId ) throws SchedulerException {
    IScheduler scheduler = PentahoSystem.get( IScheduler.class, "IScheduler2", null ); //$NON-NLS-1$
    scheduler.removeJob( jobId );
  }
View Full Code Here

    scheduler.removeJob( jobId );
  }

  /** {@inheritDoc} */
  public void start() throws SchedulerException {
    IScheduler scheduler = PentahoSystem.get( IScheduler.class, "IScheduler2", null ); //$NON-NLS-1$
    scheduler.start();
  }
View Full Code Here

    scheduler.start();
  }

  /** {@inheritDoc} */
  public void resumeJob( String jobId ) throws SchedulerException {
    IScheduler scheduler = PentahoSystem.get( IScheduler.class, "IScheduler2", null ); //$NON-NLS-1$
    scheduler.resumeJob( jobId );
  }
View Full Code Here

          throw new IllegalAccessException();
        }
      }
    }

    Job job = null;

    IJobTrigger jobTrigger = SchedulerResourceUtil.convertScheduleRequestToJobTrigger( scheduleRequest, scheduler );

    HashMap<String, Serializable> parameterMap = new HashMap<String, Serializable>();
    for ( JobScheduleParam param : scheduleRequest.getJobParameters() ) {
View Full Code Here

    return job;
  }

  public Job triggerNow( String jobId ) throws SchedulerException {
    Job job = getScheduler().getJob( jobId );
    if ( getPolicy().isAllowed( SchedulerAction.NAME ) ) {
      getScheduler().triggerNow( jobId );
    } else {
      if ( getSession().getName().equals( job.getUserName() ) ) {
        getScheduler().triggerNow( jobId );
      }
    }
    // udpate job state
    job = getScheduler().getJob( jobId );
View Full Code Here

    }
    return getScheduler().getStatus().name();
  }

  public JobState pauseJob( String jobId ) throws SchedulerException {
    Job job = getJob( jobId );
    if ( isScheduleAllowed() || PentahoSessionHolder.getSession().getName().equals( job.getUserName() ) ) {
      getScheduler().pauseJob( jobId );
    }
    job = getJob( jobId );
    return job.getState();
  }
View Full Code Here

    job = getJob( jobId );
    return job.getState();
  }

  public JobState resumeJob( String jobId ) throws SchedulerException {
    Job job = getJob( jobId );
    if ( isScheduleAllowed() || PentahoSessionHolder.getSession().getName().equals( job.getUserName() ) ) {
      getScheduler().resumeJob( jobId );
    }
    job = getJob( jobId );
    return job.getState();
  }
View Full Code Here

TOP

Related Classes of org.pentaho.platform.api.scheduler2.ComplexJobTrigger

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.