Skip to content

Commit

Permalink
Stop trying to move pages into the read cache once it is full.
Browse files Browse the repository at this point in the history
  • Loading branch information
adamreichold committed May 12, 2024
1 parent 09435b1 commit c6c80ca
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/tree_store/page_store/cached_file.rs
Original file line number Diff line number Diff line change
Expand Up @@ -303,6 +303,7 @@ impl PagedCachedFile {
} else {
self.read_cache_bytes
.fetch_sub(buffer.len(), Ordering::AcqRel);
break;
}
}
for (offset, buffer) in write_buffer.low_pri_cache.iter_mut() {
Expand All @@ -318,6 +319,7 @@ impl PagedCachedFile {
} else {
self.read_cache_bytes
.fetch_sub(buffer.len(), Ordering::AcqRel);
break;
}
}
self.write_buffer_bytes.store(0, Ordering::Release);
Expand Down

0 comments on commit c6c80ca

Please sign in to comment.