ReadLedgerCommand can't get lastEntry when specifying the ledger rang…#4149
ReadLedgerCommand can't get lastEntry when specifying the ledger rang…#4149liubingxing wants to merge 1 commit intoapache:masterfrom
Conversation
|
rerun failure checks |
1 similar comment
|
rerun failure checks |
|
@liubingxing Would you please help take a look at the failed tests? |
@hangc0276 Sorry, I didn't notice these failed tests, I will fix them as soon as possible. |
|
@hangc0276 |
|
rerun failure checks |
|
The test failed with timeout The failed log is @liubingxing Please take a look, thanks. |
…e and bookie addr
5cfcca9 to
189a489
Compare
@hangc0276 Thanks for pointing out the error, I updated the code. Please review again. |
When we use the ReadLedgerCommand to read the ledger with entry range
bookkeeper shell readledger -l < ledgerId > -fe <firstEntryId> -le <lastEntryId>
This will return the entry in range [firstEntryId, lastEntryId].
If we specifying the bookie addr to read the ledger with entry range
bookkeeper shell readledger -b <bookieId> -l <ledgerId> -fe <firstEntryId> -le <lastEntryId>
It will return the entry in range [firstEntryId, lastEntryId) , the lastEntry is not included.
Because the LongStream.range will not include the lastEntry


We should replace LongStream.range with LongStream.rangeClosed
