Codota Logo
MLDataFormats$ManagedCursorInfo$Builder.addAllIndividualDeletedMessages
Code IndexAdd Codota to your IDE (free)

How to use
addAllIndividualDeletedMessages
method
in
org.apache.bookkeeper.mledger.proto.MLDataFormats$ManagedCursorInfo$Builder

Best Java code snippets using org.apache.bookkeeper.mledger.proto.MLDataFormats$ManagedCursorInfo$Builder.addAllIndividualDeletedMessages (Showing top 3 results out of 315)

  • Add the Codota plugin to your IDE and get smart completions
private void myMethod () {
ArrayList a =
  • Codota Iconnew ArrayList<String>()
  • Codota Iconnew ArrayList()
  • Codota Iconnew ArrayList<Object>()
  • Smart code suggestions by Codota
}
origin: apache/pulsar

private void persistPositionMetaStore(long cursorsLedgerId, PositionImpl position, Map<String, Long> properties,
    MetaStoreCallback<Void> callback, boolean persistIndividualDeletedMessageRanges) {
  // When closing we store the last mark-delete position in the z-node itself, so we won't need the cursor ledger,
  // hence we write it as -1. The cursor ledger is deleted once the z-node write is confirmed.
  ManagedCursorInfo.Builder info = ManagedCursorInfo.newBuilder() //
      .setCursorsLedgerId(cursorsLedgerId) //
      .setMarkDeleteLedgerId(position.getLedgerId()) //
      .setMarkDeleteEntryId(position.getEntryId()) //
      .setLastActive(lastActive); //
  info.addAllProperties(buildPropertiesMap(properties));
  if (persistIndividualDeletedMessageRanges) {
    info.addAllIndividualDeletedMessages(buildIndividualDeletedMessageRanges());
  }
  if (log.isDebugEnabled()) {
    log.debug("[{}][{}]  Closing cursor at md-position: {}", ledger.getName(), name, position);
  }
  ledger.getStore().asyncUpdateCursorInfo(ledger.getName(), name, info.build(), cursorLedgerStat,
      new MetaStoreCallback<Void>() {
        @Override
        public void operationComplete(Void result, Stat stat) {
          cursorLedgerStat = stat;
          callback.operationComplete(result, stat);
        }
        @Override
        public void operationFailed(MetaStoreException e) {
          callback.operationFailed(e);
        }
      });
}
origin: com.yahoo.pulsar/managed-ledger

private void persistPositionMetaStore(long cursorsLedgerId, PositionImpl position,
    MetaStoreCallback<Void> callback) {
  // When closing we store the last mark-delete position in the z-node itself, so we won't need the cursor ledger,
  // hence we write it as -1. The cursor ledger is deleted once the z-node write is confirmed.
  ManagedCursorInfo.Builder info = ManagedCursorInfo.newBuilder() //
      .setCursorsLedgerId(cursorsLedgerId) //
      .setMarkDeleteLedgerId(position.getLedgerId()) //
      .setMarkDeleteEntryId(position.getEntryId()); //
  if (protobufFormat == ZNodeProtobufFormat.Binary) {
    info.addAllIndividualDeletedMessages(buildIndividualDeletedMessageRanges());
  }
  if (log.isDebugEnabled()) {
    log.debug("[{}][{}]  Closing cursor at md-position: {}", ledger.getName(), name, markDeletePosition);
  }
  ledger.getStore().asyncUpdateCursorInfo(ledger.getName(), name, info.build(), cursorLedgerStat,
      new MetaStoreCallback<Void>() {
        @Override
        public void operationComplete(Void result, Stat stat) {
          callback.operationComplete(result, stat);
        }
        @Override
        public void operationFailed(MetaStoreException e) {
          callback.operationFailed(e);
        }
      });
}
origin: org.apache.pulsar/managed-ledger-original

private void persistPositionMetaStore(long cursorsLedgerId, PositionImpl position, Map<String, Long> properties,
    MetaStoreCallback<Void> callback, boolean persistIndividualDeletedMessageRanges) {
  // When closing we store the last mark-delete position in the z-node itself, so we won't need the cursor ledger,
  // hence we write it as -1. The cursor ledger is deleted once the z-node write is confirmed.
  ManagedCursorInfo.Builder info = ManagedCursorInfo.newBuilder() //
      .setCursorsLedgerId(cursorsLedgerId) //
      .setMarkDeleteLedgerId(position.getLedgerId()) //
      .setMarkDeleteEntryId(position.getEntryId()) //
      .setLastActive(lastActive); //
  info.addAllProperties(buildPropertiesMap(properties));
  if (persistIndividualDeletedMessageRanges) {
    info.addAllIndividualDeletedMessages(buildIndividualDeletedMessageRanges());
  }
  if (log.isDebugEnabled()) {
    log.debug("[{}][{}]  Closing cursor at md-position: {}", ledger.getName(), name, position);
  }
  ledger.getStore().asyncUpdateCursorInfo(ledger.getName(), name, info.build(), cursorLedgerStat,
      new MetaStoreCallback<Void>() {
        @Override
        public void operationComplete(Void result, Stat stat) {
          cursorLedgerStat = stat;
          callback.operationComplete(result, stat);
        }
        @Override
        public void operationFailed(MetaStoreException e) {
          callback.operationFailed(e);
        }
      });
}
org.apache.bookkeeper.mledger.protoMLDataFormats$ManagedCursorInfo$BuilderaddAllIndividualDeletedMessages

Javadoc

repeated .MessageRange individualDeletedMessages = 4;

Popular methods of MLDataFormats$ManagedCursorInfo$Builder

  • build
  • setCursorsLedgerId
    If the ledger id is -1, then the mark-delete position is the one from the (ledgerId, entryId) sna
  • setMarkDeleteEntryId
    optional int64 markDeleteEntryId = 3;
  • setMarkDeleteLedgerId
    Last snapshot of the mark-delete position optional int64 markDeleteLedgerId = 2;
  • <init>
  • buildPartial
  • ensureIndividualDeletedMessagesIsMutable
  • getIndividualDeletedMessages
    repeated .MessageRange individualDeletedMessages = 4;
  • getIndividualDeletedMessagesCount
    repeated .MessageRange individualDeletedMessages = 4;
  • getIndividualDeletedMessagesFieldBuilder
  • getParentForChildren
  • hasCursorsLedgerId
    If the ledger id is -1, then the mark-delete position is the one from the (ledgerId, entryId) sna
  • getParentForChildren,
  • hasCursorsLedgerId,
  • isClean,
  • maybeForceBuilderInitialization,
  • mergeFrom,
  • mergeUnknownFields,
  • newUninitializedMessageException,
  • onBuilt,
  • onChanged

Popular in Java

  • Creating JSON documents from java classes using gson
  • orElseThrow (Optional)
    Return the contained value, if present, otherwise throw an exception to be created by the provided s
  • requestLocationUpdates (LocationManager)
  • setScale (BigDecimal)
    Returns a BigDecimal whose scale is the specified value, and whose value is numerically equal to thi
  • GridBagLayout (java.awt)
    The GridBagLayout class is a flexible layout manager that aligns components vertically and horizonta
  • InputStreamReader (java.io)
    An InputStreamReader is a bridge from byte streams to character streams: It reads bytes and decodes
  • UnknownHostException (java.net)
    Thrown when a hostname can not be resolved.
  • Enumeration (java.util)
    A legacy iteration interface.New code should use Iterator instead. Iterator replaces the enumeration
  • Cipher (javax.crypto)
    This class provides access to implementations of cryptographic ciphers for encryption and decryption
  • IsNull (org.hamcrest.core)
    Is the value null?
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