Skip to content

Commit

Permalink
Merge pull request #76 from qdrant/fix-clippy-bump-deps
Browse files Browse the repository at this point in the history
Fix Clippy & bump dependencies
  • Loading branch information
agourlay committed Aug 15, 2024
2 parents a787090 + a88aee9 commit 7c9202d
Show file tree
Hide file tree
Showing 4 changed files with 16 additions and 14 deletions.
18 changes: 9 additions & 9 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -13,13 +13,13 @@ repository = "https://github.com/qdrant/wal"
edition = "2021"

[dependencies]
byteorder = "1.4"
crc32c = "0.6.4"
byteorder = "1.5"
crc32c = "0.6.8"
log = "0.4"
memmap2 = "0.9.0"
memmap2 = "0.9.4"
rand = "0.8.5"
rand_distr = "0.4.3"
fs4 = "0.8"
fs4 = "0.9.1"
# fs4 depends on rustix, but pulling this dependency explicitly into the tree
# to use direct functions on FreeBSD
rustix = { version = "0", features = [ "fs" ]}
Expand All @@ -31,12 +31,12 @@ env_logger = "0.11"
serde = { version = "1", features = ["derive"] }

[dev-dependencies]
crc = "3"
hdrhistogram = "7.5.2"
crc = "3.2.1"
hdrhistogram = "7.5.4"
quickcheck = "1.0.3"
regex = "1.8.1"
tempfile = "3.5.0"
chrono = "0.4.31"
regex = "1.10.6"
tempfile = "3.12.0"
chrono = "0.4.38"
criterion = "0.5.1"

[[bench]]
Expand Down
9 changes: 5 additions & 4 deletions src/lib.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
use crossbeam_channel::{Receiver, Sender};
use fs4::FileExt;
use fs4::fs_std::FileExt;
use log::{debug, info, trace, warn};
pub use segment::{Entry, Segment};
use std::cmp::Ordering;
use std::collections::HashMap;
use std::fmt;
Expand All @@ -13,8 +14,6 @@ use std::result;
use std::str::FromStr;
use std::thread;

pub use segment::{Entry, Segment};

mod mmap_view_sync;
mod segment;
pub mod test_utils;
Expand Down Expand Up @@ -137,6 +136,7 @@ impl Wal {
.create(true)
.read(true)
.write(true)
.truncate(true)
.open(&path)?;
path.pop();
dir
Expand Down Expand Up @@ -514,7 +514,7 @@ impl Wal {
segment.copy_to_path(&dst_path)?;
} else {
// if file is not locked by any Segment, just copy it
fs::copy(&entry.path(), &dst_path)?;
fs::copy(entry.path(), &dst_path)?;
}
}
Ok(())
Expand Down Expand Up @@ -955,6 +955,7 @@ mod test {
.read(true)
.write(true)
.create(true)
.truncate(true)
.open(dir.path().join("tmp-open-123"))
.unwrap();

Expand Down
1 change: 1 addition & 0 deletions src/mmap_view_sync.rs
Original file line number Diff line number Diff line change
Expand Up @@ -237,6 +237,7 @@ mod test {
.read(true)
.write(true)
.create(true)
.truncate(true)
.open(path)
.unwrap();
file.set_len(len).unwrap();
Expand Down
2 changes: 1 addition & 1 deletion src/segment.rs
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ use std::time::Duration;
use crate::mmap_view_sync::MmapViewSync;
use byteorder::{ByteOrder, LittleEndian};
#[cfg(not(unix))]
use fs4::FileExt;
use fs4::fs_std::FileExt;

/// The magic bytes and version tag of the segment header.
const SEGMENT_MAGIC: &[u8; 3] = b"wal";
Expand Down

0 comments on commit 7c9202d

Please sign in to comment.