Codota Logo
Subscription.poll
Code IndexAdd Codota to your IDE (free)

How to use
poll
method
in
io.zeebe.dispatcher.Subscription

Best Java code snippets using io.zeebe.dispatcher.Subscription.poll (Showing top 4 results out of 315)

  • Add the Codota plugin to your IDE and get smart completions
private void myMethod () {
ScheduledThreadPoolExecutor s =
  • Codota Iconnew ScheduledThreadPoolExecutor(corePoolSize)
  • Codota IconThreadFactory threadFactory;new ScheduledThreadPoolExecutor(corePoolSize, threadFactory)
  • Codota IconString str;new ScheduledThreadPoolExecutor(1, new ThreadFactoryBuilder().setNameFormat(str).build())
  • Smart code suggestions by Codota
}
origin: zeebe-io/zeebe

 @Override
 public int poll(int maxCount) {
  return subscription.poll(fragmentHandler, maxCount);
 }
}
origin: io.zeebe/zb-transport

 @Override
 public int poll(int maxCount) {
  return subscription.poll(fragmentHandler, maxCount);
 }
}
origin: zeebe-io/zeebe

@Override
protected void onActorStarted() {
 final ActorFuture<Subscription> subscriptionAsync =
   controlMessageDispatcher.openSubscriptionAsync(
     TRANSPORT_CONTROL_MESSAGE_HANDLER_SUBSCRIPTION);
 actor.runOnCompletion(
   subscriptionAsync,
   (sub, throwable) -> {
    if (throwable == null) {
     actor.consume(
       sub,
       () -> {
        if (sub.poll(this, 1) == 0) {
         actor.yield();
        }
       });
     openFuture.complete(null);
    } else {
     openFuture.completeExceptionally(throwable);
     Loggers.SYSTEM_LOGGER.error("Can't get subscription for {}", NAME, throwable);
    }
   });
}
origin: io.zeebe/zeebe-broker-core

@Override
protected void onActorStarted() {
 final ActorFuture<Subscription> subscriptionAsync =
   controlMessageDispatcher.openSubscriptionAsync(
     TRANSPORT_CONTROL_MESSAGE_HANDLER_SUBSCRIPTION);
 actor.runOnCompletion(
   subscriptionAsync,
   (sub, throwable) -> {
    if (throwable == null) {
     actor.consume(
       sub,
       () -> {
        if (sub.poll(this, 1) == 0) {
         actor.yield();
        }
       });
     openFuture.complete(null);
    } else {
     openFuture.completeExceptionally(throwable);
     Loggers.SYSTEM_LOGGER.error("Can't get subscription for {}", NAME, throwable);
    }
   });
}
io.zeebe.dispatcherSubscriptionpoll

Javadoc

Read fragments from the buffer and invoke the given handler for each fragment. Consume the fragments (i.e. update the subscription position) after all fragments are handled.

Note that the handler is not aware of fragment batches.

Popular methods of Subscription

  • getPosition
  • peekBlock
  • <init>
  • getActorConditions
  • getLimit
  • getName
  • hasAvailable
  • peekAndConsume
    Sequentially read fragments from the buffer and invoke the given handler for each fragment. Consume
  • pollFragments
  • registerConsumer
  • removeConsumer
  • removeConsumer

Popular in Java

  • Creating JSON documents from java classes using gson
  • onRequestPermissionsResult (Fragment)
  • onCreateOptionsMenu (Activity)
  • compareTo (BigDecimal)
    Compares this BigDecimal with the specified BigDecimal. Two BigDecimal objects that are equal in val
  • RandomAccessFile (java.io)
    Allows reading from and writing to a file in a random-access manner. This is different from the uni-
  • ServerSocket (java.net)
    This class represents a server-side socket that waits for incoming client connections. A ServerSocke
  • MessageDigest (java.security)
    Uses a one-way hash function to turn an arbitrary number of bytes into a fixed-length byte sequence.
  • NumberFormat (java.text)
    The abstract base class for all number formats. This class provides the interface for formatting and
  • SimpleDateFormat (java.text)
    Formats and parses dates in a locale-sensitive manner. Formatting turns a Date into a String, and pa
  • Vector (java.util)
    The Vector class implements a growable array of objects. Like an array, it contains components that
Codota Logo
  • Products

    Search for Java codeSearch for JavaScript codeEnterprise
  • IDE Plugins

    IntelliJ IDEAWebStormAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogCodota Academy Plugin user guide Terms of usePrivacy policyJava Code IndexJavascript Code Index
Get Codota for your IDE now