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

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

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

  • Add the Codota plugin to your IDE and get smart completions
private void myMethod () {
Gson g =
  • Codota Iconnew Gson()
  • Codota IconGsonBuilder gsonBuilder;gsonBuilder.create()
  • Codota Iconnew GsonBuilder().create()
  • Smart code suggestions by Codota
}
origin: apache/pulsar

@Override
public void operationComplete(ManagedCursorInfo result, Stat stat) {
  cursorLedgerId.set(result.getCursorsLedgerId());
  cursorLedgerLatch.countDown();
}
origin: apache/pulsar

hash = (37 * hash) + CURSORSLEDGERID_FIELD_NUMBER;
hash = (53 * hash) + com.google.protobuf.Internal.hashLong(
  getCursorsLedgerId());
origin: apache/pulsar

public Builder mergeFrom(org.apache.bookkeeper.mledger.proto.MLDataFormats.ManagedCursorInfo other) {
 if (other == org.apache.bookkeeper.mledger.proto.MLDataFormats.ManagedCursorInfo.getDefaultInstance()) return this;
 if (other.hasCursorsLedgerId()) {
  setCursorsLedgerId(other.getCursorsLedgerId());
origin: apache/pulsar

long ledgerId = info.getCursorsLedgerId();
bookkeeper.asyncOpenLedger(ledgerId, digestType, config.getPassword(), (rc, lh, ctx) -> {
  if (log.isDebugEnabled()) {
origin: com.yahoo.pulsar/managed-ledger

@Override
public void operationComplete(ManagedCursorInfo info, Stat stat) {
  cursorLedgerStat = stat;
  if (info.getCursorsLedgerId() == -1L) {
    // There is no cursor ledger to read the last position from. It means the cursor has been properly
    // closed and the last mark-delete position is stored in the ManagedCursorInfo itself.s
    PositionImpl recoveredPosition = new PositionImpl(info.getMarkDeleteLedgerId(),
        info.getMarkDeleteEntryId());
    if (info.getIndividualDeletedMessagesCount() > 0) {
      recoverIndividualDeletedMessages(info.getIndividualDeletedMessagesList());
    }
    recoveredCursor(recoveredPosition);
    callback.operationComplete();
  } else {
    // Need to proceed and read the last entry in the specified ledger to find out the last position
    log.info("[{}] Consumer {} meta-data recover from ledger {}", ledger.getName(), name,
        info.getCursorsLedgerId());
    recoverFromLedger(info, callback);
  }
}
origin: apache/pulsar

  Stat stat, final MetaStoreCallback<Void> callback) {
log.info("[{}] [{}] Updating cursor info ledgerId={} mark-delete={}:{}", ledgerName, cursorName,
    info.getCursorsLedgerId(), info.getMarkDeleteLedgerId(), info.getMarkDeleteEntryId());
origin: org.apache.pulsar/managed-ledger-original

  Stat stat, final MetaStoreCallback<Void> callback) {
log.info("[{}] [{}] Updating cursor info ledgerId={} mark-delete={}:{}", ledgerName, cursorName,
    info.getCursorsLedgerId(), info.getMarkDeleteLedgerId(), info.getMarkDeleteEntryId());
origin: com.yahoo.pulsar/managed-ledger

  Stat stat, final MetaStoreCallback<Void> callback) {
log.info("[{}] [{}] Updating cursor info ledgerId={} mark-delete={}:{}", ledgerName, cursorName,
    info.getCursorsLedgerId(), info.getMarkDeleteLedgerId(), info.getMarkDeleteEntryId());
origin: org.apache.pulsar/managed-ledger-original

result = result && (hasCursorsLedgerId() == other.hasCursorsLedgerId());
if (hasCursorsLedgerId()) {
 result = result && (getCursorsLedgerId()
   == other.getCursorsLedgerId());
origin: org.apache.pulsar/managed-ledger-original

hash = (37 * hash) + CURSORSLEDGERID_FIELD_NUMBER;
hash = (53 * hash) + com.google.protobuf.Internal.hashLong(
  getCursorsLedgerId());
origin: com.yahoo.pulsar/managed-ledger

public Builder mergeFrom(org.apache.bookkeeper.mledger.proto.MLDataFormats.ManagedCursorInfo other) {
 if (other == org.apache.bookkeeper.mledger.proto.MLDataFormats.ManagedCursorInfo.getDefaultInstance()) return this;
 if (other.hasCursorsLedgerId()) {
  setCursorsLedgerId(other.getCursorsLedgerId());
origin: apache/pulsar

result = result && (hasCursorsLedgerId() == other.hasCursorsLedgerId());
if (hasCursorsLedgerId()) {
 result = result && (getCursorsLedgerId()
   == other.getCursorsLedgerId());
origin: com.yahoo.pulsar/managed-ledger

long ledgerId = info.getCursorsLedgerId();
bookkeeper.asyncOpenLedger(ledgerId, config.getDigestType(), config.getPassword(), (rc, lh, ctx) -> {
  if (log.isDebugEnabled()) {
origin: org.apache.pulsar/managed-ledger-original

public Builder mergeFrom(org.apache.bookkeeper.mledger.proto.MLDataFormats.ManagedCursorInfo other) {
 if (other == org.apache.bookkeeper.mledger.proto.MLDataFormats.ManagedCursorInfo.getDefaultInstance()) return this;
 if (other.hasCursorsLedgerId()) {
  setCursorsLedgerId(other.getCursorsLedgerId());
origin: apache/pulsar

@Override
public void operationComplete(ManagedCursorInfo info, Stat stat) {
  cursorLedgerStat = stat;
  lastActive = info.getLastActive() != 0 ? info.getLastActive() : lastActive;
  if (info.getCursorsLedgerId() == -1L) {
    // There is no cursor ledger to read the last position from. It means the cursor has been properly
    // closed and the last mark-delete position is stored in the ManagedCursorInfo itself.s
    PositionImpl recoveredPosition = new PositionImpl(info.getMarkDeleteLedgerId(),
        info.getMarkDeleteEntryId());
    if (info.getIndividualDeletedMessagesCount() > 0) {
      recoverIndividualDeletedMessages(info.getIndividualDeletedMessagesList());
    }
    Map<String, Long> recoveredProperties = Collections.emptyMap();
    if (info.getPropertiesCount() > 0) {
      // Recover properties map
      recoveredProperties = Maps.newHashMap();
      for (int i = 0; i < info.getPropertiesCount(); i++) {
        LongProperty property = info.getProperties(i);
        recoveredProperties.put(property.getName(), property.getValue());
      }
    }
    recoveredCursor(recoveredPosition, recoveredProperties, null);
    callback.operationComplete();
  } else {
    // Need to proceed and read the last entry in the specified ledger to find out the last position
    log.info("[{}] Consumer {} meta-data recover from ledger {}", ledger.getName(), name,
        info.getCursorsLedgerId());
    recoverFromLedger(info, callback);
  }
}
origin: org.apache.pulsar/managed-ledger-original

long ledgerId = info.getCursorsLedgerId();
bookkeeper.asyncOpenLedger(ledgerId, digestType, config.getPassword(), (rc, lh, ctx) -> {
  if (log.isDebugEnabled()) {
origin: org.apache.pulsar/managed-ledger-original

@Override
public void operationComplete(ManagedCursorInfo info, Stat stat) {
  cursorLedgerStat = stat;
  lastActive = info.getLastActive() != 0 ? info.getLastActive() : lastActive;
  if (info.getCursorsLedgerId() == -1L) {
    // There is no cursor ledger to read the last position from. It means the cursor has been properly
    // closed and the last mark-delete position is stored in the ManagedCursorInfo itself.s
    PositionImpl recoveredPosition = new PositionImpl(info.getMarkDeleteLedgerId(),
        info.getMarkDeleteEntryId());
    if (info.getIndividualDeletedMessagesCount() > 0) {
      recoverIndividualDeletedMessages(info.getIndividualDeletedMessagesList());
    }
    Map<String, Long> recoveredProperties = Collections.emptyMap();
    if (info.getPropertiesCount() > 0) {
      // Recover properties map
      recoveredProperties = Maps.newHashMap();
      for (int i = 0; i < info.getPropertiesCount(); i++) {
        LongProperty property = info.getProperties(i);
        recoveredProperties.put(property.getName(), property.getValue());
      }
    }
    recoveredCursor(recoveredPosition, recoveredProperties, null);
    callback.operationComplete();
  } else {
    // Need to proceed and read the last entry in the specified ledger to find out the last position
    log.info("[{}] Consumer {} meta-data recover from ledger {}", ledger.getName(), name,
        info.getCursorsLedgerId());
    recoverFromLedger(info, callback);
  }
}
org.apache.bookkeeper.mledger.protoMLDataFormats$ManagedCursorInfogetCursorsLedgerId

Javadoc

 
If the ledger id is -1, then the mark-delete position is 
the one from the (ledgerId, entryId) snapshot below 
required int64 cursorsLedgerId = 1;

Popular methods of MLDataFormats$ManagedCursorInfo

  • getIndividualDeletedMessagesCount
    repeated .MessageRange individualDeletedMessages = 4;
  • newBuilder
  • <init>
  • getDefaultInstance
  • getDescriptor
  • getIndividualDeletedMessages
    repeated .MessageRange individualDeletedMessages = 4;
  • getIndividualDeletedMessagesList
    repeated .MessageRange individualDeletedMessages = 4;
  • getMarkDeleteEntryId
    optional int64 markDeleteEntryId = 3;
  • getMarkDeleteLedgerId
    Last snapshot of the mark-delete position optional int64 markDeleteLedgerId = 2;
  • hasCursorsLedgerId
    If the ledger id is -1, then the mark-delete position is the one from the (ledgerId, entryId) sna
  • hasMarkDeleteEntryId
    optional int64 markDeleteEntryId = 3;
  • hasMarkDeleteLedgerId
    Last snapshot of the mark-delete position optional int64 markDeleteLedgerId = 2;
  • hasMarkDeleteEntryId,
  • hasMarkDeleteLedgerId,
  • isInitialized,
  • toByteArray,
  • getLastActive,
  • getProperties,
  • getPropertiesCount,
  • getPropertiesList,
  • getSerializedSize

Popular in Java

  • Running tasks concurrently on multiple threads
  • setRequestProperty (URLConnection)
  • addToBackStack (FragmentTransaction)
  • getSupportFragmentManager (FragmentActivity)
    Return the FragmentManager for interacting with fragments associated with this activity.
  • GridLayout (java.awt)
    The GridLayout class is a layout manager that lays out a container's components in a rectangular gri
  • Runnable (java.lang)
    Represents a command that can be executed. Often used to run code in a different Thread.
  • Selector (java.nio.channels)
    A controller for the selection of SelectableChannel objects. Selectable channels can be registered w
  • Queue (java.util)
    A collection designed for holding elements prior to processing. Besides basic java.util.Collection o
  • CountDownLatch (java.util.concurrent)
    A synchronization aid that allows one or more threads to wait until a set of operations being perfor
  • BoxLayout (javax.swing)
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