Uploaded image for project: 'Kudu'
  1. Kudu
  2. KUDU-1664

Clean-up in-code documentation for KuduScanner::ReadMode and KuduClient::GetLatestObservedTimestamp

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Minor
    • Resolution: Duplicate
    • Affects Version/s: 1.0.0
    • Fix Version/s: 1.1.0
    • Component/s: api, client, documentation
    • Labels:
      None

      Description

      After reading the in-line doc for the subj. entities, one would expect the scanner from the following code to do its job on reading-what-you-have-written:

      const uint64_t snapshot_timestamp = client->GetLatestObservedTimestamp();
      
      KuduScanner scanner(table.get());
      RETURN_NOT_OK(scanner.SetSnapshotRaw(snapshot_timestamp));
      RETURN_NOT_OK(scanner.SetReadMode(KuduScanner::READ_AT_SNAPSHOT));
      RETURN_NOT_OK(scanner.Open());
      

      However, it does not work.

      To make it work, it's necessary to add extra 1 to the snapshot timestamp:

      RETURN_NOT_OK(scanner.SetSnapshotRaw(snapshot_timestamp + 1));
      

        Attachments

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              aserbin Alexey Serbin
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: