Class SchedulerService


  • public class SchedulerService
    extends Object
    • Field Detail

      • scheduler

        protected org.pentaho.platform.api.scheduler2.IScheduler scheduler
      • policy

        protected org.pentaho.platform.api.engine.IAuthorizationPolicy policy
      • repository

        protected org.pentaho.platform.api.repository2.unified.IUnifiedRepository repository
      • blockoutManager

        protected org.pentaho.platform.api.scheduler2.IBlockoutManager blockoutManager
    • Constructor Detail

      • SchedulerService

        public SchedulerService()
    • Method Detail

      • triggerNow

        public org.pentaho.platform.api.scheduler2.Job triggerNow​(String jobId)
                                                           throws org.pentaho.platform.api.scheduler2.SchedulerException
        Throws:
        org.pentaho.platform.api.scheduler2.SchedulerException
      • getContentCleanerJob

        public org.pentaho.platform.api.scheduler2.Job getContentCleanerJob()
                                                                     throws org.pentaho.platform.api.scheduler2.SchedulerException
        Throws:
        org.pentaho.platform.api.scheduler2.SchedulerException
      • doGetGeneratedContentForSchedule

        public List<org.pentaho.platform.api.repository2.unified.webservices.RepositoryFileDto> doGetGeneratedContentForSchedule​(String lineageId)
                                                                                                                          throws FileNotFoundException
        Parameters:
        lineageId -
        Returns:
        Throws:
        FileNotFoundException
      • getJob

        public org.pentaho.platform.api.scheduler2.Job getJob​(String jobId)
                                                       throws org.pentaho.platform.api.scheduler2.SchedulerException
        Throws:
        org.pentaho.platform.api.scheduler2.SchedulerException
      • isScheduleAllowed

        public boolean isScheduleAllowed()
      • isScheduleAllowed

        public boolean isScheduleAllowed​(String id)
      • getJobFilter

        public org.pentaho.platform.api.scheduler2.IJobFilter getJobFilter​(boolean canAdminister,
                                                                           String principalName)
      • doGetCanSchedule

        public String doGetCanSchedule()
      • getState

        public String getState()
                        throws org.pentaho.platform.api.scheduler2.SchedulerException
        Throws:
        org.pentaho.platform.api.scheduler2.SchedulerException
      • start

        public String start()
                     throws org.pentaho.platform.api.scheduler2.SchedulerException
        Throws:
        org.pentaho.platform.api.scheduler2.SchedulerException
      • pause

        public String pause()
                     throws org.pentaho.platform.api.scheduler2.SchedulerException
        Throws:
        org.pentaho.platform.api.scheduler2.SchedulerException
      • shutdown

        public String shutdown()
                        throws org.pentaho.platform.api.scheduler2.SchedulerException
        Throws:
        org.pentaho.platform.api.scheduler2.SchedulerException
      • pauseJob

        public org.pentaho.platform.api.scheduler2.Job.JobState pauseJob​(String jobId)
                                                                  throws org.pentaho.platform.api.scheduler2.SchedulerException
        Throws:
        org.pentaho.platform.api.scheduler2.SchedulerException
      • resumeJob

        public org.pentaho.platform.api.scheduler2.Job.JobState resumeJob​(String jobId)
                                                                   throws org.pentaho.platform.api.scheduler2.SchedulerException
        Throws:
        org.pentaho.platform.api.scheduler2.SchedulerException
      • removeJob

        public boolean removeJob​(String jobId)
                          throws org.pentaho.platform.api.scheduler2.SchedulerException
        Throws:
        org.pentaho.platform.api.scheduler2.SchedulerException
      • getJobInfo

        public org.pentaho.platform.api.scheduler2.Job getJobInfo​(String jobId)
                                                           throws org.pentaho.platform.api.scheduler2.SchedulerException
        Throws:
        org.pentaho.platform.api.scheduler2.SchedulerException
      • getBlockOutJobs

        public List<org.pentaho.platform.api.scheduler2.Job> getBlockOutJobs()
      • hasBlockouts

        public boolean hasBlockouts()
      • willFire

        public boolean willFire​(org.pentaho.platform.api.scheduler2.IJobTrigger trigger)
      • shouldFireNow

        public boolean shouldFireNow()
      • updateStartDateForTimeZone

        protected void updateStartDateForTimeZone​(JobScheduleRequest jobScheduleRequest)
      • getBlockStatus

        public BlockStatusProxy getBlockStatus​(JobScheduleRequest jobScheduleRequest)
                                        throws org.pentaho.platform.api.scheduler2.SchedulerException
        Throws:
        org.pentaho.platform.api.scheduler2.SchedulerException
      • convertScheduleRequestToJobTrigger

        protected org.pentaho.platform.api.scheduler2.IJobTrigger convertScheduleRequestToJobTrigger​(JobScheduleRequest jobScheduleRequest)
                                                                                              throws org.pentaho.platform.api.scheduler2.SchedulerException
        Throws:
        org.pentaho.platform.api.scheduler2.SchedulerException
      • getJobState

        public org.pentaho.platform.api.scheduler2.Job.JobState getJobState​(JobRequest jobRequest)
                                                                     throws org.pentaho.platform.api.scheduler2.SchedulerException
        Throws:
        org.pentaho.platform.api.scheduler2.SchedulerException
      • getSession

        protected org.pentaho.platform.api.engine.IPentahoSession getSession()
      • getRepository

        public org.pentaho.platform.api.repository2.unified.IUnifiedRepository getRepository()
      • getScheduler

        public org.pentaho.platform.api.scheduler2.IScheduler getScheduler()
      • getPolicy

        public org.pentaho.platform.api.engine.IAuthorizationPolicy getPolicy()
      • isPdiFile

        protected boolean isPdiFile​(org.pentaho.platform.api.repository2.unified.RepositoryFile file)
      • getAutoCreateUniqueFilename

        public boolean getAutoCreateUniqueFilename​(JobScheduleRequest scheduleRequest)
      • getJobs

        public List<org.pentaho.platform.api.scheduler2.Job> getJobs()
                                                              throws org.pentaho.platform.api.scheduler2.SchedulerException
        Throws:
        org.pentaho.platform.api.scheduler2.SchedulerException
      • canAdminister

        protected Boolean canAdminister()
      • canAdminister

        protected Boolean canAdminister​(org.pentaho.platform.api.engine.IPentahoSession session)
      • resolveActionId

        protected String resolveActionId​(String inputFile)
      • getExtension

        protected String getExtension​(String filename)
      • getSessionResource

        protected SessionResource getSessionResource()
        Gets an instance of SessionResource
        Returns:
        SessionResource
      • getFileService

        protected FileService getFileService()
      • getBlockoutManager

        protected org.pentaho.platform.api.scheduler2.IBlockoutManager getBlockoutManager()
      • getSecurityHelper

        protected org.pentaho.platform.api.engine.ISecurityHelper getSecurityHelper()