Package co.cask.tigon.api.flow.flowlet

Examples of co.cask.tigon.api.flow.flowlet.InputContext


    this.queueName = queueName;
    // Memorize the transformed Iterable so that decoder would only invoked once for each event no matter
    // how many times iterator() is called. This is to save time as well as a need for the case where
    // metrics has been logged inside the decoder.
    this.events = result.isEmpty() ? ImmutableList.<T>of() : ImmutableList.copyOf(Iterables.transform(result, decoder));
    this.inputContext = new InputContext() {
      @Override
      public String getOrigin() {
        return queueName.getSimpleName();
      }
View Full Code Here


  @Override
  public ProcessResult<T> invoke(InputDatum<T> input) {
    try {
      Preconditions.checkState(!hasParam || input.needProcess(), "Empty input provided to method that needs input.");

      InputContext inputContext = input.getInputContext();

      try {
        if (hasParam) {
          if (needsIterator) {
            invoke(method, input.iterator(), inputContext);
View Full Code Here

  /**
   * Process the process result. This method never throws.
   */
  private void postProcess(ProcessMethodCallback callback, TransactionContext txContext,
                           InputDatum input, ProcessMethod.ProcessResult result) {
    InputContext inputContext = input.getInputContext();
    Throwable failureCause = null;
    FailureReason.Type failureType = FailureReason.Type.IO_ERROR;
    try {
      if (result.isSuccess()) {
        // If it is a retry input, force the dequeued entries into current transaction.
View Full Code Here

TOP

Related Classes of co.cask.tigon.api.flow.flowlet.InputContext

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.