Interface QueueProvider

    • Method Detail

      • getExecutionSize

        Long getExecutionSize()
        Get the value for ExecutionSize. (ExecutionSize is the maximum number of concurrent executing jobs allowed in the queue. If IncludeWaitingJobs is true this includes jobs in Executing and Idle JobStatusStates. If IncludeWaitingJobs is false then this only includes the jobs in the Executing JobStatusState.)
        Returns:
        the field
        Throws:
        com.redwood.scheduler.api.exception.ObjectNotAttachedToSessionException - This will be thrown if this method is called while the object is not attached to a session.
      • isHeld

        boolean isHeld()
        Get the value for Held. (Is the queue provider on hold?)
        Returns:
        the field
        Throws:
        com.redwood.scheduler.api.exception.ObjectNotAttachedToSessionException - This will be thrown if this method is called while the object is not attached to a session.
      • getHoldLevel

        Long getHoldLevel()
        Get the value for HoldLevel. (Jobs having a priority below the specified number will not be started on this process server for this queue)
        Returns:
        the field
        Throws:
        com.redwood.scheduler.api.exception.ObjectNotAttachedToSessionException - This will be thrown if this method is called while the object is not attached to a session.
      • isInclusive

        boolean isInclusive()
        Get the value for Inclusive. (Does the execution size include waiting jobs?)
        Returns:
        the field
        Throws:
        com.redwood.scheduler.api.exception.ObjectNotAttachedToSessionException - This will be thrown if this method is called while the object is not attached to a session.
      • getNextWindowChange

        DateTimeZone getNextWindowChange()
        Get the value for NextWindowChange. (The next date on which the time window will open or close the queue again)
        Returns:
        the field
        Throws:
        com.redwood.scheduler.api.exception.ObjectNotAttachedToSessionException - This will be thrown if this method is called while the object is not attached to a session.
      • isOpen

        boolean isOpen()
        Get the value for Open. (Is the queue provider open?)
        Returns:
        the field
        Throws:
        com.redwood.scheduler.api.exception.ObjectNotAttachedToSessionException - This will be thrown if this method is called while the object is not attached to a session.
      • getStatus

        QueueStatus getStatus()
        Get the value for Status. (Return the status of the queue provider) This value is mandatory, and therefore will not be null if this object has been retrieved from the database.
        Returns:
        the field
        Throws:
        com.redwood.scheduler.api.exception.ObjectNotAttachedToSessionException - This will be thrown if this method is called while the object is not attached to a session.
      • setExecutionSize

        void setExecutionSize​(Long newExecutionSize)
        Set the value for ExecutionSize. (ExecutionSize is the maximum number of concurrent executing jobs allowed in the queue. If IncludeWaitingJobs is true this includes jobs in Executing and Idle JobStatusStates. If IncludeWaitingJobs is false then this only includes the jobs in the Executing JobStatusState.) This value is optional.
        Parameters:
        newExecutionSize - the new value for ExecutionSize.
        Throws:
        com.redwood.scheduler.api.exception.ObjectNotAttachedToSessionException - This will be thrown if this method is called while the object is not attached to a session.
      • setHeld

        void setHeld​(boolean newHeld)
        Set the value for Held. (Is the queue provider on hold?)
        Parameters:
        newHeld - the new value for Held.
        Throws:
        com.redwood.scheduler.api.exception.ObjectNotAttachedToSessionException - This will be thrown if this method is called while the object is not attached to a session.
      • setHoldLevel

        void setHoldLevel​(Long newHoldLevel)
        Set the value for HoldLevel. (Jobs having a priority below the specified number will not be started on this process server for this queue) This value is optional.
        Parameters:
        newHoldLevel - the new value for HoldLevel.
        Throws:
        com.redwood.scheduler.api.exception.ObjectNotAttachedToSessionException - This will be thrown if this method is called while the object is not attached to a session.
      • setInclusive

        void setInclusive​(boolean newInclusive)
        Set the value for Inclusive. (Does the execution size include waiting jobs?)
        Parameters:
        newInclusive - the new value for Inclusive.
        Throws:
        com.redwood.scheduler.api.exception.ObjectNotAttachedToSessionException - This will be thrown if this method is called while the object is not attached to a session.
      • hold

        void hold()
        Hold the QueueProvider, such that further Jobs are not allocated from this Queue to this ProcessServer.
      • release

        void release()
        Release the QueueProvider, such that further Jobs can be allocated to this ProcessServer from this Queue.
      • getProcessServer

        ProcessServer getProcessServer()
        Get the ProcessServer.
        Returns:
        ProcessServer
        Throws:
        com.redwood.scheduler.api.exception.ObjectDeletedException - If this method is called when the object has been marked for deletion.
        com.redwood.scheduler.api.exception.ObjectNotAttachedToSessionException - If this method is called when the object has been removed from it's session.
      • getQueue

        Queue getQueue()
        Get the Queue.
        Returns:
        Queue
        Throws:
        com.redwood.scheduler.api.exception.ObjectDeletedException - If this method is called when the object has been marked for deletion.
        com.redwood.scheduler.api.exception.ObjectNotAttachedToSessionException - If this method is called when the object has been removed from it's session.
      • getTimeWindow

        TimeWindow getTimeWindow()
        Get the TimeWindow.
        Returns:
        TimeWindow
        Throws:
        com.redwood.scheduler.api.exception.ObjectDeletedException - If this method is called when the object has been marked for deletion.
        com.redwood.scheduler.api.exception.ObjectNotAttachedToSessionException - If this method is called when the object has been removed from it's session.
      • getQueueProviderTimeZone

        TimeZone getQueueProviderTimeZone()
        Get the QueueProviderTimeZone.
        Returns:
        QueueProviderTimeZone
        Throws:
        com.redwood.scheduler.api.exception.ObjectDeletedException - If this method is called when the object has been marked for deletion.
        com.redwood.scheduler.api.exception.ObjectNotAttachedToSessionException - If this method is called when the object has been removed from it's session.
      • setTimeWindow

        void setTimeWindow​(TimeWindow newTimeWindow)
        Set the value for TimeWindow. This value is optional.
        Parameters:
        newTimeWindow - is the object to set TimeWindow to. The time window when this queue is open for this process server.
      • setQueueProviderTimeZone

        void setQueueProviderTimeZone​(TimeZone newQueueProviderTimeZone)
        Set the value for QueueProviderTimeZone. This value is optional.
        Parameters:
        newQueueProviderTimeZone - is the object to set QueueProviderTimeZone to. The timezone to use for QueueProvider TimeWindow calculations.