Skip to content

Commit 203019c

Browse files
committed
public some stuff in Vortex-datafusion
1 parent 60bb402 commit 203019c

File tree

3 files changed

+5
-2
lines changed

3 files changed

+5
-2
lines changed

vortex-datafusion/src/persistent/cache.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ use vortex::stats::{Precision, Stat};
2020
use vortex::utils::aliases::DefaultHashBuilder;
2121

2222
#[derive(Clone)]
23-
pub(crate) struct VortexFileCache {
23+
pub struct VortexFileCache {
2424
file_cache: Cache<FileKey, VortexFile, DefaultHashBuilder>,
2525
segment_cache: Cache<SegmentKey, ByteBuffer, DefaultHashBuilder>,
2626
session: Arc<VortexSession>,
@@ -50,6 +50,7 @@ struct SegmentKey {
5050
}
5151

5252
impl VortexFileCache {
53+
/// Create a new [`VortexFileCache`] with the given size.
5354
pub fn new(size_mb: usize, segment_size_mb: usize, session: Arc<VortexSession>) -> Self {
5455
let file_cache = Cache::builder()
5556
.max_capacity(size_mb as u64 * (1 << 20))

vortex-datafusion/src/persistent/mod.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ mod opener;
99
mod sink;
1010
mod source;
1111

12+
pub use cache::VortexFileCache;
1213
pub use format::{VortexFormat, VortexFormatFactory, VortexOptions};
1314
pub use source::VortexSource;
1415

vortex-datafusion/src/persistent/source.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,8 @@ pub struct VortexSource {
5656
}
5757

5858
impl VortexSource {
59-
pub(crate) fn new(file_cache: VortexFileCache, metrics: VortexMetrics) -> Self {
59+
/// Creates a new VortexSource instance.
60+
pub fn new(file_cache: VortexFileCache, metrics: VortexMetrics) -> Self {
6061
Self {
6162
file_cache,
6263
metrics,

0 commit comments

Comments
 (0)