Interface WorkflowUpdateHandle<T>

    • Method Summary

      All Methods Instance Methods Abstract Methods 
      Modifier and Type Method Description
      io.temporal.api.common.v1.WorkflowExecution getExecution()
      Gets the workflow execution this update request was sent to.
      java.lang.String getId()
      Gets the unique ID of this update.
      T getResult()
      Returns the result of the workflow update.
      T getResult​(long timeout, java.util.concurrent.TimeUnit unit)
      Returns the result of the workflow update.
      java.util.concurrent.CompletableFuture<T> getResultAsync()
      Returns a CompletableFuture with the update workflow execution request result, potentially waiting for the update to complete.
      java.util.concurrent.CompletableFuture<T> getResultAsync​(long timeout, java.util.concurrent.TimeUnit unit)
      Returns a CompletableFuture with the update workflow execution request result, potentially waiting for the update to complete.
    • Method Detail

      • getExecution

        io.temporal.api.common.v1.WorkflowExecution getExecution()
        Gets the workflow execution this update request was sent to.
        Returns:
        the workflow execution this update was sent to.
      • getId

        java.lang.String getId()
        Gets the unique ID of this update.
        Returns:
        the updates ID.
      • getResult

        T getResult()
        Returns the result of the workflow update.
        Returns:
        the result of the workflow update
        Throws:
        WorkflowUpdateException - if the update was rejected or failed by the workflow.
      • getResult

        T getResult​(long timeout,
                    java.util.concurrent.TimeUnit unit)
        Returns the result of the workflow update.
        Parameters:
        timeout - maximum time to wait and perform the background long polling
        unit - unit of timeout
        Returns:
        the result of the workflow update
        Throws:
        WorkflowUpdateTimeoutOrCancelledException - if the timeout is reached.
        WorkflowUpdateException - if the update was rejected or failed by the workflow.
      • getResultAsync

        java.util.concurrent.CompletableFuture<T> getResultAsync()
        Returns a CompletableFuture with the update workflow execution request result, potentially waiting for the update to complete.
        Returns:
        future completed with the result of the update or an exception
      • getResultAsync

        java.util.concurrent.CompletableFuture<T> getResultAsync​(long timeout,
                                                                 java.util.concurrent.TimeUnit unit)
        Returns a CompletableFuture with the update workflow execution request result, potentially waiting for the update to complete.
        Parameters:
        timeout - maximum time to wait and perform the background long polling
        unit - unit of timeout
        Returns:
        future completed with the result of the update or an exception