Tabnine Logo
SinkQueue$Consumer.consume
Code IndexAdd Tabnine to your IDE (free)

How to use
consume
method
in
org.apache.hadoop.metrics2.impl.SinkQueue$Consumer

Best Java code snippets using org.apache.hadoop.metrics2.impl.SinkQueue$Consumer.consume (Showing top 10 results out of 315)

origin: io.prestosql.hadoop/hadoop-apache

/**
 * Consume all the elements, will block if queue is empty
 * @param consumer  the consumer callback object
 * @throws InterruptedException
 */
void consumeAll(Consumer<T> consumer) throws InterruptedException {
 waitForData();
 try {
  for (int i = size(); i-- > 0; ) {
   consumer.consume(front()); // can take forever
   _dequeue();
  }
 }
 finally {
  clearConsumerLock();
 }
}
origin: ch.cern.hadoop/hadoop-common

/**
 * Consume all the elements, will block if queue is empty
 * @param consumer  the consumer callback object
 * @throws InterruptedException
 */
void consumeAll(Consumer<T> consumer) throws InterruptedException {
 waitForData();
 try {
  for (int i = size(); i-- > 0; ) {
   consumer.consume(front()); // can take forever
   _dequeue();
  }
 }
 finally {
  clearConsumerLock();
 }
}
origin: io.hops/hadoop-common

/**
 * Consume all the elements, will block if queue is empty
 * @param consumer  the consumer callback object
 * @throws InterruptedException
 */
void consumeAll(Consumer<T> consumer) throws InterruptedException {
 waitForData();
 try {
  for (int i = size(); i-- > 0; ) {
   consumer.consume(front()); // can take forever
   _dequeue();
  }
 }
 finally {
  clearConsumerLock();
 }
}
origin: io.hops/hadoop-common

/**
 * Consume one element, will block if queue is empty
 * Only one consumer at a time is allowed
 * @param consumer  the consumer callback object
 */
void consume(Consumer<T> consumer) throws InterruptedException {
 T e = waitForData();
 try {
  consumer.consume(e);  // can take forever
  _dequeue();
 }
 finally {
  clearConsumerLock();
 }
}
origin: io.prestosql.hadoop/hadoop-apache

/**
 * Consume one element, will block if queue is empty
 * Only one consumer at a time is allowed
 * @param consumer  the consumer callback object
 */
void consume(Consumer<T> consumer) throws InterruptedException {
 T e = waitForData();
 try {
  consumer.consume(e);  // can take forever
  _dequeue();
 }
 finally {
  clearConsumerLock();
 }
}
origin: com.github.jiayuhan-it/hadoop-common

/**
 * Consume one element, will block if queue is empty
 * Only one consumer at a time is allowed
 * @param consumer  the consumer callback object
 */
void consume(Consumer<T> consumer) throws InterruptedException {
 T e = waitForData();
 try {
  consumer.consume(e);  // can take forever
  _dequeue();
 }
 finally {
  clearConsumerLock();
 }
}
origin: com.github.jiayuhan-it/hadoop-common

/**
 * Consume all the elements, will block if queue is empty
 * @param consumer  the consumer callback object
 * @throws InterruptedException
 */
void consumeAll(Consumer<T> consumer) throws InterruptedException {
 waitForData();
 try {
  for (int i = size(); i-- > 0; ) {
   consumer.consume(front()); // can take forever
   _dequeue();
  }
 }
 finally {
  clearConsumerLock();
 }
}
origin: ch.cern.hadoop/hadoop-common

/**
 * Consume one element, will block if queue is empty
 * Only one consumer at a time is allowed
 * @param consumer  the consumer callback object
 */
void consume(Consumer<T> consumer) throws InterruptedException {
 T e = waitForData();
 try {
  consumer.consume(e);  // can take forever
  _dequeue();
 }
 finally {
  clearConsumerLock();
 }
}
origin: org.apache.hadoop/hadoop-common

/**
 * Consume all the elements, will block if queue is empty
 * @param consumer  the consumer callback object
 * @throws InterruptedException
 */
void consumeAll(Consumer<T> consumer) throws InterruptedException {
 waitForData();
 try {
  for (int i = size(); i-- > 0; ) {
   consumer.consume(front()); // can take forever
   _dequeue();
  }
 }
 finally {
  clearConsumerLock();
 }
}
origin: org.apache.hadoop/hadoop-common

/**
 * Consume one element, will block if queue is empty
 * Only one consumer at a time is allowed
 * @param consumer  the consumer callback object
 */
void consume(Consumer<T> consumer) throws InterruptedException {
 T e = waitForData();
 try {
  consumer.consume(e);  // can take forever
  _dequeue();
 }
 finally {
  clearConsumerLock();
 }
}
org.apache.hadoop.metrics2.implSinkQueue$Consumerconsume

Popular methods of SinkQueue$Consumer

    Popular in Java

    • Running tasks concurrently on multiple threads
    • getExternalFilesDir (Context)
    • runOnUiThread (Activity)
    • getSystemService (Context)
    • FileNotFoundException (java.io)
      Thrown when a file specified by a program cannot be found.
    • ConnectException (java.net)
      A ConnectException is thrown if a connection cannot be established to a remote host on a specific po
    • Date (java.sql)
      A class which can consume and produce dates in SQL Date format. Dates are represented in SQL as yyyy
    • ThreadPoolExecutor (java.util.concurrent)
      An ExecutorService that executes each submitted task using one of possibly several pooled threads, n
    • Stream (java.util.stream)
      A sequence of elements supporting sequential and parallel aggregate operations. The following exampl
    • IsNull (org.hamcrest.core)
      Is the value null?
    • Top 12 Jupyter Notebook extensions
    Tabnine Logo
    • Products

      Search for Java codeSearch for JavaScript code
    • IDE Plugins

      IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
    • Company

      About UsContact UsCareers
    • Resources

      FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
    Get Tabnine for your IDE now