Skip to content

Commit

Permalink
Refactor index management and enhance transaction support in OnDiskIn…
Browse files Browse the repository at this point in the history
…dexManager
  • Loading branch information
sachaarbonel committed Jan 13, 2025
1 parent 2a2e761 commit 9fd1307
Show file tree
Hide file tree
Showing 6 changed files with 684 additions and 150 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ fn main() {
### Critical for Production (Highest Priority)

#### Real-time Index Management
- [ ] Real-time index updates with ACID compliance
- [x] Real-time index updates with ACID compliance
- [ ] Index consistency verification
- [ ] Atomic index operations
- [ ] Index recovery mechanisms
Expand Down
6 changes: 5 additions & 1 deletion src/indexes/btree/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,11 @@ impl BTreeIndex {
}

pub fn search(&self, value: Vec<u8>) -> Option<&HashSet<usize>> {
self.index.get(&value)
println!("BTreeIndex::search - Searching for value: {:?}", value);
println!("BTreeIndex::search - Current index contents: {:?}", self.index);
let result = self.index.get(&value);
println!("BTreeIndex::search - Found result: {:?}", result);
result
}

pub fn range_search(&self, start: Vec<u8>, end: Vec<u8>) -> HashSet<usize> {
Expand Down
Loading

0 comments on commit 9fd1307

Please sign in to comment.