Class ExecutionWithResponse

java.lang.Object
com.yahoo.processing.execution.Execution
com.yahoo.processing.execution.ExecutionWithResponse

public class ExecutionWithResponse extends Execution
An execution which has a response which is returned when this gets to the end of the chain. This is useful to run processing chains where a response exists up front, typically for on completion listeners.
Author:
bratseth
  • Constructor Details

    • ExecutionWithResponse

      public ExecutionWithResponse(Chain<? extends Processor> chain, Response response, Execution execution)
      Creates an execution which will return a given response at the end of the chain.
      Parameters:
      chain - the chain to execute in this
      response - the response this will return from Execution.process(com.yahoo.processing.Request) then the end of this chain is reached
      execution - the the parent of this execution
  • Method Details

    • defaultResponse

      protected Response defaultResponse(Request request)
      Description copied from class: Execution
      Creates the default response to return from this kind of execution when there are no further processors. If this is overridden, make sure to propagate any freezeListener from this to the returned response top-level DataList.
      Overrides:
      defaultResponse in class Execution