Skip to content

Commit

Permalink
Explain the high water number.
Browse files Browse the repository at this point in the history
  • Loading branch information
AaronGoldman committed Oct 22, 2024
1 parent bd3efd8 commit 7ea1d9c
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions anchor-service/src/cas_mock.rs
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,9 @@ impl Store for MockAnchorEventService {
highwater: i64,
limit: i64,
) -> Result<Vec<AnchorRequest>> {
// The high water mark is the last row in the table.
// The call to events_since_high_water_mark generate the next event (n+1)
// to the anchor_req_count which is the last event in the mock data.
let ints = ((highwater as u64 + 1)..=self.anchor_req_count).take(limit as usize);
Ok(ints.map(|n| AnchorRequest {
id: self.int64_cid(n),
Expand Down

0 comments on commit 7ea1d9c

Please sign in to comment.