Class ProcessInstanceAdminServiceImpl

    • Constructor Detail

      • ProcessInstanceAdminServiceImpl

        public ProcessInstanceAdminServiceImpl()
    • Method Detail

      • setProcessService

        public void setProcessService​(ProcessService processService)
      • setRuntimeDataService

        public void setRuntimeDataService​(RuntimeDataService runtimeDataService)
      • setIdentityProvider

        public void setIdentityProvider​(org.kie.internal.identity.IdentityProvider identityProvider)
      • updateTimer

        public void updateTimer​(long processInstanceId,
                                long timerId,
                                long delay,
                                long period,
                                int repeatLimit)
                         throws NodeInstanceNotFoundException,
                                ProcessInstanceNotFoundException
        Description copied from interface: ProcessInstanceAdminService
        Updates active timer identified by timer id with delay that is given in seconds. Delay is absolute meaning it is as it would be set when timer was created.
        Example:
        In case timer was initially created with delay of 1 hour and after 30 min we decide to update it to 2 hours it will then expire in 1,5 hour from the time it was updated.
        Specified by:
        updateTimer in interface ProcessInstanceAdminService
        Parameters:
        processInstanceId - unique id of process instance
        timerId - timer id that should be updated
        delay - absolute delay in seconds
        period - in case of repeatable timer how often it should repeat in milliseconds - if not applicable should be set to -1
        repeatLimit - in case of repeatable timer how many times it should trigger - if not applicable should be set to -1
        Throws:
        NodeInstanceNotFoundException - in case node instance with given id is not active
        ProcessInstanceNotFoundException - in case process instance id with given id was not found
      • updateTimerRelative

        public void updateTimerRelative​(long processInstanceId,
                                        long timerId,
                                        long delay,
                                        long period,
                                        int repeatLimit)
                                 throws NodeInstanceNotFoundException,
                                        ProcessInstanceNotFoundException
        Description copied from interface: ProcessInstanceAdminService
        Updates active timer identified by timer id with delay that is given in seconds and is relative to current time.
        Example:
        In case timer was initially created with delay of 1 hour and after 30 min we decide to update it to 2 hours it will then expire in 2 hours from the time it was updated.
        Specified by:
        updateTimerRelative in interface ProcessInstanceAdminService
        Parameters:
        processInstanceId - unique id of process instance
        timerId - timer id that should be updated
        delay - absolute delay in seconds
        period - in case of repeatable timer how often it should repeat in milliseconds - if not applicable should be set to -1
        repeatLimit - in case of repeatable timer how many times it should trigger - if not applicable should be set to -1
        Throws:
        NodeInstanceNotFoundException - in case node instance with given id is not active
        ProcessInstanceNotFoundException - in case process instance id with given id was not found
      • getErrors

        public List<org.kie.internal.runtime.error.ExecutionError> getErrors​(boolean includeAcknowledged,
                                                                             org.kie.api.runtime.query.QueryContext queryContext)
        Description copied from interface: ProcessInstanceAdminService
        Returns all execution errors regardless of their type
        Specified by:
        getErrors in interface ProcessInstanceAdminService
        Parameters:
        includeAcknowledged - indicates whether to include acknowledged errors or not
        queryContext - control parameters for pagination
        Returns:
        list of found errors
      • getErrorsByProcessId

        public List<org.kie.internal.runtime.error.ExecutionError> getErrorsByProcessId​(String deploymentId,
                                                                                        String processId,
                                                                                        boolean includeAcknowledged,
                                                                                        org.kie.api.runtime.query.QueryContext queryContext)
        Description copied from interface: ProcessInstanceAdminService
        Returns execution errors for given process id and deployment id
        Specified by:
        getErrorsByProcessId in interface ProcessInstanceAdminService
        Parameters:
        deploymentId - deployment id that contains given process
        processId - process id of the process
        includeAcknowledged - indicates whether to include acknowledged errors or not
        queryContext - control parameters for pagination
        Returns:
        list of found errors
      • getErrorsByProcessInstanceId

        public List<org.kie.internal.runtime.error.ExecutionError> getErrorsByProcessInstanceId​(long processInstanceId,
                                                                                                boolean includeAcknowledged,
                                                                                                org.kie.api.runtime.query.QueryContext queryContext)
        Description copied from interface: ProcessInstanceAdminService
        Returns execution errors for given process instance id
        Specified by:
        getErrorsByProcessInstanceId in interface ProcessInstanceAdminService
        Parameters:
        processInstanceId - process instance id of the process
        includeAcknowledged - indicates whether to include acknowledged errors or not
        queryContext - control parameters for pagination
        Returns:
        list of found errors
      • getErrorsByProcessInstanceId

        public List<org.kie.internal.runtime.error.ExecutionError> getErrorsByProcessInstanceId​(long processInstanceId,
                                                                                                String nodeName,
                                                                                                boolean includeAcknowledged,
                                                                                                org.kie.api.runtime.query.QueryContext queryContext)
        Description copied from interface: ProcessInstanceAdminService
        Returns execution errors for given process instance id and node
        Specified by:
        getErrorsByProcessInstanceId in interface ProcessInstanceAdminService
        Parameters:
        processInstanceId - process instance id of the process
        nodeName - name of the node that error should be found for
        includeAcknowledged - indicates whether to include acknowledged errors or not
        queryContext - control parameters for pagination
        Returns:
        list of found errors
      • getErrorsByDeploymentId

        public List<org.kie.internal.runtime.error.ExecutionError> getErrorsByDeploymentId​(String containerId,
                                                                                           boolean includeAcknowledged,
                                                                                           org.kie.api.runtime.query.QueryContext queryContext)
        Description copied from interface: ProcessInstanceAdminService
        Returns all execution errors for a given deployment regardless of their type
        Specified by:
        getErrorsByDeploymentId in interface ProcessInstanceAdminService
        Parameters:
        containerId - deployment id that contains the errors
        includeAcknowledged - indicates whether to include acknowledged errors or not
        queryContext - control parameters for pagination
        Returns:
        list of found errors
      • applyQueryContext

        protected void applyQueryContext​(Map<String,​Object> params,
                                         org.kie.api.runtime.query.QueryContext queryContext)
      • getAckMode

        protected List<Short> getAckMode​(boolean includeAcknowledged)