Examples of failed()


Examples of com.facebook.presto.jdbc.internal.jetty.util.Callback.failed()

     */
    public void onFail(Throwable cause)
    {
        Callback callback=_interested.get();
        if (callback!=null && _interested.compareAndSet(callback,null))
            callback.failed(cause);
    }
   
    /* ------------------------------------------------------------ */
    public void onClose()
    {
View Full Code Here

Examples of com.fasterxml.clustermate.client.operation.HeadOperationResult.failed()

     */
    public long getContentLength(CONFIG config, K key)
            throws InterruptedException
    {
        HeadOperationResult result = headContent(config, key);
        if (result.failed()) { // failed to contact any server
            NodeFailure nodeFail = result.getFirstFail();
            if (nodeFail != null) {
                CallFailure callFail = nodeFail.getFirstCallFailure();
                if (callFail != null) {
                    Throwable t = callFail.getCause();
View Full Code Here

Examples of com.github.mustachejava.util.LatchedWriter.failed()

              ((LatchedWriter) subWriter).await();
            }
            // Tell the replacement writer that we are done
            latchedWriter.done();
          } catch (Throwable e) {
            latchedWriter.failed(e);
          }
        }
      });
    }
    return writer;
View Full Code Here

Examples of com.github.mustachejava.util.LatchedWriter.failed()

          try {
            Object call = callable.call();
            execute(finalWriter, call == null ? null : oh.stringify(call));
            latchedWriter.done();
          } catch (Throwable e) {
            latchedWriter.failed(e);
          }
        }
      });
      return super.execute(latchedWriter, scopes);
    }
View Full Code Here

Examples of com.google.protobuf.RpcController.failed()

      if (returnValue != null) {
        builder.setResponseMessage(returnValue.toByteString());
      }

      if (controller.failed()) {
        builder.setErrorMessage(controller.errorText());
      }
      e.getChannel().write(builder.build());
    }
View Full Code Here

Examples of com.google.protobuf.RpcController.failed()

          if (returnValue != null) {
            builder.setResponseMessage(returnValue.toByteString());
          }

          if (controller.failed()) {
            builder.setErrorMessage(controller.errorText());
          }

          channel.write(builder.build());
        }
View Full Code Here

Examples of com.google.protobuf.RpcController.failed()

    });

    // Wait for a response, and assert that is a complete failure. :-)
    responseLatch.await(TIMEOUT_SECONDS, TimeUnit.SECONDS);
    assertEquals(Arrays.asList((ProtocolWaveletUpdate) null), responses);
    assertTrue(controller.failed());
    assertEquals(ERROR_TEXT, controller.errorText());
  }

  /**
   * Tests cancelling a streaming RPC. This is achieved by waiting for the first
View Full Code Here

Examples of com.google.protobuf.RpcController.failed()

    // Cancel the RPC and wait for it to finish.
    controller.startCancel();
    finishedLatch.await(TIMEOUT_SECONDS, TimeUnit.SECONDS);
    assertEquals(0, finishedLatch.getCount());
    assertFalse(controller.failed());
  }

}
View Full Code Here

Examples of com.google.protobuf.RpcController.failed()

      if (returnValue != null) {
        builder.setResponseMessage(returnValue.toByteString());
      }

      if (controller.failed()) {
        builder.setErrorMessage(controller.errorText());
      }
      e.getChannel().write(builder.build());
    }
View Full Code Here

Examples of com.google.protobuf.RpcController.failed()

          if (returnValue != null) {
            builder.setResponseMessage(returnValue.toByteString());
          }

          if (controller.failed()) {
            builder.setErrorMessage(controller.errorText());
          }

          channel.write(builder.build());
        }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.